Commit 5782ca36 authored by thomas's avatar thomas
Browse files

autoconf files (by Tim Blechmann)


git-svn-id: https://svn.grrrr.org/ext/trunk@852 4d9ac71a-51e6-0310-8455-cad1006bcd31
parent 926b58ae
#
# automake template
# added by tim blechmann
#
SUBDIRS = source
EXTRA_DIST = flext.doxy examples tutorial
AUTOMAKE_OPTIONS = foreign
\ No newline at end of file
#! /bin/sh
aclocal \
&& automake --add-missing \
&& autoconf
dnl
dnl autoconf template
dnl added by tim blechmann
dnl
AC_INIT([flext],[0.4.7],[gr@grrrr.org],[flext])
AM_INIT_AUTOMAKE(1.8)
dnl configure options
AC_ARG_ENABLE(system, [ --enable-system flext system (default: pd)],
[
case $enableval in
max) AC_DEFINE(FLEXT_SYS,1);;
*) AC_DEFINE(FLEXT_SYS,2);;
esac
],
AC_DEFINE(FLEXT_SYS,2))
AC_ARG_ENABLE(sysdir,
[ --enable-sysdir path to pd or max headers],
[
INCLUDEDIR="-I$enableval $INCLUDEDIR"
]
)
AC_ARG_ENABLE(stkdir,
[ --enable-stkdir path to stk headers],
[
stkdir=$enableval
INCLUDEDIR="-I$enableval $INCLUDEDIR"
])
AC_ARG_ENABLE(sndobjdir,
[ --enable-sndobjdir path to SndObj headers],
[
sndobjdir=$enableval
INCLUDEDIR="-I$enableval $INCLUDEDIR"
])
AM_CONDITIONAL([STK],[test "$stkdir"])
AM_CONDITIONAL([SNDOBJ],[test "$sndobjdir"])
AC_ARG_ENABLE(optimize, [ --enable-optimize enables optimized builds for: pentium4, pentium3, G4, G5],
[
case $enableval in
pentium4)
OPT_FLAGS = "-mtune=pentium4 -march=pentium4 -mmmx -msse -msse2 -mfpmath=sse";;
pentium3)
OPT_FLAGS = "-mtune=pentium3 -march=pentium3 -mmmx -msse -mfpmath=sse";;
pentium2)
OPT_FLAGS="-mtune=pentium2 -march=pentium2 -mmmx";;
pentium)
OPT_FLAGS="-mtune=pentium -march=pentium";;
G5)
OPT_FLAGS="-march=G5 -mcpu=G5 -maltivec -faltivec -malign-natural";
AC_DEFINE(FLEXT_USE_SIMD);;
G4)
OPT_FLAGS="-march=G4 -mcpu=G4 -maltivec -faltivec -malign-natural";
AC_DEFINE(FLEXT_USE_SIMD);;
G3)
OPT_FLAGS="-mtune=G3 -mcpu=G3 -malign-natural";;
*)
;;
esac
])
dnl Checks for programs.
AC_PROG_CC
AC_PROG_CXX
AC_PROG_INSTALL
AC_PROG_MAKE_SET
AC_PROG_LIBTOOL
dnl Checks for libraries.
dnl Checks for header files.
dnl Checks for typedefs, structures, and compiler characteristics.
AC_C_CONST
AC_C_INLINE
AC_TYPE_SIZE_T
AC_STRUCT_TM
dnl Checks for library functions.
dnl system specific
if test 'uname -s' == Linux; then
DYNAMIC_LDFLAGS = -Wl,-Bdynamic
fi
if test 'uname -s' == Darwin; then
DYNAMIC_LDFLAGS = "-dylib -dynamic -flat_namespace -undefined suppress"
fi
AC_SUBST(INCLUDEDIR)
AC_SUBST(OPT_FLAGS)
AC_SUBST(DYNAMIC_LDFLAGS)
AC_SUBST(stkdir)
AC_SUBST(sndobjdir)
AC_OUTPUT([Makefile
source/Makefile])
#
# automake template
# added by tim blechmann
#
pkglib_LIBRARIES = libflext.a libflext_d.a libflext_t.a libflext_td.a
pkglib_LTLIBRARIES = libflext.la libflext_d.la
SRCS_FLEXT = \
flbase.cpp \
flext.cpp \
flbuf.cpp \
fldsp.cpp \
fllib.cpp \
flxlet.cpp \
flattr.cpp \
flattr_ed.cpp \
flsupport.cpp \
flutil.cpp \
flatom.cpp \
flatom_pr.cpp \
flthr.cpp \
fltimer.cpp \
flsimd.cpp \
flout.cpp \
flatom_app.cpp \
flatom_part.cpp \
flitem.cpp \
flmeth.cpp \
flmsg.cpp \
flproxy.cpp \
flqueue.cpp \
flbind.cpp
pkginclude_HEADERS = \
flprefix.h \
flstdc.h \
flbase.h \
flclass.h \
flext.h \
flsupport.h \
flmap.h \
fldsp.h \
flinternal.h \
fldefs.h \
fldefs_hdr.h \
fldefs_setup.h \
fldefs_methcb.h \
fldefs_meththr.h \
fldefs_methadd.h \
fldefs_methbind.h \
fldefs_methcall.h \
fldefs_attrcb.h \
fldefs_attrvar.h \
fldefs_attradd.h
#handling for stk / sndobj
SRCS_STK = flstk.cpp
HDRS_STK = flstk.cpp
SRCS_SNDOBJ = flsndobj.cpp
HDRS_SNDOBJ = flsndobj.cpp
if SNDOBJ
SRCS_FLEXT += $(SRCS_SNDOBJ)
pkginclude_HEADERS += $(HDRS_SNDOBJ)
LIB_SNDOBJ = sndobj
endif
if STK
SRCS_FLEXT += $(SRCS_STK)
pkginclude_HEADERS += $(HDRS_STK)
LIB_STK = stk
endif
libflext_a_SOURCES = $(SRCS_FLEXT)
libflext_d_a_SOURCES = $(SRCS_FLEXT)
libflext_t_a_SOURCES = $(SRCS_FLEXT)
libflext_td_a_SOURCES = $(SRCS_FLEXT)
libflext_la_SOURCES = $(SRCS_FLEXT)
libflext_d_la_SOURCES = $(SRCS_FLEXT)
libflext_a_CXXFLAGS = @OPT_FLAGS@ @INCLUDEDIR@
libflext_d_a_CXXFLAGS = @INCLUDEDIR@ -g -DFLEXT_DEBUG
libflext_t_a_CXXFLAGS = @OPT_FLAGS@ @INCLUDEDIR@ -DFLEXT_THREADS
libflext_td_a_CXXFLAGS = @INCLUDEDIR@ -g -DFLEXT_DEBUG -DFLEXT_THREADS
libflext_la_CXXFLAGS = @OPT_FLAGS@ @INCLUDEDIR@ -DFLEXT_SHARED \
-DFLEXT_EXPORTS
libflext_d_la_CXXFLAGS = @INCLUDEDIR@ -g -DFLEXT_DEBUG -DFLEXT_SHARED \
-DFLEXT_EXPORTS
libflext_la_LDFLAGS = @DYNAMIC_LDFLAGS@ -l$(LIB_STK) -l$(LIB_SNDOBJ)
libflext_d_la_LDFLAGS = @DYNAMIC_LDFLAGS@ -l$(LIB_STK) -l$(LIB_SNDOBJ)
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment