source: libcfa/src/Makefile.am @ bbfd0e0

arm-ehenumforall-pointer-decayjacob/cs343-translationjenkins-sandboxnew-astnew-ast-unique-exprpthread-emulationqualifiedEnum
Last change on this file since bbfd0e0 was bbfd0e0, checked in by Thierry Delisle <tdelisle@…>, 3 years ago

Tentative support for distcc in cforall, right now nothing works because distcc doesn't understand cfa

  • Property mode set to 100644
File size: 4.3 KB
Line 
1######################## -*- Mode: Makefile-Automake -*- ######################
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.am --
9##
10## Author           : Peter A. Buhr
11## Created On       : Sun May 31 08:54:01 2015
12## Last Modified By : Peter A. Buhr
13## Last Modified On : Mon Jul 15 22:43:27 2019
14## Update Count     : 241
15###############################################################################
16
17# create object files in directory with source files
18AUTOMAKE_OPTIONS = foreign subdir-objects
19ACLOCAL_AMFLAGS  = -I automake
20
21include $(srcdir)/../../src/cfa.make
22
23libdir = ${CFA_LIBDIR}
24lib_LTLIBRARIES = libcfa.la libcfathread.la
25
26VPATH += :../prelude
27
28# AM_CFLAGS for all cfa source
29# AM_CFAFLAGS for only cfa source
30# use -no-include-stdhdr to prevent rebuild cycles
31# The built sources must not depend on the installed headers
32AM_CFAFLAGS = -v @PRELUDEFLAG@ -I$(srcdir)/stdhdr @CONFIG_CFAFLAGS@
33AM_CFLAGS = -g -Wall -Wno-unused-function -fPIC @ARCH_FLAGS@ @CONFIG_CFLAGS@
34AM_CCASFLAGS = -g -Wall -Wno-unused-function @ARCH_FLAGS@ @CONFIG_CFLAGS@
35CFACC = @CFACC@
36
37#----------------------------------------------------------------------------------------------------------------
38if BUILDLIB
39headers_nosrc = math.hfa gmp.hfa time_t.hfa bits/align.hfa bits/containers.hfa bits/defs.hfa bits/debug.hfa bits/locks.hfa
40headers = fstream.hfa iostream.hfa iterator.hfa limits.hfa rational.hfa time.hfa stdlib.hfa common.hfa \
41          containers/maybe.hfa containers/pair.hfa containers/result.hfa containers/vector.hfa
42
43libsrc = startup.cfa interpose.cfa bits/debug.cfa assert.cfa exception.c virtual.c heap.cfa ${headers:.hfa=.cfa}
44
45# not all platforms support concurrency, add option do disable it
46thread_headers_nosrc = concurrency/invoke.h
47thread_headers = concurrency/coroutine.hfa concurrency/thread.hfa concurrency/kernel.hfa concurrency/monitor.hfa concurrency/mutex.hfa
48thread_libsrc = concurrency/CtxSwitch-@ARCHITECTURE@.S concurrency/alarm.cfa concurrency/invoke.c concurrency/preemption.cfa ${thread_headers:.hfa=.cfa}
49else
50headers =
51thread_headers =
52headers_nosrc =
53thread_headers_nosrc =
54libsrc =
55endif
56
57
58#----------------------------------------------------------------------------------------------------------------
59# add dependency to cfa-cpp so all libraries are rebuilt with new translator
60#@CFACC@ @CFACPP@ prelude.cfa
61
62# add dependency of cfa files
63libobjs = $(addsuffix .lo, $(basename $(filter %.cfa,$(libsrc))))
64$(libobjs) : @LOCAL_CFACC@ @LOCAL_CFACPP@ prelude.cfa
65
66thread_libobjs = $(addsuffix .lo, $(basename $(filter %.cfa,$(thread_libsrc))))
67$(thread_libobjs) : @LOCAL_CFACC@ @LOCAL_CFACPP@ prelude.cfa
68
69
70# .deps inclusion is not done automatically by automake for new languages
71libdeps = $(join \
72        $(addsuffix $(DEPDIR)/ , $(dir $(libobjs) ) ), \
73        $(notdir ${libobjs:.lo=.Plo}) \
74)
75
76-include $(libdeps)
77
78thread_libdeps = $(join \
79        $(addsuffix $(DEPDIR)/ , $(dir $(thread_libobjs) ) ), \
80        $(notdir ${thread_libobjs:.lo=.Plo}) \
81)
82
83-include $(thread_libdeps)
84
85
86prelude.o : prelude.cfa extras.cf gcc-builtins.cf builtins.cf @LOCAL_CFACC@ @LOCAL_CFACPP@
87        ${AM_V_GEN}$(CFACOMPILE) -quiet @PRELUDEFLAG@ -XCFA -l ${<} -c -o ${@}
88
89prelude.lo: prelude.cfa extras.cf gcc-builtins.cf builtins.cf @LOCAL_CFACC@ @LOCAL_CFACPP@
90        ${AM_V_GEN}$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile \
91        $(CFACOMPILE) -quiet @PRELUDEFLAG@ -XCFA -l ${<} -c -o ${@}
92
93
94#----------------------------------------------------------------------------------------------------------------
95libcfa_la_SOURCES = prelude.cfa ${libsrc}
96libcfa_la_LDFLAGS = -version-info @CFA_VERSION@
97
98libcfathread_la_SOURCES = ${thread_libsrc}
99libcfathread_la_LDFLAGS = -version-info @CFA_VERSION@
100
101stdhdr = $(shell find $(srcdir)/stdhdr -type f -printf "%p ")
102
103cfa_includedir = $(CFA_INCDIR)
104nobase_cfa_include_HEADERS = ${stdhdr} ${headers} ${headers_nosrc} ${thread_headers} ${thread_headers_nosrc}
105
106#----------------------------------------------------------------------------------------------------------------
107maintainer-clean-local:
108        -rm -rf ${CFA_INCDIR} ${CFA_LIBDIR}
109
110
111# $(AM_V_CFA)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.o$$||'`;\
112#       $(CFACOMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\
113#       $(am__mv) $$depbase.Tpo $$depbase.Po
Note: See TracBrowser for help on using the repository browser.