Browse Source

Autotool fixes

* Fix usage of `AC_INIT`.
* Extract JACK version numbers from `AC_INIT` version number.
* Newer versions of automake insists on the `subdir-objects` option
  when using C files from outside the current directory.
* Need to use generate `noinst_LTLIBRARIES` rather than just adding
  and out-of-dir C file to the `*_SOURCES`.
tags/0.125.0rc1
Erik de Castro Lopo 9 years ago
parent
commit
22ff0a5176
8 changed files with 86 additions and 46 deletions
  1. +2
    -0
      .gitignore
  2. +2
    -0
      Makefile.am
  3. +2
    -1
      autogen.sh
  4. +26
    -14
      configure.ac
  5. +5
    -0
      drivers/alsa/Makefile.am
  6. +4
    -1
      drivers/netjack/Makefile.am
  7. +5
    -12
      jackd/Makefile.am
  8. +40
    -18
      libjack/Makefile.am

+ 2
- 0
.gitignore View File

@@ -50,6 +50,7 @@ jack/version.h
jackd/jack_md5.h
jackd/jackd
jackd/jackd.1
m4
tags
tools/alsa_in
tools/alsa_out
@@ -66,3 +67,4 @@ tools/jack_thread_wait
tools/jack_transport
tools/jack_unload
tools/jackrec
libjack/.dirstamp

+ 2
- 0
Makefile.am View File

@@ -1,6 +1,8 @@
MAINTAINERCLEANFILES = Makefile.in aclocal.m4 configure config.h.in \
stamp-h.in config.log config.cache config.status

ACLOCAL_AMFLAGS = -I m4

if HAVE_DOXYGEN
DOC_DIR = doc
dist-check-doxygen:


+ 2
- 1
autogen.sh View File

@@ -18,11 +18,12 @@ else
fi
fi

$LIBTOOLIZE --force 2>&1 | sed '/^You should/d' || {
$LIBTOOLIZE --force --automake 2>&1 | sed '/^You should/d' || {
echo "libtool failed, exiting..."
exit 1
}

ACLOCAL_FLAGS="-I m4"
aclocal $ACLOCAL_FLAGS || {
echo "aclocal \$ACLOCAL_FLAGS where \$ACLOCAL_FLAGS= failed, exiting..."
exit 1


+ 26
- 14
configure.ac View File

@@ -1,8 +1,14 @@
dnl Process this file with autoconf to produce a configure script.
dnl $Id$

AC_INIT(jackd/jackd.c)
AC_INIT([jack-audio-connection-kit],[0.124.2],
[jack-devel@lists.jackaudio.org],[],[http://www.jackaudio.org/])

AC_CONFIG_SRCDIR([jackd/jackd.c])

AC_CONFIG_MACRO_DIR([m4])
AC_CONFIG_AUX_DIR(config)
AC_LANG([C])

dnl
dnl Check for existing JACK installs
@@ -28,7 +34,7 @@ for dir in /usr/lib /usr/local/lib /opt/lib ; do
done

if test "x$FORCE_INSTALL" != "xyes" -a $not_overwriting -gt 0 ; then
echo
AC_MSG_RESULT(yes)
echo
echo "!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"
echo "You appear to have at least one existing installation of JACK."
@@ -54,6 +60,7 @@ if test "x$FORCE_INSTALL" != "xyes" -a $not_overwriting -gt 0 ; then
exit 1
fi
fi
AC_MSG_RESULT(no)

AC_CONFIG_AUX_DIR(config)
AC_CANONICAL_BUILD
@@ -67,9 +74,17 @@ dnl interfaces are changed
dnl micro version = incremented when implementation-only
dnl changes are made
dnl ---
JACK_MAJOR_VERSION=0
JACK_MINOR_VERSION=124
JACK_MICRO_VERSION=3

JACK_MAJOR_VERSION=$(echo $PACKAGE_VERSION | sed "s/\..*//")
JACK_MINOR_VERSION=$(echo $PACKAGE_VERSION | sed "s/${JACK_MAJOR_VERSION}\.//;s/\..*//")
JACK_MICRO_VERSION=$(echo $PACKAGE_VERSION | sed "s/.*\.//g")

if test "${JACK_MAJOR_VERSION}.${JACK_MINOR_VERSION}.${JACK_MICRO_VERSION}" != "${PACKAGE_VERSION}" ; then
echo "ooops"
echo "Found : ${JACK_MAJOR_VERSION}.${JACK_MINOR_VERSION}.${JACK_MICRO_VERSION}"
echo "Expected : ${PACKAGE_VERSION}"
exit 1
fi

dnl ---
dnl HOWTO: updating the jack protocol version
@@ -100,10 +115,6 @@ JACK_API_CURRENT=0
JACK_API_REVISION=28
JACK_API_AGE=0

AC_SUBST(JACK_MAJOR_VERSION)
AC_SUBST(JACK_MINOR_VERSION)
AC_SUBST(JACK_MICRO_VERSION)

AC_SUBST(JACK_PROTOCOL_VERSION)
AC_DEFINE_UNQUOTED(PROTOCOL_VERSION, "$JACK_PROTOCOL_VERSION", [Protocol version])

@@ -116,11 +127,12 @@ JACK_SO_VERSION=${JACK_API_CURRENT}:${JACK_API_REVISION}:${JACK_API_AGE}
JACK_VERSION=$JACK_MAJOR_VERSION.$JACK_MINOR_VERSION.${JACK_MICRO_VERSION}${BETA}
JACK_RELEASE=$JACK_MAJOR_VERSION-$JACK_MINOR_VERSION-${JACK_MICRO_VERSION}${BETA}


AC_SUBST(JACK_SO_VERSION)
AC_SUBST(JACK_VERSION)
AC_SUBST(JACK_RELEASE)

AM_INIT_AUTOMAKE(jack-audio-connection-kit,${JACK_VERSION})
AM_INIT_AUTOMAKE
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])

dnl
dnl save any user-provided CFLAGS so we can forget
@@ -360,7 +372,7 @@ if test "build_cpu" = "powerpc" -o "$build_cpu" = "powerpc64" ; then

AC_MSG_CHECKING(whether we can compile Altivec code)

AC_COMPILE_IFELSE([asm ("vand %v0, %v0, %v0");],
AC_COMPILE_IFELSE([AC_LANG_SOURCE([asm ("vand %v0, %v0, %v0");])],
AC_DEFINE(USE_ALTIVEC, 1, [Define to 1 if Altivec assembly is available.])
AC_DEFINE(HAVE_ALTIVEC_LINUX, 1, "Is there Altivec Support ?")
ALTIVEC_OPT_FLAGS="-maltivec -mabi=altivec"
@@ -417,7 +429,7 @@ elif echo $build_cpu | egrep '(i.86|x86_64)' >/dev/null; then

AC_MSG_CHECKING(whether we can compile SSE code)

AC_COMPILE_IFELSE([asm ("movntps %xmm0, 0");],
AC_COMPILE_IFELSE([AC_LANG_SOURCE([asm ("movntps %xmm0, 0");])],
[
if test x$optimization_by_cpu = xyes ; then
if test x$cpu_supports_sse = xyes ; then
@@ -985,7 +997,7 @@ dnl Output summary message
dnl

echo
echo $PACKAGE $VERSION :
echo $PACKAGE_NAME $PACKAGE_VERSION :
echo
echo \| Build with ALSA support............................... : $HAVE_ALSA
echo \| Build with old FireWire \(FreeBob\) support............. : $HAVE_FREEBOB


+ 5
- 0
drivers/alsa/Makefile.am View File

@@ -18,3 +18,8 @@ noinst_HEADERS = alsa_driver.h \
usx2y.h

jack_alsa_la_LIBADD = $(ALSA_LIBS) $(top_builddir)/jackd/libjackserver.la


noinst_LTLIBRARIES = libmemops.la

libmemops_la_SOURCES = memops.c

+ 4
- 1
drivers/netjack/Makefile.am View File

@@ -1,6 +1,6 @@
MAINTAINCLEANFILES = Makefile.in

AM_CFLAGS = $(JACK_CFLAGS)
AM_CFLAGS = $(JACK_CFLAGS)


plugindir = $(ADDON_DIR)
@@ -14,3 +14,6 @@ jack_net_la_LIBADD = $(top_builddir)/libjack/libjack.la $(top_builddir)/jackd/li

noinst_HEADERS = netjack.h net_driver.h netjack_packet.h

noinst_LTLIBRARIES = libnetjack_packet.la

libnetjack_packet_la_SOURCES = netjack_packet.c

+ 5
- 12
jackd/Makefile.am View File

@@ -1,4 +1,6 @@
MAINTAINERCLEANFILES = Makefile.in jackd.1 jack_md5.h
AUTOMAKE_OPTIONS = subdir-objects

MAINTAINERCLEANFILES = Makefile.in jackd.1 jack_md5.h

if USE_CAPABILITIES
CAP_PROGS = jackstart
@@ -44,19 +46,10 @@ lib_LTLIBRARIES = libjackserver.la

libjackserver_la_CFLAGS = $(AM_CFLAGS)

libjackserver_la_SOURCES = engine.c clientengine.c transengine.c controlapi.c \
../libjack/systemtest.c ../libjack/sanitycheck.c \
../libjack/client.c ../libjack/driver.c ../libjack/intclient.c \
../libjack/messagebuffer.c ../libjack/pool.c ../libjack/port.c \
../libjack/midiport.c ../libjack/ringbuffer.c ../libjack/shm.c \
../libjack/thread.c ../libjack/time.c ../libjack/transclient.c \
../libjack/unlock.c ../libjack/uuid.c ../libjack/metadata.c
libjackserver_la_LIBADD = simd.lo -ldb @OS_LDFLAGS@
libjackserver_la_SOURCES = engine.c clientengine.c transengine.c controlapi.c
libjackserver_la_LIBADD = $(top_builddir)/libjack/simd.lo $(top_builddir)/libjack/libjackcommon.la $(top_builddir)/libjack/libjackdaemon.la -ldb @OS_LDFLAGS@
libjackserver_la_LDFLAGS = -export-dynamic -version-info @JACK_SO_VERSION@

simd.lo: $(srcdir)/../libjack/simd.c
$(LIBTOOL) --mode=compile $(CC) -I$(top_builddir) $(JACK_CORE_CFLAGS) $(SIMD_CFLAGS) -c -o simd.lo $(srcdir)/../libjack/simd.c

man_MANS = jackd.1 jackstart.1
EXTRA_DIST = $(man_MANS)



+ 40
- 18
libjack/Makefile.am View File

@@ -10,20 +10,20 @@ install-exec-hook:
endif

SOURCE_FILES = \
client.c \
intclient.c \
messagebuffer.c \
pool.c \
port.c \
metadata.c \
midiport.c \
ringbuffer.c \
shm.c \
thread.c \
time.c \
transclient.c \
unlock.c \
uuid.c
client.c \
intclient.c \
messagebuffer.c \
metadata.c \
midiport.c \
pool.c \
port.c \
ringbuffer.c \
shm.c \
thread.c \
time.c \
transclient.c \
unlock.c \
uuid.c

simd.lo: $(srcdir)/simd.c
$(LIBTOOL) --mode=compile $(CC) -I$(top_builddir) $(JACK_CORE_CFLAGS) $(SIMD_CFLAGS) -c -o simd.lo $(srcdir)/simd.c
@@ -35,9 +35,31 @@ noinst_HEADERS = local.h
AM_CFLAGS = $(JACK_CFLAGS) -DJACK_LOCATION=\"$(bindir)\"
AM_CXXFLAGS = $(JACK_CFLAGS)

libjack_la_CFLAGS = $(AM_CFLAGS)

libjack_la_SOURCES = $(SOURCE_FILES)
libjack_la_LIBADD = simd.lo -ldb @OS_LDFLAGS@
libjack_la_SOURCES =
libjack_la_LIBADD = libjackcommon.la simd.lo -ldb @OS_LDFLAGS@
libjack_la_LDFLAGS = -export-dynamic -version-info @JACK_SO_VERSION@

noinst_LTLIBRARIES = libjackcommon.la libjackdaemon.la

libjackcommon_la_CFLAGS = $(AM_CFLAGS)
libjackcommon_la_SOURCES = \
client.c \
intclient.c \
messagebuffer.c \
metadata.c \
midiport.c \
pool.c \
port.c \
ringbuffer.c \
shm.c \
thread.c \
time.c \
transclient.c \
unlock.c \
uuid.c

libjackdaemon_la_CFLAGS = $(AM_CFLAGS)
libjackdaemon_la_SOURCES = \
driver.c \
systemtest.c \
sanitycheck.c

Loading…
Cancel
Save