Mercurial > projects > ldc
comparison druntime/src/dmd-posix.mak @ 1458:e0b2d67cfe7c
Added druntime (this should be removed once it works).
author | Robert Clipsham <robert@octarineparrot.com> |
---|---|
date | Tue, 02 Jun 2009 17:43:06 +0100 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
1456:7b218ec1044f | 1458:e0b2d67cfe7c |
---|---|
1 # Makefile to build the composite D runtime library for Linux | |
2 # Designed to work with GNU make | |
3 # Targets: | |
4 # make | |
5 # Same as make all | |
6 # make debug | |
7 # Build the debug version of the library | |
8 # make release | |
9 # Build the release version of the library | |
10 # make doc | |
11 # Generate documentation | |
12 # make clean | |
13 # Delete all files created by build process | |
14 | |
15 # Essentials | |
16 | |
17 LIBDIR:=../lib | |
18 DOCDIR:=../doc | |
19 LIBBASENAME=libdruntime.a | |
20 | |
21 DIR_CC=common | |
22 DIR_RT=compiler/dmd | |
23 DIR_GC=gc/basic | |
24 | |
25 # Symbols | |
26 | |
27 DMD=dmd | |
28 | |
29 # Targets | |
30 | |
31 all : debug release doc unittest $(LIBDIR)/$(LIBBASENAME) | |
32 | |
33 # unittest : | |
34 # $(MAKE) -fdmd-posix.mak lib MAKE_LIB="unittest" | |
35 # dmd -unittest unittest ../import/core/stdc/stdarg \ | |
36 # -defaultlib="$(DUP_TARGET)" -debuglib="$(DUP_TARGET)" | |
37 # $(RM) stdarg.o | |
38 # ./unittest | |
39 | |
40 debug release unittest : | |
41 @$(MAKE) DMD=$(DMD) -C $(DIR_CC) --no-print-directory -fposix.mak $@ | |
42 @$(MAKE) DMD=$(DMD) -C $(DIR_RT) --no-print-directory -fposix.mak $@ | |
43 @$(MAKE) DMD=$(DMD) -C $(DIR_GC) --no-print-directory -fposix.mak $@ | |
44 @$(DMD) -lib -of$(LIBDIR)/$@/$(LIBBASENAME) \ | |
45 $(LIBDIR)/$@/libdruntime-core.a \ | |
46 $(LIBDIR)/$@/libdruntime-rt-dmd.a \ | |
47 $(LIBDIR)/$@/libdruntime-gc-basic.a | |
48 | |
49 $(LIBDIR)/$(LIBBASENAME) : $(LIBDIR)/release/$(LIBBASENAME) | |
50 ln -sf $(realpath $<) $@ | |
51 | |
52 doc : $(ALL_DOCS) | |
53 $(MAKE) DMD=$(DMD) -C $(DIR_CC) --no-print-directory -fposix.mak doc | |
54 # $(MAKE) DMD=$(DMD) -C $(DIR_RT) --no-print-directory -fposix.mak doc | |
55 # $(MAKE) DMD=$(DMD) -C $(DIR_GC) --no-print-directory -fposix.mak doc | |
56 | |
57 ###################################################### | |
58 | |
59 clean : | |
60 $(MAKE) DMD=$(DMD) -C $(DIR_CC) --no-print-directory -fposix.mak clean | |
61 $(MAKE) DMD=$(DMD) -C $(DIR_RT) --no-print-directory -fposix.mak clean | |
62 $(MAKE) DMD=$(DMD) -C $(DIR_GC) --no-print-directory -fposix.mak clean | |
63 #find . -name "*.di" | xargs $(RM) | |
64 rm -rf $(LIBDIR) $(DOCDIR) | |
65 | |
66 # install : | |
67 # make -C $(DIR_CC) --no-print-directory -fposix.mak install | |
68 # make -C $(DIR_RT) --no-print-directory -fposix.mak install | |
69 # make -C $(DIR_GC) --no-print-directory -fposix.mak install | |
70 # $(CP) $(LIB_MASK) $(LIB_DEST)/. | |
71 # $(CP) $(DUP_MASK) $(LIB_DEST)/. | |
72 |