Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 53 lines (43 sloc) 1.82 kb
923eae5 Stefan O'Rear Redo build system; bootstrapped niecza is live
authored
1 ### CONFIGURATION
2
3 # How to run CLR programs; can be blank for Win32
4 RUN_CLR=mono
5 CSC=gmcs
6 RM=rm -f
7 CP=cp
8
9 cskernel=Kernel.cs Builtins.cs Cursor.cs JSYNC.cs NieczaCLR.cs
10 csbackend=CLRBackend.cs
11
12 # keep this in dependency order
eab7f8a Stefan O'Rear Add test and p6eval make targets
authored
13 libunits=SAFE CORE JSYNC
14 srcunits=CClass Body Unit CgOp Op Sig RxOp NAME Stash STD NieczaGrammar \
15 Metamodel OptRxSimple NAMOutput NieczaActions NieczaFrontendSTD \
16 NieczaPassBegin NieczaPassBeta NieczaPassSimplifier NieczaPathSearch \
17 NieczaBackendNAM NieczaBackendDotnet NieczaBackendClisp NieczaCompiler
923eae5 Stefan O'Rear Redo build system; bootstrapped niecza is live
authored
18
eab7f8a Stefan O'Rear Add test and p6eval make targets
authored
19 all: run/Niecza.exe obj/Kernel.dll obj/CLRBackend.exe
e2d1ed2 Stefan O'Rear Write VERSION file
authored
20 git describe --tags > VERSION
eab7f8a Stefan O'Rear Add test and p6eval make targets
authored
21
22 run/Niecza.exe: .fetch-stamp $(patsubst %,src/%.pm6,$(srcunits)) src/niecza
e23237d Stefan O'Rear On second thought, don't pass -I to bootstrap
authored
23 cd src && $(RUN_CLR) ../boot/run/Niecza.exe -v -c -Bnam niecza
eab7f8a Stefan O'Rear Add test and p6eval make targets
authored
24 for nfile in $(libunits) $(srcunits); do echo $$nfile; \
0cdc4fd Stefan O'Rear Only run nam->dll step if file changed
authored
25 if [ boot/obj/$$nfile.nam -nt boot/obj/$$nfile.dll ]; then \
26 $(RUN_CLR) boot/obj/CLRBackend.exe boot/obj $$nfile.nam $$nfile.dll 0; \
27 fi; done
923eae5 Stefan O'Rear Redo build system; bootstrapped niecza is live
authored
28 $(RUN_CLR) boot/obj/CLRBackend.exe boot/obj MAIN.nam MAIN.exe 1
eab7f8a Stefan O'Rear Add test and p6eval make targets
authored
29 $(CP) $(patsubst %,boot/obj/%.dll,Kernel $(libunits) $(srcunits)) run/
923eae5 Stefan O'Rear Redo build system; bootstrapped niecza is live
authored
30 $(CP) boot/obj/MAIN.exe run/Niecza.exe
31
32 .fetch-stamp: FETCH_URL
33 -rm -rf boot/
34 mkdir boot
35 wget --no-check-certificate -Oboot/niecza.zip $$(cat FETCH_URL)
36 cd boot && unzip niecza.zip
37 touch .fetch-stamp
38
39 obj/Kernel.dll: $(patsubst %,lib/%,$(cskernel))
40 $(CSC) /target:library /out:obj/Kernel.dll /unsafe+ \
41 $(patsubst %,lib/%,$(cskernel))
42 obj/CLRBackend.exe: $(patsubst %,lib/%,$(csbackend)) obj/Kernel.dll
43 $(CSC) /target:exe /lib:obj /out:obj/CLRBackend.exe /r:Kernel.dll \
44 $(patsubst %,lib/%,$(csbackend))
eab7f8a Stefan O'Rear Add test and p6eval make targets
authored
45
46 test: all
47 $(RUN_CLR) run/Niecza.exe -c test.pl
48 prove -e $(RUN_CLR) obj/MAIN.exe
49
50 p6eval: all
51 $(RUN_CLR) run/Niecza.exe -C CORE Test JSYNC
52 $(RUN_CLR) --aot run/*.dll run/Niecza.exe
Something went wrong with that request. Please try again.