aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans-Christoph Steiner <eighthave@users.sourceforge.net>2004-04-05 04:26:00 +0000
committerHans-Christoph Steiner <eighthave@users.sourceforge.net>2004-04-05 04:26:00 +0000
commit64e913d255cc53b7b0791f07d8e85ca2f2eca108 (patch)
treeff25610d2ccc1bd425f3d11cb51d427b750cd26c
parent4ddc89a36ab33d0b660b7312b9b9f9557e820a78 (diff)
made unified autoconf build, should work with MinGW also
svn path=/trunk/externals/OSCx/; revision=1550
-rw-r--r--Makefile.in2
-rwxr-xr-xconfigure241
-rw-r--r--configure.ac71
-rw-r--r--send+dump/Makefile.in5
-rw-r--r--src/Makefile.in90
-rw-r--r--src/OSC.c4
6 files changed, 189 insertions, 224 deletions
diff --git a/Makefile.in b/Makefile.in
index 5abb7ae..d4aa84b 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -2,8 +2,8 @@ dirs = libOSC send+dump src
all:
cd libOSC ; make
- cd send+dump ; make
cd src ; make
+ cd send+dump ; make
install: all
cd src ; make install
diff --git a/configure b/configure
index bfae3e0..84d4993 100755
--- a/configure
+++ b/configure
@@ -310,7 +310,7 @@ ac_includes_default="\
# include <unistd.h>
#endif"
-ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT LN_S CPP build build_cpu build_vendor build_os host host_cpu host_vendor host_os EGREP LIBOBJS pd_suffix INCLUDES LTLIBOBJS'
+ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT LN_S CPP EGREP LIBOBJS LIBOSC pd_suffix INCLUDES LTLIBOBJS'
ac_subst_files=''
# Initialize some variables set by options.
@@ -1279,6 +1279,87 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu
ac_config_headers="$ac_config_headers config.h"
+# get system type
+ac_aux_dir=
+for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
+ if test -f $ac_dir/install-sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install-sh -c"
+ break
+ elif test -f $ac_dir/install.sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install.sh -c"
+ break
+ elif test -f $ac_dir/shtool; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/shtool install -c"
+ break
+ fi
+done
+if test -z "$ac_aux_dir"; then
+ { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
+echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
+ { (exit 1); exit 1; }; }
+fi
+ac_config_guess="$SHELL $ac_aux_dir/config.guess"
+ac_config_sub="$SHELL $ac_aux_dir/config.sub"
+ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
+
+# Make sure we can run config.sub.
+$ac_config_sub sun4 >/dev/null 2>&1 ||
+ { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
+echo "$as_me: error: cannot run $ac_config_sub" >&2;}
+ { (exit 1); exit 1; }; }
+
+echo "$as_me:$LINENO: checking build system type" >&5
+echo $ECHO_N "checking build system type... $ECHO_C" >&6
+if test "${ac_cv_build+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_cv_build_alias=$build_alias
+test -z "$ac_cv_build_alias" &&
+ ac_cv_build_alias=`$ac_config_guess`
+test -z "$ac_cv_build_alias" &&
+ { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
+echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
+ { (exit 1); exit 1; }; }
+ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
+ { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
+echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
+ { (exit 1); exit 1; }; }
+
+fi
+echo "$as_me:$LINENO: result: $ac_cv_build" >&5
+echo "${ECHO_T}$ac_cv_build" >&6
+build=$ac_cv_build
+build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
+build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
+build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
+
+
+echo "$as_me:$LINENO: checking host system type" >&5
+echo $ECHO_N "checking host system type... $ECHO_C" >&6
+if test "${ac_cv_host+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_cv_host_alias=$host_alias
+test -z "$ac_cv_host_alias" &&
+ ac_cv_host_alias=$ac_cv_build_alias
+ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
+ { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
+echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
+ { (exit 1); exit 1; }; }
+
+fi
+echo "$as_me:$LINENO: result: $ac_cv_host" >&5
+echo "${ECHO_T}$ac_cv_host" >&6
+host=$ac_cv_host
+host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
+host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
+host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
+
+
+
# Checks for programs.
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
@@ -2402,86 +2483,6 @@ echo "default flags"
echo cflags "$CFLAGS"
echo ldflags "$LDFLAGS"
-ac_aux_dir=
-for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
- if test -f $ac_dir/install-sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f $ac_dir/install.sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- elif test -f $ac_dir/shtool; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/shtool install -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
-echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
- { (exit 1); exit 1; }; }
-fi
-ac_config_guess="$SHELL $ac_aux_dir/config.guess"
-ac_config_sub="$SHELL $ac_aux_dir/config.sub"
-ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
-
-# Make sure we can run config.sub.
-$ac_config_sub sun4 >/dev/null 2>&1 ||
- { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
-echo "$as_me: error: cannot run $ac_config_sub" >&2;}
- { (exit 1); exit 1; }; }
-
-echo "$as_me:$LINENO: checking build system type" >&5
-echo $ECHO_N "checking build system type... $ECHO_C" >&6
-if test "${ac_cv_build+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- ac_cv_build_alias=$build_alias
-test -z "$ac_cv_build_alias" &&
- ac_cv_build_alias=`$ac_config_guess`
-test -z "$ac_cv_build_alias" &&
- { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
-echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
- { (exit 1); exit 1; }; }
-ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
- { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
-echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
- { (exit 1); exit 1; }; }
-
-fi
-echo "$as_me:$LINENO: result: $ac_cv_build" >&5
-echo "${ECHO_T}$ac_cv_build" >&6
-build=$ac_cv_build
-build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-
-
-echo "$as_me:$LINENO: checking host system type" >&5
-echo $ECHO_N "checking host system type... $ECHO_C" >&6
-if test "${ac_cv_host+set}" = set; then
- echo $ECHO_N "(cached) $ECHO_C" >&6
-else
- ac_cv_host_alias=$host_alias
-test -z "$ac_cv_host_alias" &&
- ac_cv_host_alias=$ac_cv_build_alias
-ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
- { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
-echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
- { (exit 1); exit 1; }; }
-
-fi
-echo "$as_me:$LINENO: result: $ac_cv_host" >&5
-echo "${ECHO_T}$ac_cv_host" >&6
-host=$ac_cv_host
-host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-
-
-
# Checks for libraries.
# FIXME: Replace `main' with a function in `-lc':
@@ -2856,7 +2857,8 @@ done
-for ac_header in arpa/inet.h fcntl.h netdb.h netinet/in.h stdlib.h string.h strings.h sys/file.h sys/ioctl.h sys/param.h sys/socket.h sys/time.h unistd.h
+
+for ac_header in arpa/inet.h fcntl.h netdb.h netinet/in.h stdlib.h string.h strings.h sys/file.h sys/ioctl.h sys/param.h sys/socket.h sys/time.h unistd.h sys/prctl.h
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
if eval "test \"\${$as_ac_Header+set}\" = set"; then
@@ -4112,8 +4114,8 @@ _ACEOF
# from augusts template
-INCLUDES="-I../libOSC -I../../../pd/src"
-LDFLAGS="$LDFLAGS -L/usr/local/lib -ldl"
+INCLUDES="-I../libOSC -I../../pd/src -I../../../pd/src -I."
+LIBOSC=libOSC.a
if test -z "$GCC"; then
case $host in
*-*-irix*)
@@ -4123,44 +4125,50 @@ if test -z "$GCC"; then
;;
sparc-sun-solaris*)
CFLAGS="-xO4 -fast -w -fsimple -native -xcg92"
- ;;
+ ;;
*)
CFLAGS="-O"
- ;;
+ ;;
esac
else
-
case $host in
*86-*-linux*)
CFLAGS="$CFLAGS -DUNIX -Wall -Wimplicit -Wunused -Wmissing-prototypes -O2"
- LDFLAGS="$LDFLAGS -shared"
- pd_suffix=pd_linux
- ;;
+ LDFLAGS="-Wl,-export_dynamic -shared"
+ pd_suffix=pd_linux
+ ;;
powerpc-*-linux*)
CFLAGS="$CFLAGS -DUNIX -Wall -Wimplicit -Wunused -Wmissing-prototypes -O1"
- LDFLAGS="$LDFLAGS -shared"
- pd_suffix=pd_linux
- ;;
+ LDFLAGS="-Wl,-export_dynamic -shared"
+ pd_suffix=pd_linux
+ ;;
*-*-linux*)
CFLAGS="$CFLAGS -DUNIX -Wall -Wimplicit -Wunused -Wmissing-prototypes -O1"
- LDFLAGS="$LDFLAGS -shared"
- INCLUDES="$INCLUDES"
- pd_suffix=pd_linux
- ;;
+ LDFLAGS="-Wl,-export_dynamic -shared"
+ INCLUDES="$INCLUDES"
+ pd_suffix=pd_linux
+ ;;
sparc-sun-*)
- echo "YOU HAVE A SPARC STATION, not setting any flags, not supported yet"
- ;;
+ echo "YOU HAVE A SPARC STATION, not setting any flags, not supported yet"
+ ;;
+ *-*-cygwin*)
+ CFLAGS="$CPFLAGS -mno-cygwin -Wall -Wimplicit -Wunused -Wmissing-prototypes -O3 "
+ LDFLAGS="-Wl,-export_dynamic -shared"
+ INCLUDES="$INCLUDES -I../../../pd/bin"
+ LIBOSC=libOSC.lib
+ pd_suffix=dll
+ ;;
*-*-darwin*)
CFLAGS="$CPFLAGS -DUNIX -Wall -Wimplicit -Wunused -Wmissing-prototypes -O3 "
- # LDFLAGS="$LDFLAGS -bundle -bundle_loader ../../../pd/bin/pd -undefined suppress -flat_namespace"
- LDFLAGS="$LDFLAGS -bundle -bundle_loader ../../../pd/bin/pd -flat_namespace"
- pd_suffix=pd_darwin
- ;;
+ # LDFLAGS=" -bundle -bundle_loader ../../../pd/bin/pd -undefined suppress -flat_namespace"
+ LDFLAGS=" -bundle -bundle_loader ../../../pd/bin/pd -flat_namespace "
+ pd_suffix=pd_darwin
+ ;;
*)
- CFLAGS="$CFLAGS -DUNIX -Wall -Wimplicit -Wunused -Wmissing-prototypes -O1"
- LDFLAGS="$LDFLAGS -shared"
- pd_suffix=pd_linux
- ;;
+ CFLAGS="$CFLAGS -DUNIX -Wall -Wimplicit -Wunused -Wmissing-prototypes -O1"
+ LDFLAGS="-Wl,-export_dynamic -shared"
+ pd_suffix=pd_linux
+ ;;
esac
fi
@@ -4331,6 +4339,8 @@ fi
+
+
ac_config_files="$ac_config_files src/Makefile libOSC/Makefile send+dump/Makefile Makefile"
@@ -4946,6 +4956,14 @@ s,@ECHO_C@,$ECHO_C,;t t
s,@ECHO_N@,$ECHO_N,;t t
s,@ECHO_T@,$ECHO_T,;t t
s,@LIBS@,$LIBS,;t t
+s,@build@,$build,;t t
+s,@build_cpu@,$build_cpu,;t t
+s,@build_vendor@,$build_vendor,;t t
+s,@build_os@,$build_os,;t t
+s,@host@,$host,;t t
+s,@host_cpu@,$host_cpu,;t t
+s,@host_vendor@,$host_vendor,;t t
+s,@host_os@,$host_os,;t t
s,@CC@,$CC,;t t
s,@CFLAGS@,$CFLAGS,;t t
s,@LDFLAGS@,$LDFLAGS,;t t
@@ -4955,16 +4973,9 @@ s,@EXEEXT@,$EXEEXT,;t t
s,@OBJEXT@,$OBJEXT,;t t
s,@LN_S@,$LN_S,;t t
s,@CPP@,$CPP,;t t
-s,@build@,$build,;t t
-s,@build_cpu@,$build_cpu,;t t
-s,@build_vendor@,$build_vendor,;t t
-s,@build_os@,$build_os,;t t
-s,@host@,$host,;t t
-s,@host_cpu@,$host_cpu,;t t
-s,@host_vendor@,$host_vendor,;t t
-s,@host_os@,$host_os,;t t
s,@EGREP@,$EGREP,;t t
s,@LIBOBJS@,$LIBOBJS,;t t
+s,@LIBOSC@,$LIBOSC,;t t
s,@pd_suffix@,$pd_suffix,;t t
s,@INCLUDES@,$INCLUDES,;t t
s,@LTLIBOBJS@,$LTLIBOBJS,;t t
diff --git a/configure.ac b/configure.ac
index 56e1794..49ad817 100644
--- a/configure.ac
+++ b/configure.ac
@@ -6,6 +6,9 @@ AC_INIT(OSCxpd, 0.2, jdl@xdv.org)
AC_CONFIG_SRCDIR([libOSC/OSC-client.h])
AC_CONFIG_HEADER([config.h])
+# get system type
+AC_CANONICAL_HOST
+
# Checks for programs.
AC_PROG_CC
AC_PROG_LN_S
@@ -24,12 +27,6 @@ echo "default flags"
echo cflags "$CFLAGS"
echo ldflags "$LDFLAGS"
-dnl ------------------------------------------
-dnl ---- do some magic to gues the host opsys
-dnl ---- taken from libvorbis configure.in
-dnl ------------------------------------------
-AC_CANONICAL_HOST
-
# Checks for libraries.
# FIXME: Replace `main' with a function in `-lc':
AC_CHECK_LIB([c], [main])
@@ -38,7 +35,7 @@ AC_CHECK_LIB([m], [main])
# Checks for header files.
AC_HEADER_STDC
-AC_CHECK_HEADERS([arpa/inet.h fcntl.h netdb.h netinet/in.h stdlib.h string.h strings.h sys/file.h sys/ioctl.h sys/param.h sys/socket.h sys/time.h unistd.h])
+AC_CHECK_HEADERS([arpa/inet.h fcntl.h netdb.h netinet/in.h stdlib.h string.h strings.h sys/file.h sys/ioctl.h sys/param.h sys/socket.h sys/time.h unistd.h sys/prctl.h])
# Checks for typedefs, structures, and compiler characteristics.
AC_HEADER_STDBOOL
@@ -60,8 +57,8 @@ dnl for each of the *-*-host's in the following, do the checking and then set y
dnl CFLAGS get set for C code, CPPFLAGS for c++ code. LDFLAGS is the linking flags for both c and c++
dnl ------------------------------------------
-INCLUDES="-I../libOSC -I../../../pd/src"
-LDFLAGS="$LDFLAGS -L/usr/local/lib -ldl"
+INCLUDES="-I../libOSC -I../../pd/src -I../../../pd/src -I."
+LIBOSC=libOSC.a
if test -z "$GCC"; then
case $host in
*-*-irix*)
@@ -73,46 +70,52 @@ if test -z "$GCC"; then
;;
sparc-sun-solaris*)
CFLAGS="-xO4 -fast -w -fsimple -native -xcg92"
- ;;
+ ;;
*)
CFLAGS="-O"
- ;;
+ ;;
esac
else
-
case $host in
*86-*-linux*)
CFLAGS="$CFLAGS -DUNIX -Wall -Wimplicit -Wunused -Wmissing-prototypes -O2"
- LDFLAGS="$LDFLAGS -shared"
- dnl we could test for bad glibc here, but don't
- pd_suffix=pd_linux
- ;;
+ LDFLAGS="-Wl,-export_dynamic -shared"
+ dnl we could test for bad glibc here, but don't
+ pd_suffix=pd_linux
+ ;;
powerpc-*-linux*)
CFLAGS="$CFLAGS -DUNIX -Wall -Wimplicit -Wunused -Wmissing-prototypes -O1"
- LDFLAGS="$LDFLAGS -shared"
- pd_suffix=pd_linux
- ;;
+ LDFLAGS="-Wl,-export_dynamic -shared"
+ pd_suffix=pd_linux
+ ;;
*-*-linux*)
CFLAGS="$CFLAGS -DUNIX -Wall -Wimplicit -Wunused -Wmissing-prototypes -O1"
- LDFLAGS="$LDFLAGS -shared"
- INCLUDES="$INCLUDES"
- pd_suffix=pd_linux
- ;;
+ LDFLAGS="-Wl,-export_dynamic -shared"
+ INCLUDES="$INCLUDES"
+ pd_suffix=pd_linux
+ ;;
sparc-sun-*)
- echo "YOU HAVE A SPARC STATION, not setting any flags, not supported yet"
- ;;
+ echo "YOU HAVE A SPARC STATION, not setting any flags, not supported yet"
+ ;;
+ *-*-cygwin*)
+ CFLAGS="$CPFLAGS -mno-cygwin -Wall -Wimplicit -Wunused -Wmissing-prototypes -O3 "
+ LDFLAGS="-Wl,-export_dynamic -shared"
+ INCLUDES="$INCLUDES -I../../../pd/bin"
+ LIBOSC=libOSC.lib
+ pd_suffix=dll
+ ;;
*-*-darwin*)
CFLAGS="$CPFLAGS -DUNIX -Wall -Wimplicit -Wunused -Wmissing-prototypes -O3 "
- # LDFLAGS="$LDFLAGS -bundle -bundle_loader ../../../pd/bin/pd -undefined suppress -flat_namespace"
- LDFLAGS="$LDFLAGS -bundle -bundle_loader ../../../pd/bin/pd -flat_namespace"
- pd_suffix=pd_darwin
- ;;
+ # LDFLAGS=" -bundle -bundle_loader ../../../pd/bin/pd -undefined suppress -flat_namespace"
+ LDFLAGS=" -bundle -bundle_loader ../../../pd/bin/pd -flat_namespace "
+ pd_suffix=pd_darwin
+ ;;
*)
- dnl assume unix
+ dnl assume unix
CFLAGS="$CFLAGS -DUNIX -Wall -Wimplicit -Wunused -Wmissing-prototypes -O1"
- LDFLAGS="$LDFLAGS -shared"
- pd_suffix=pd_linux
- ;;
+ LDFLAGS="-Wl,-export_dynamic -shared"
+ pd_suffix=pd_linux
+ ;;
esac
fi
@@ -149,8 +152,10 @@ AC_CHECK_HEADER(m_pd.h, [have_pd_hdr=yes ], [
])
+AC_SUBST(LIBOSC)
AC_SUBST(pd_suffix)
AC_SUBST(INCLUDES)
+AC_SUBST(CFLAGS)
AC_CONFIG_FILES([src/Makefile
libOSC/Makefile
diff --git a/send+dump/Makefile.in b/send+dump/Makefile.in
index 2927d63..f7444a6 100644
--- a/send+dump/Makefile.in
+++ b/send+dump/Makefile.in
@@ -1,9 +1,8 @@
LIBOSCDIR = ../libOSC
LIBOSC = ${LIBOSCDIR}/libOSC.a
-# for eg. linux
-# DEFS= -Dunix
-CFLAGS= @CFLAGS@
+# strange bug requires this...
+CFLAGS= @CFLAGS@ @INCLUDES@
# INCLUDES= @INCLUDES@
DUMPOBJS=dumpOSC.o
diff --git a/src/Makefile.in b/src/Makefile.in
index 5fd81cd..03e256e 100644
--- a/src/Makefile.in
+++ b/src/Makefile.in
@@ -1,60 +1,36 @@
-# current: all
-# pd_linux
-###############################
-NAME=OSC
+
EXT=o
LIBS = -lm -lc
-LIBOSC = ../libOSC/libOSC.a
-DEFS= -Dunix
-
-prefix=$(DESTDIR)/usr
-
-current: @pd_suffix@
-
-# ----------------------- LINUX i386 -----------------------
-
-# pd_linux: $(NAME).pd_linux
+LIBOSC = ../libOSC/@LIBOSC@
-SFX=@pd_suffix@
+CFLAGS = @CFLAGS@
+INCLUDES = @INCLUDES@
+LDFLAGS = @LDFLAGS@
-.SUFFIXES: .$(SFX)
-
-CFLAGS += $(DEFS) -DPD -DUNIX -O2 -funroll-loops -fomit-frame-pointer \
- -Wall -W -Wshadow \
- -Wno-unused -Wno-parentheses -Wno-switch
-
-# where is your m_pd.h ???
-INCLUDE = -I../../build/include -I../libOSC
+prefix=$(DESTDIR)/usr
-# LINUXEXTERNALS = htmsocket.o OSC-pattern-match.o sendOSC.o dumpOSC.o OSCroute.o
-# SOURCES = $(wildcard *.c)
-SOURCES = OSC-pattern-match.c OSC.c dumpOSC.c \
-htmsocket.c OSCroute.c sendOSC.c
+SOURCES = OSC-pattern-match.c OSC.c dumpOSC.c htmsocket.c OSCroute.c sendOSC.c
TARGETS = $(SOURCES:.c=.o)
EXTS=sendOSC.@pd_suffix@ dumpOSC.@pd_suffix@ OSCroute.@pd_suffix@ OSC.@pd_suffix@
+# ----------------------- autoconf -----------------------
+
all: $(EXTS)
-sendOSC.pd_linux: htmsocket.o sendOSC.o
- cc -Wl,-export_dynamic -shared -o $*.@pd_suffix@ *.o -lc -lm ../libOSC/libOSC.a
-dumpOSC.pd_linux: dumpOSC.o
- cc -Wl,-export_dynamic -shared -o $*.@pd_suffix@ $*.o -lc -lm
-OSCroute.pd_linux: OSCroute.o OSC-pattern-match.o
- cc -Wl,-export_dynamic -shared -o $*.@pd_suffix@ $? -lc -lm
+sendOSC.@pd_suffix@: sendOSC.o htmsocket.o
+ cc $(LDFLAGS) -o sendOSC.@pd_suffix@ $? -lc -lm $(LIBOSC)
-OSC.pd_linux: OSC.o
- cc -Wl,-export_dynamic -shared -o $*.@pd_suffix@ $? -lc -lm
-# $(LD) $(LDFLAGS) -o OSC.$(EXT) *.$(EXT) *.o $(LIBS) $(LIBOSC)
-# $(LD) $(LDFLAGS) -o OSC.$(EXT) *.$(EXT) $(LIBS) $(LIBOSC)
-$(TARGETS): %.o : %.c
- cc $(CFLAGS) $(INCLUDE) -c -o $*.o $*.c
+dumpOSC.@pd_suffix@: dumpOSC.o
+ cc $(LDFLAGS) -o dumpOSC.@pd_suffix@ $? -lc -lm
+
+OSCroute.@pd_suffix@: OSCroute.o OSC-pattern-match.o
+ cc $(LDFLAGS) -o OSCroute.@pd_suffix@ $? -lc -lm
-# cc -c $(CFLAGS) OSC.c
+OSC.@pd_suffix@: OSC.o sendOSC.o dumpOSC.o OSCroute.o htmsocket.o OSC-pattern-match.o
+ cc $(LDFLAGS) -o OSC.@pd_suffix@ $? -lc -lm $(LIBOSC)
-# .c.pd_linux:
-# cc -O2 -Wall -DPD -fPIC $(LINUXCFLAGS) $(LINUXINCLUDE) -c *.c
-# ld -export_dynamic -shared -o $*.pd_linux $*.o $(LINUXEXTERNALS) $(LIBS) $(LIBOSC)
-# strip --strip-unneeded $*.pd_linux
+$(TARGETS): %.o : %.c
+ cc $(CFLAGS) $(INCLUDES) -c -o $*.o $*.c
# ----------------------------------------------------------
@@ -68,29 +44,3 @@ install: install-doc
clean:
rm -rf *.$(EXT) *.@pd_suffix@
-
-# ----------------------- Mac OS X (Darwin) -----------------------
-
-pd_darwin: $(NAME).pd_darwin
-
-SFX=.pd_darwin
-
-.SUFFIXES: $(SFX)
-
-DARWINCFLAGS = -DPD -DUNIX -O2 \
- -Wall -W -Wshadow -Wstrict-prototypes \
- -Wno-unused -Wno-parentheses -Wno-switch
-
-# where is your m_pd.h ???
-DARWININCLUDE = @INCLUDES@
-
-DARWINEXTERNALS = htmsocket.o OSC-pattern-match.o sendOSC.o dumpOSC.o OSCroute.o
-
-.c.pd_darwin:
- cc $(DARWINCFLAGS) $(DARWININCLUDE) -c *.c
- cc -bundle -bundle_loader ../../../pd/bin/pd -flat_namespace -o $*.pd_darwin $*.o $(DARWINEXTERNALS) $(LIBS) $(LIBOSC)
-
- rm -f $*.o ../$*.pd_darwin
-# ln -s $*/$*.pd_darwin ..
-
-
diff --git a/src/OSC.c b/src/OSC.c
index 1b94a7f..dfac679 100644
--- a/src/OSC.c
+++ b/src/OSC.c
@@ -47,8 +47,8 @@ OSC_API void OSC_version (t_OSC *x) {
// EnterCallback();
post("OSC4PD Version " VERSION
"\n ¯\\ original code by matt wright. pd-fication jdl@xdv.org\n"
- " · Win32-port raf@interaccess.com Darwin cleanup hans@at.or.at\n"
- " \\_ Compiled " __TIME__ " " __DATE__);
+ " · Win32-port raf@interaccess.com unified versions hans@at.or.at\n"
+ " \\_ Compiled " __TIME__ " " __DATE__);
// ExitCallback();
}