Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
H
Hdlmake
Manage
Activity
Members
Labels
Plan
Issues
20
Issue boards
Milestones
Wiki
Code
Merge requests
5
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Projects
Hdlmake
Commits
cb90d0ad
Commit
cb90d0ad
authored
11 years ago
by
Pawel Szostek
Browse files
Options
Downloads
Patches
Plain Diff
Move makefile and "build" scripts to separate directory
parent
64ac1e4b
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
scripts/build_hash.sh
+1
-1
1 addition, 1 deletion
scripts/build_hash.sh
scripts/makefile
+19
-7
19 additions, 7 deletions
scripts/makefile
with
20 additions
and
8 deletions
embed_
build_
id
.sh
→
scripts/
build_
hash
.sh
+
1
−
1
View file @
cb90d0ad
...
...
@@ -8,5 +8,5 @@ date_string=$(echo $date_line | awk '{print $6 $3 $4}')
embed_string
=
'"'
$(
echo
"
$date_string
:
${
commit_string
:0:6
}
"
)
'"'
build_hash_path
=
"
src
/build_hash.py"
build_hash_path
=
"
../hdlmake
/build_hash.py"
echo
'BUILD_ID = '
"
$embed_string
"
>
$build_hash_path
This diff is collapsed.
Click to expand it.
make_tarball
→
scripts/makefile
+
19
−
7
View file @
cb90d0ad
...
...
@@ -15,17 +15,18 @@
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
#
SRC_FILES := $(shell find hdlmake -name '*py')
SRC_DIR
:=
../hdlmake
SRC_FILES
:=
$(
shell find
$(
SRC_DIR
)
-name
'*py'
)
SRC_FILES_BASENAMES
=
$(
foreach src,
$(
SRC_FILES
)
,
$(
shell
basename
$(
src
)))
TAG = $(shell git describe --abbrev=0 --tags --always)#get the latest tag
TAG
=
$(
shell
cd
..
&&
git describe
--abbrev
=
0
--tags
--always
)
#get the latest tag
RELEASE
=
hdlmake-
$(
TAG
)
.tar.gz
ARCH
:=
hdlmake
$(
TAG
)
single_file_app:
$(ARCH) build_tag
single_file_app
:
warning $(ARCH)
$(ARCH)
:
$(SRC_FILES)
bash
embed_
build_
id
.sh
cd
hdlmake
&&\
bash build_
hash
.sh
cd
$(
SRC_DIR
)
&&
\
zip
$(
ARCH
)
build_hash.py
$(
SRC_FILES_BASENAMES
)
&&
\
echo
'#!/usr/bin/python'
>
$(
ARCH
)
&&
\
cat
$(
ARCH
)
.zip
>>
$(
ARCH
)
&&
\
...
...
@@ -37,8 +38,19 @@ release: $(RELEASE)
$(RELEASE)
:
$(ARCH) $(SRC)
tar
-zcvf
$@
*
.PHONY: clean build_tag
warning
:
echo
This makefile is not ment to build an executable file.
echo
The default way to run hdlmake is to give the path
echo
to the
source
code as the first argument to the Python
echo
interpreter call,
for
instance:
echo
python path/to/hdl-make/hdlmake
echo
If you _really_ need to have a single file,
then
echo
you might use this makefile, but
in
some cases it might
echo
reduce the volume of displayed debugging information.
sleep
5
.PHONY
:
clean
clean
:
rm -f $(SRC_DIR)/*~ $(
PREFIX)/*pyc $(EXEC)
hdlmake-*.tar.gz
rm
-f
$(
SRC_DIR
)
/
*
~
$(
SRC_DIR
)
/
*
pyc ../
$(
ARCH
)
../
hdlmake-
*
.tar.gz
This diff is collapsed.
Click to expand it.
Preview
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment