Skip to content
Newer
Older
100644 41 lines (34 sloc) 1.41 KB
923eae5 @sorear 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
13 units=SAFE CORE CClass Body Unit CgOp Op Sig RxOp NAME Stash JSYNC STD \
14 NieczaGrammar Metamodel OptRxSimple NAMOutput NieczaActions \
15 NieczaFrontendSTD NieczaPassBegin NieczaPassBeta NieczaPassSimplifier \
16 NieczaPathSearch NieczaBackendNAM NieczaBackendDotnet NieczaBackendClisp \
17 NieczaCompiler
18
19 all: obj/Kernel.dll obj/CLRBackend.exe .fetch-stamp
20 cd src && $(RUN_CLR) ../boot/run/Niecza.exe -I../lib -v -c -Bnam niecza
21 for nfile in $(units); do echo $$nfile; \
22 $(RUN_CLR) boot/obj/CLRBackend.exe boot/obj $$nfile.nam $$nfile.dll 0; \
23 done
24 $(RUN_CLR) boot/obj/CLRBackend.exe boot/obj MAIN.nam MAIN.exe 1
25 $(CP) $(patsubst %,boot/obj/%.dll,Kernel $(units)) run/
26 $(CP) boot/obj/MAIN.exe run/Niecza.exe
27
28 .fetch-stamp: FETCH_URL
29 -rm -rf boot/
30 mkdir boot
31 wget --no-check-certificate -Oboot/niecza.zip $$(cat FETCH_URL)
32 cd boot && unzip niecza.zip
33 touch .fetch-stamp
34
35 obj/Kernel.dll: $(patsubst %,lib/%,$(cskernel))
36 $(CSC) /target:library /out:obj/Kernel.dll /unsafe+ \
37 $(patsubst %,lib/%,$(cskernel))
38 obj/CLRBackend.exe: $(patsubst %,lib/%,$(csbackend)) obj/Kernel.dll
39 $(CSC) /target:exe /lib:obj /out:obj/CLRBackend.exe /r:Kernel.dll \
40 $(patsubst %,lib/%,$(csbackend))
Something went wrong with that request. Please try again.