source: libcfa/Makefile.in @ 0c7a885

ADTaaron-thesisarm-ehast-experimentalcleanup-dtorsctordeferred_resndemanglerenumforall-pointer-decaygc_noraiijacob/cs343-translationjenkins-sandboxmemorynew-astnew-ast-unique-exprnew-envno_listpersistent-indexerpthread-emulationqualifiedEnumresolv-newstringwith_gc
Last change on this file since 0c7a885 was 0c7a885, checked in by Peter A. Buhr <pabuhr@…>, 9 years ago

fix libcfa/Makefile.in, second attempt

  • Property mode set to 100644
File size: 1.7 KB
Line 
1b######################### -*- Mode: Makefile-Gmake -*- ########################
2##
3## Cforall Version 1.0.0 Copyright (C) 2015 University of Waterloo
4##
5## The contents of this file are covered under the licence agreement in the
6## file "LICENCE" distributed with Cforall.
7##
8## Makefile.in --
9##
10## Author           : Peter A. Buhr
11## Created On       : Sat May 16 08:05:18 2015
12## Last Modified By : Peter A. Buhr
13## Last Modified On : Mon May 25 16:14:54 2015
14## Update Count     : 7
15###############################################################################
16
17INSTALL=@INSTALL@
18BACKEND_CC := @BACKEND_CC@
19CFA_LIBDIR = @CFA_LIBDIR@
20
21LIBRARIES := libcfa.a
22
23all : ${LIBRARIES} builtins.cf Makefile
24
25install : all
26        ${INSTALL} -d @CFA_LIBDIR@
27        ${INSTALL} prelude.cf @CFA_LIBDIR@
28        ${INSTALL} libcfa.a @CFA_LIBDIR@
29
30# make forward declarations for gcc builtins
31builtins.cf : builtins.c
32        if [ -e builtins.c ] ; then \
33                @BACKEND_CC@ -E -P $^ | sed -e "/targetm/s/.*//" -e "/_Decimal/s/.*//" -e "s/void (const char \*)0();//" -e "s/\"//g" -e "s/\(__builtin_\) /\1/" > $@ ; \
34        fi
35        ${INSTALL} builtins.cf @CFA_LIBDIR@
36
37builtins.c : builtins.def prototypes.awk
38        if [ -e builtins.def ] ; then \
39                @BACKEND_CC@ -E prototypes.c | awk -f prototypes.awk > $@ ; \
40        fi
41
42builtins.def :
43
44libcfa-prelude.c : @CFA_LIBDIR@/cfa-cpp prelude.cf builtins.cf
45        sed -i -e "s#typedef.*ptrdiff_t.*#`@BACKEND_CC@ -E ptrdiff_t.c | grep 'typedef.*ptrdiff_t'`#" prelude.cf
46        @CFA_LIBDIR@/cfa-cpp -l prelude.cf $@
47        rm -f prelude.c
48
49libcfa-prelude.o : libcfa-prelude.c
50        ${BACKEND_CC} -c -o $@ $<
51
52libcfa.a : libcfa-prelude.o
53        ar crs $@ $^
54
55EXTRA_OUTPUT += libcfa-prelude.o libcfa-prelude.c
56
57# clean-up rule
58clean :
59        rm -f ${LIBRARIES} ${EXTRA_OUTPUT}
60
61distclean : clean
Note: See TracBrowser for help on using the repository browser.