Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • libcfa/src/Makefile.am

    re523b07 r38d12e7  
    1717# create object files in directory with source files
    1818AUTOMAKE_OPTIONS = foreign subdir-objects
     19ACLOCAL_AMFLAGS  = -I automake
    1920ARFLAGS = cr
    2021
     
    2223
    2324libdir = ${CFA_LIBDIR}
    24 lib_LIBRARIES =  libcfa.a
    25 
    26 VPATH += :../prelude
     25lib_LTLIBRARIES =  libcfa.la
    2726
    2827# AM_CFLAGS for all cfa source
     
    3029# use -no-include-stdhdr to prevent rebuild cycles
    3130# The built sources must not depend on the installed headers
    32 AM_CFAFLAGS = -quiet -in-tree -I$(srcdir)/stdhdr @CONFIG_CFAFLAGS@
    33 AM_CFLAGS = -g -Wall -Wno-unused-function @ARCH_FLAGS@ @CONFIG_CFLAGS@
     31AM_CFAFLAGS = -quiet -in-tree -imacros prelude.c -I$(srcdir)/stdhdr @CONFIG_CFAFLAGS@
     32AM_CFLAGS = -g -Wall -Wno-unused-function -fPIC @ARCH_FLAGS@ @CONFIG_CFLAGS@
    3433AM_CCASFLAGS = -g -Wall -Wno-unused-function @ARCH_FLAGS@ @CONFIG_CFLAGS@
    3534CFACC = @CFACC@
    3635
    3736#----------------------------------------------------------------------------------------------------------------
    38 if BUILDLIB
    3937headers = fstream.hfa iostream.hfa iterator.hfa limits.hfa rational.hfa time.hfa stdlib.hfa common.hfa \
    4038          containers/maybe.hfa containers/pair.hfa containers/result.hfa containers/vector.hfa
    41 
    42 headers_nosrc = math.hfa gmp.hfa time_t.hfa bits/align.hfa bits/containers.hfa bits/defs.hfa bits/debug.hfa bits/locks.hfa
    4339
    4440# not all platforms support concurrency, add option do disable it
    4541headers += concurrency/coroutine.hfa concurrency/thread.hfa concurrency/kernel.hfa concurrency/monitor.hfa concurrency/mutex.hfa
    4642
    47 headers_nosrc += concurrency/invoke.h
    48 
    49 libsrc = startup.cfa interpose.cfa bits/debug.cfa assert.cfa exception.c virtual.c heap.cfa ${headers:.hfa=.cfa}
     43libobjs = ${headers:.hfa=.lo}
     44libsrc = prelude.c startup.cfa interpose.cfa bits/debug.cfa assert.cfa exception.c virtual.c heap.cfa \
     45        ${headers:.hfa=.cfa}
    5046
    5147# not all platforms support concurrency, add option do disable it
    5248libsrc += concurrency/CtxSwitch-@ARCHITECTURE@.S concurrency/alarm.cfa concurrency/invoke.c concurrency/preemption.cfa
    53 else
    54 headers =
    55 headers_nosrc =
    56 libsrc =
    57 endif
    58 
    5949
    6050#----------------------------------------------------------------------------------------------------------------
    6151# add dependency to cfa-cpp so all libraries are rebuilt with new translator
    62 #@CFACC@ @CFACPP@ prelude.cfa
     52${libobjs} : ${cfalib_DATA}
    6353
    64 # add dependency of cfa files
    65 libobjs = $(addsuffix .o, $(basename $(filter %.cfa,$(libsrc))))
    66 $(libobjs) : @CFACC@ @CFACPP@ prelude.cfa
     54libcfa_la_SOURCES = ${libsrc}
    6755
    68 
    69 # .deps inclusion is not done automatically by automake for new languages
    70 libdeps = $(join \
    71         $(addsuffix $(DEPDIR)/ , $(dir $(libobjs) ) ), \
    72         $(notdir ${libobjs:.o=.Po}) \
    73 )
    74 
    75 -include $(libdeps)
    76 
    77 prelude.o : prelude.cfa extras.cf gcc-builtins.cf builtins.cf @CFACC@ @CFACPP@
    78         ${AM_V_GEN}@CFACC@ ${AM_CFLAGS} ${CFLAGS} -quiet -in-tree -XCFA -l ${<} -c -o ${@}
    79 
    80 
    81 
    82 #----------------------------------------------------------------------------------------------------------------
    83 libcfa_a_SOURCES = prelude.cfa ${libsrc}
    84 
    85 stdhdr = ${shell find ${srcdir}/stdhdr -type f -printf "%p "}
     56stdhdr = $(shell find $(srcdir)/stdhdr -type f -printf "%p ")
    8657
    8758cfa_includedir = $(CFA_INCDIR)
    88 nobase_cfa_include_HEADERS = ${stdhdr} ${headers} ${headers_nosrc}
     59nobase_cfa_include_HEADERS = \
     60        ${headers}             \
     61        ${stdhdr}              \
     62        math.hfa               \
     63        gmp.hfa                \
     64        time_t.hfa             \
     65        bits/align.hfa         \
     66        bits/containers.hfa    \
     67        bits/defs.hfa          \
     68        bits/debug.hfa         \
     69        bits/locks.hfa         \
     70        concurrency/invoke.h
     71
     72MOSTLYCLEANFILES = prelude.c
    8973
    9074#----------------------------------------------------------------------------------------------------------------
    9175maintainer-clean-local:
    9276        -rm -rf ${CFA_INCDIR} ${CFA_LIBDIR}
    93 
    94 
    95 # $(AM_V_CFA)depbase=`echo $@ | sed 's|[^/]*$$|$(DEPDIR)/&|;s|\.o$$||'`;\
    96 #       $(CFACOMPILE) -MT $@ -MD -MP -MF $$depbase.Tpo -c -o $@ $< &&\
    97 #       $(am__mv) $$depbase.Tpo $$depbase.Po
Note: See TracChangeset for help on using the changeset viewer.