-
-
Notifications
You must be signed in to change notification settings - Fork 654
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add Makefile/sh based "build system"
- Loading branch information
Showing
5 changed files
with
56 additions
and
151 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,8 @@ | ||
# Auto detect text files and perform LF normalization | ||
* text=auto | ||
|
||
.gitattributes export-ignore | ||
.gitattributes export-ignore | ||
.gitignore export-ignore | ||
.travis.yml export-ignore | ||
appveyor.yml export-ignore | ||
appveyor.yml export-ignore | ||
*.sh eol=lf |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -94,3 +94,6 @@ tests/misc/projects/Issue4070/cpp/ | |
|
||
/tests/sys/temp | ||
*.dll | ||
_build/ | ||
Makefile.dependencies | ||
Makefile.modules |
Oops, something went wrong.
dacdd0b
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm gonna document what this is doing here. The first thing we do is copy all
.ml
files from the source directories to_build
if they are newer (-u
flag). At this point we also runcompile.sh
which re-generateslexer.ml
,parser.ml
andversion.ml
if they are newer than the target file.The make process afterwards consists of 4 passes:
ls
to get a list of all.ml
files in_build
and write that list toMakefile.modules
.ocamldep -sort
to get an ordered list of these modules and strip the.ml
extension usingsed
. Write the new result toMakefile.modules
again.ocamldep
on all module files and write the output toMakefile.dependencies
.Makefile.modules
as a list of modules andMakefile.dependencies
for the dependencies.The main reason I'm multi-passing is that I couldn't find a way to pass information to ocamldep otherwise, as it doesn't seem to support reading stdin.
dacdd0b
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hello,
I sometimes have trouble to recompile haxe when i only modified some files , i have to do a clean_haxe and rebuild all.
To circumvent this i have created a rsync.sh that will indicate if there is dependencies to rebuild:
rsync.sh:
and in Makefile i have deleted the pass_build and avoid the reentrant call:
makefile pass for haxe: