Mercurial > audlegacy
annotate m4/buildsys.m4 @ 4661:e4e7999a21bc
Move D-Bus initialization before plugin system and playlist initialization.
(The other changes in this changeset are to remedy the problem arising from
the move, which resulted in annoying pause during startup due to D-Bus being
initialized when assumed not to be.)
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Fri, 27 Jun 2008 17:57:39 +0300 |
parents | 1d94382f0bde |
children | 9bc0c8a3a0f0 |
rev | line source |
---|---|
3535 | 1 dnl |
3877 | 2 dnl Copyright (c) 2007, Jonathan Schleifer <js-buildsys@webkeks.org> |
3535 | 3 dnl |
4275
3e0a2cce15f6
Added HG repo URL to buildsys as a comment.
Jonathan Schleifer <js-audacious@webkeks.org>
parents:
3877
diff
changeset
|
4 dnl https://webkeks.org/hg/buildsys/ |
3e0a2cce15f6
Added HG repo URL to buildsys as a comment.
Jonathan Schleifer <js-audacious@webkeks.org>
parents:
3877
diff
changeset
|
5 dnl |
3535 | 6 dnl Permission to use, copy, modify, and/or distribute this software for any |
7 dnl purpose with or without fee is hereby granted, provided that the above | |
8 dnl copyright notice and this permission notice is present in all copies. | |
9 dnl | |
10 dnl THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" | |
11 dnl AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE | |
12 dnl IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE | |
13 dnl ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE | |
14 dnl LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR | |
15 dnl CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF | |
16 dnl SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS | |
17 dnl INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN | |
18 dnl CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) | |
19 dnl ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE | |
20 dnl POSSIBILITY OF SUCH DAMAGE. | |
21 dnl | |
22 | |
3656
db04d0916c22
implib for ${PROG} should finally work.
Jonathan Schleifer <js@h3c.de>
parents:
3653
diff
changeset
|
23 AC_DEFUN([BUILDSYS_PROG_IMPLIB], [ |
3723
d4794783f2ee
Spelling fix. Spotted by nenolod.
Eugene Paskevich <eugene@raptor.kiev.ua>
parents:
3657
diff
changeset
|
24 AC_MSG_CHECKING(whether we need an implib) |
3656
db04d0916c22
implib for ${PROG} should finally work.
Jonathan Schleifer <js@h3c.de>
parents:
3653
diff
changeset
|
25 case "$target" in |
4275
3e0a2cce15f6
Added HG repo URL to buildsys as a comment.
Jonathan Schleifer <js-audacious@webkeks.org>
parents:
3877
diff
changeset
|
26 *-*-cygwin | *-*-mingw32) |
3e0a2cce15f6
Added HG repo URL to buildsys as a comment.
Jonathan Schleifer <js-audacious@webkeks.org>
parents:
3877
diff
changeset
|
27 AC_MSG_RESULT(yes) |
3e0a2cce15f6
Added HG repo URL to buildsys as a comment.
Jonathan Schleifer <js-audacious@webkeks.org>
parents:
3877
diff
changeset
|
28 PROG_IMPLIB_NEEDED='yes' |
3e0a2cce15f6
Added HG repo URL to buildsys as a comment.
Jonathan Schleifer <js-audacious@webkeks.org>
parents:
3877
diff
changeset
|
29 PROG_IMPLIB_LDFLAGS='-Wl,-export-all-symbols,--out-implib,lib${PROG}.a' |
3e0a2cce15f6
Added HG repo URL to buildsys as a comment.
Jonathan Schleifer <js-audacious@webkeks.org>
parents:
3877
diff
changeset
|
30 ;; |
3656
db04d0916c22
implib for ${PROG} should finally work.
Jonathan Schleifer <js@h3c.de>
parents:
3653
diff
changeset
|
31 *) |
db04d0916c22
implib for ${PROG} should finally work.
Jonathan Schleifer <js@h3c.de>
parents:
3653
diff
changeset
|
32 AC_MSG_RESULT(no) |
3657 | 33 PROG_IMPLIB_NEEDED='no' |
3656
db04d0916c22
implib for ${PROG} should finally work.
Jonathan Schleifer <js@h3c.de>
parents:
3653
diff
changeset
|
34 PROG_IMPLIB_LDFLAGS='' |
db04d0916c22
implib for ${PROG} should finally work.
Jonathan Schleifer <js@h3c.de>
parents:
3653
diff
changeset
|
35 ;; |
db04d0916c22
implib for ${PROG} should finally work.
Jonathan Schleifer <js@h3c.de>
parents:
3653
diff
changeset
|
36 esac |
db04d0916c22
implib for ${PROG} should finally work.
Jonathan Schleifer <js@h3c.de>
parents:
3653
diff
changeset
|
37 |
db04d0916c22
implib for ${PROG} should finally work.
Jonathan Schleifer <js@h3c.de>
parents:
3653
diff
changeset
|
38 AC_SUBST(PROG_IMPLIB_NEEDED) |
db04d0916c22
implib for ${PROG} should finally work.
Jonathan Schleifer <js@h3c.de>
parents:
3653
diff
changeset
|
39 AC_SUBST(PROG_IMPLIB_LDFLAGS) |
db04d0916c22
implib for ${PROG} should finally work.
Jonathan Schleifer <js@h3c.de>
parents:
3653
diff
changeset
|
40 ]) |
db04d0916c22
implib for ${PROG} should finally work.
Jonathan Schleifer <js@h3c.de>
parents:
3653
diff
changeset
|
41 |
3641
12500701b6dd
Update buildsys (adds ${PROG_SUFFIX}).
Jonathan Schleifer <js@h3c.de>
parents:
3618
diff
changeset
|
42 AC_DEFUN([BUILDSYS_SHARED_LIB], [ |
3535 | 43 AC_MSG_CHECKING(for shared library system) |
44 case "$target" in | |
45 intel-apple-*) | |
46 AC_MSG_RESULT([Mac OS X (Intel)]) | |
47 LIB_CPPFLAGS='-DPIC' | |
48 LIB_CFLAGS='-fPIC' | |
3785 | 49 LIB_LDFLAGS='-dynamiclib -fPIC -install_name ${libdir}/${LIB} -flat_namespace -undefined suppress' |
3535 | 50 LIB_PREFIX='lib' |
51 LIB_SUFFIX='.dylib' | |
52 PLUGIN_CPPFLAGS='' | |
53 PLUGIN_CFLAGS='' | |
54 PLUGIN_LDFLAGS='-bundle -fno-common -flat_namespace -undefined suppress' | |
55 PLUGIN_SUFFIX='.impl' | |
56 INSTALL_LIB='${INSTALL} -m 755 $$i ${DESTDIR}${libdir}/$${i%.dylib}.${LIB_MAJOR}.${LIB_MINOR}.dylib && ${LN_S} -f $${i%.dylib}.${LIB_MAJOR}.${LIB_MINOR}.dylib ${DESTDIR}${libdir}/$${i%.dylib}.${LIB_MAJOR}.dylib && ${LN_S} -f $${i%.dylib}.${LIB_MAJOR}.${LIB_MINOR}.dylib ${DESTDIR}${libdir}/$$i' | |
57 UNINSTALL_LIB='rm -f ${DESTDIR}${libdir}/$$i ${DESTDIR}${libdir}/$${i%.dylib}.${LIB_MAJOR}.dylib ${DESTDIR}${libdir}/$${i%.dylib}.${LIB_MAJOR}.${LIB_MINOR}.dylib' | |
3594
fa49ef305f59
Some buildsys fixes for Windows.
Jonathan Schleifer <js@h3c.de>
parents:
3586
diff
changeset
|
58 CLEAN_LIB='' |
3535 | 59 ;; |
60 *-apple-*) | |
61 AC_MSG_RESULT(Mac OS X) | |
62 LIB_CPPFLAGS='-DPIC' | |
63 LIB_CFLAGS='' | |
3785 | 64 LIB_LDFLAGS='-dynamiclib -fPIC -install_name ${libdir}/${LIB} -flat_namespace -undefined suppress' |
3535 | 65 LIB_PREFIX='lib' |
66 LIB_SUFFIX='.dylib' | |
67 PLUGIN_CPPFLAGS='' | |
68 PLUGIN_CFLAGS='' | |
69 PLUGIN_LDFLAGS='-bundle -fno-common -flat_namespace -undefined suppress' | |
70 PLUGIN_SUFFIX='.impl' | |
71 INSTALL_LIB='${INSTALL} -m 755 $$i ${DESTDIR}${libdir}/$${i%.dylib}.${LIB_MAJOR}.${LIB_MINOR}.dylib && ${LN_S} -f $${i%.dylib}.${LIB_MAJOR}.${LIB_MINOR}.dylib ${DESTDIR}${libdir}/$${i%.dylib}.${LIB_MAJOR}.dylib && ${LN_S} -f $${i%.dylib}.${LIB_MAJOR}.${LIB_MINOR}.dylib ${DESTDIR}${libdir}/$$i' | |
72 UNINSTALL_LIB='rm -f ${DESTDIR}${libdir}/$$i ${DESTDIR}${libdir}/$${i%.dylib}.${LIB_MAJOR}.dylib ${DESTDIR}${libdir}/$${i%.dylib}.${LIB_MAJOR}.${LIB_MINOR}.dylib' | |
3594
fa49ef305f59
Some buildsys fixes for Windows.
Jonathan Schleifer <js@h3c.de>
parents:
3586
diff
changeset
|
73 CLEAN_LIB='' |
3535 | 74 ;; |
3618 | 75 *-*-solaris* | *-openbsd-* | *-mirbsd-*) |
3535 | 76 AC_MSG_RESULT(Solaris) |
77 LIB_CPPFLAGS='-DPIC' | |
78 LIB_CFLAGS='-fPIC' | |
4317
1d94382f0bde
fixed linker arguments to gcc
Yoshiki Yazawa <yaz@cc.rim.or.jp>
parents:
4275
diff
changeset
|
79 LIB_LDFLAGS='-shared -fPIC -Wl,-soname,${LIB}.${LIB_MAJOR}.${LIB_MINOR}' |
3535 | 80 LIB_PREFIX='lib' |
81 LIB_SUFFIX='.so' | |
82 PLUGIN_CPPFLAGS='-DPIC' | |
83 PLUGIN_CFLAGS='-fPIC' | |
84 PLUGIN_LDFLAGS='-shared -fPIC' | |
85 PLUGIN_SUFFIX='.so' | |
3618 | 86 INSTALL_LIB='${INSTALL} -m 755 $$i ${DESTDIR}${libdir}/$$i.${LIB_MAJOR}.${LIB_MINOR} && rm -f ${DESTDIR}${libdir}/$$i && ${LN_S} $$i.${LIB_MAJOR}.${LIB_MINOR} ${DESTDIR}${libdir}/$$i' |
3535 | 87 UNINSTALL_LIB='rm -f ${DESTDIR}${libdir}/$$i ${DESTDIR}${libdir}/$$i.${LIB_MAJOR}.${LIB_MINOR}' |
3594
fa49ef305f59
Some buildsys fixes for Windows.
Jonathan Schleifer <js@h3c.de>
parents:
3586
diff
changeset
|
88 CLEAN_LIB='' |
3535 | 89 ;; |
3643 | 90 *-*-cygwin | *-*-mingw32) |
3618 | 91 AC_MSG_RESULT(Win32) |
3535 | 92 LIB_CPPFLAGS='-DPIC' |
93 LIB_CFLAGS='' | |
3594
fa49ef305f59
Some buildsys fixes for Windows.
Jonathan Schleifer <js@h3c.de>
parents:
3586
diff
changeset
|
94 LIB_LDFLAGS='-shared -Wl,--out-implib,${LIB}.a' |
fa49ef305f59
Some buildsys fixes for Windows.
Jonathan Schleifer <js@h3c.de>
parents:
3586
diff
changeset
|
95 LIB_PREFIX='lib' |
3535 | 96 LIB_SUFFIX='.dll' |
97 PLUGIN_CPPFLAGS='' | |
98 PLUGIN_CFLAGS='' | |
3618 | 99 PLUGIN_LDFLAGS='-shared' |
3535 | 100 PLUGIN_SUFFIX='.dll' |
3594
fa49ef305f59
Some buildsys fixes for Windows.
Jonathan Schleifer <js@h3c.de>
parents:
3586
diff
changeset
|
101 INSTALL_LIB='${INSTALL} -m 755 $$i ${DESTDIR}${bindir}/$$i && ${INSTALL} -m 755 $$i.a ${DESTDIR}${libdir}/$$i.a' |
fa49ef305f59
Some buildsys fixes for Windows.
Jonathan Schleifer <js@h3c.de>
parents:
3586
diff
changeset
|
102 UNINSTALL_LIB='rm -f ${DESTDIR}${bindir}/$$i ${DESTDIR}${libdir}/$$i.a' |
fa49ef305f59
Some buildsys fixes for Windows.
Jonathan Schleifer <js@h3c.de>
parents:
3586
diff
changeset
|
103 CLEAN_LIB='${LIB}.a' |
3535 | 104 ;; |
105 *) | |
106 AC_MSG_RESULT(POSIX) | |
107 LIB_CPPFLAGS='-DPIC' | |
108 LIB_CFLAGS='-fPIC' | |
4317
1d94382f0bde
fixed linker arguments to gcc
Yoshiki Yazawa <yaz@cc.rim.or.jp>
parents:
4275
diff
changeset
|
109 LIB_LDFLAGS='-shared -fPIC -Wl,-soname,${LIB}.${LIB_MAJOR}' |
3535 | 110 LIB_PREFIX='lib' |
111 LIB_SUFFIX='.so' | |
112 PLUGIN_CPPFLAGS='-DPIC' | |
113 PLUGIN_CFLAGS='-fPIC' | |
114 PLUGIN_LDFLAGS='-shared -fPIC' | |
115 PLUGIN_SUFFIX='.so' | |
4275
3e0a2cce15f6
Added HG repo URL to buildsys as a comment.
Jonathan Schleifer <js-audacious@webkeks.org>
parents:
3877
diff
changeset
|
116 INSTALL_LIB='${INSTALL} -m 755 $$i ${DESTDIR}${libdir}/$$i.${LIB_MAJOR}.${LIB_MINOR}.0 && ${LN_S} -f $$i.${LIB_MAJOR}.${LIB_MINOR}.0 ${DESTDIR}${libdir}/$$i.${LIB_MAJOR} && ${LN_S} -f $$i.${LIB_MAJOR}.${LIB_MINOR}.0 ${DESTDIR}${libdir}/$$i' |
3e0a2cce15f6
Added HG repo URL to buildsys as a comment.
Jonathan Schleifer <js-audacious@webkeks.org>
parents:
3877
diff
changeset
|
117 UNINSTALL_LIB='rm -f ${DESTDIR}${libdir}/$$i ${DESTDIR}${libdir}/$$i.${LIB_MAJOR} ${DESTDIR}${libdir}/$$i.${LIB_MAJOR}.${LIB_MINOR}.0' |
3594
fa49ef305f59
Some buildsys fixes for Windows.
Jonathan Schleifer <js@h3c.de>
parents:
3586
diff
changeset
|
118 CLEAN_LIB='' |
3535 | 119 ;; |
120 esac | |
121 | |
122 AC_SUBST(LIB_CPPFLAGS) | |
123 AC_SUBST(LIB_CFLAGS) | |
124 AC_SUBST(LIB_LDFLAGS) | |
125 AC_SUBST(LIB_PREFIX) | |
126 AC_SUBST(LIB_SUFFIX) | |
127 AC_SUBST(PLUGIN_CPPFLAGS) | |
128 AC_SUBST(PLUGIN_CFLAGS) | |
129 AC_SUBST(PLUGIN_LDFLAGS) | |
130 AC_SUBST(PLUGIN_SUFFIX) | |
131 AC_SUBST(INSTALL_LIB) | |
132 AC_SUBST(UNINSTALL_LIB) | |
3594
fa49ef305f59
Some buildsys fixes for Windows.
Jonathan Schleifer <js@h3c.de>
parents:
3586
diff
changeset
|
133 AC_SUBST(CLEAN_LIB) |
3535 | 134 ]) |