Skip to content
Find file
Fetching contributors…
Cannot retrieve contributors at this time
145 lines (94 sloc) 4.22 KB
# Haxe compiler Makefile
# - use 'make' to build all
# - use 'make haxe' to build only the compiler (not the libraries)
# - if you want to build quickly, install 'ocamlopt.opt' and change
# Windows users :
# - use 'make -f' to build for Windows
# - use 'make MSVC=1 -f' to build for Windows with OCaml/MSVC
.SUFFIXES : .ml .mli .cmo .cmi .cmx .mll .mly
CFLAGS= -g -I libs/extlib -I libs/extc -I libs/neko -I libs/javalib -I libs/ziplib -I libs/swflib -I libs/xml-light
CC_PARSER_CMD = $(OCAMLOPT) -pp camlp4o $(CFLAGS) -c
LIBS=unix.cmxa str.cmxa libs/extlib/extLib.cmxa libs/xml-light/xml-light.cmxa libs/swflib/swflib.cmxa \
libs/extc/extc.cmxa libs/neko/neko.cmxa libs/javalib/java.cmxa libs/ziplib/zip.cmxa
NATIVE_LIBS=-cclib libs/extc/extc_stubs.o -cclib -lz
MODULES=ast type lexer common genxml parser typecore optimizer typeload \
codegen genas3 gencommon gencpp genjs genneko genphp genswf8 \
gencs genjava genswf9 genswf interp typer dce main
all: libs haxe tools
make -C libs/extlib opt
make -C libs/extc native
make -C libs/neko
make -C libs/javalib
make -C libs/ziplib
make -C libs/swflib
make -C libs/xml-light xml-light.cmxa
haxe: $(MODULES:=.cmx)
$(CURDIR)/$(OUTPUT) --cwd "$(CURDIR)/std/tools/haxelib" haxelib.hxml
cp std/tools/haxelib/haxelib$(EXTENSION) haxelib$(EXTENSION)
$(CURDIR)/$(OUTPUT) --cwd "$(CURDIR)/std/tools/haxedoc" haxedoc.hxml
cp std/tools/haxedoc/haxedoc$(EXTENSION) haxedoc$(EXTENSION)
tools: haxelib haxedoc
cp haxe*.exe doc/CHANGES.txt $(EXPORT)
rsync -a --exclude .svn --exclude *.n --exclude std/libs --delete std $(EXPORT)
codegen.cmx: typeload.cmx typecore.cmx type.cmx genxml.cmx common.cmx ast.cmx
common.cmx: type.cmx ast.cmx
dce.cmx: ast.cmx common.cmx type.cmx typecore.cmx
genas3.cmx: type.cmx common.cmx codegen.cmx ast.cmx
gencommon.cmx: type.cmx common.cmx codegen.cmx ast.cmx
gencpp.cmx: type.cmx lexer.cmx common.cmx codegen.cmx ast.cmx
gencs.cmx: type.cmx lexer.cmx gencommon.cmx common.cmx codegen.cmx ast.cmx
genjava.cmx: type.cmx gencommon.cmx common.cmx codegen.cmx ast.cmx
genjs.cmx: type.cmx optimizer.cmx lexer.cmx common.cmx codegen.cmx ast.cmx
genneko.cmx: type.cmx lexer.cmx common.cmx codegen.cmx ast.cmx
genphp.cmx: type.cmx lexer.cmx common.cmx codegen.cmx ast.cmx
genswf.cmx: type.cmx genswf9.cmx genswf8.cmx common.cmx ast.cmx
genswf8.cmx: type.cmx lexer.cmx common.cmx codegen.cmx ast.cmx
genswf9.cmx: type.cmx lexer.cmx genswf8.cmx common.cmx codegen.cmx ast.cmx
genxml.cmx: type.cmx lexer.cmx common.cmx ast.cmx
interp.cmx: typecore.cmx type.cmx lexer.cmx genneko.cmx common.cmx codegen.cmx ast.cmx genswf.cmx parser.cmx
main.cmx: dce.cmx typer.cmx typeload.cmx typecore.cmx type.cmx parser.cmx optimizer.cmx lexer.cmx interp.cmx genxml.cmx genswf.cmx genphp.cmx genneko.cmx genjs.cmx genjava.cmx gencs.cmx gencpp.cmx genas3.cmx common.cmx codegen.cmx ast.cmx
optimizer.cmx: typecore.cmx type.cmx parser.cmx common.cmx ast.cmx
parser.cmx: lexer.cmx common.cmx ast.cmx
type.cmx: ast.cmx
typecore.cmx: type.cmx common.cmx ast.cmx
typeload.cmx: typecore.cmx type.cmx parser.cmx optimizer.cmx lexer.cmx common.cmx ast.cmx
typer.cmx: typeload.cmx typecore.cmx type.cmx parser.cmx optimizer.cmx lexer.cmx interp.cmx genneko.cmx genjs.cmx common.cmx codegen.cmx ast.cmx
lexer.cmx: ast.cmx
clean: clean_libs clean_haxe clean_tools
make -C libs/extlib clean
make -C libs/extc clean
make -C libs/neko clean
make -C libs/ziplib clean
make -C libs/javalib clean
make -C libs/swflib clean
make -C libs/xml-light clean
rm -f $(MODULES:=.obj) $(MODULES:=.o) $(MODULES:=.cmx) $(MODULES:=.cmi)
rm -f $(OUTPUT) haxelib haxedoc
ocamllex $<
.PHONY: haxe libs
Jump to Line
Something went wrong with that request. Please try again.