Qt: adv settings: Optimize synchronization panel
[vlc/solaris.git] / bootstrap
blob2f5ce733315a76b21be10bce2150d4359b17c1e4
1 #! /bin/sh
3 ## bootstrap file for the VLC media player
4 ##
5 ## Copyright (C) 2005-2008 the VideoLAN team
6 ##
7 ## Authors: Sam Hocevar <sam@zoy.org>
8 ## RĂ©mi Denis-Courmont <rem # videolan # org>
10 set -e
12 cd "$(dirname "$0")"
14 if test "$#" != "0"; then
15 echo "Usage: $0"
16 echo " Calls autoreconf to generate m4 macros and prepare Makefiles."
17 exit 1
20 ACLOCAL_ARGS="-I m4 ${ACLOCAL_ARGS}"
22 ###
23 ### Get a sane environment, just in case
24 ###
25 CYGWIN=binmode
26 export CYGWIN
28 # Prepare m4/private.m4
29 rm -f m4/private.m4 && cat > m4/private.m4 << EOF
30 dnl Private VLC macros - generated by bootstrap
31 EOF
33 # Check for pkg-config
34 if ! pkg-config --version >/dev/null 2>&1; then
35 cat << EOF
36 NOTE: "pkg-config" is missing from your system.
37 Many underlying libraries will not be detected.
38 ==============================================================
40 EOF
41 cat >> m4/private.m4 << EOF
42 dnl User does not have pkg-config, so assume package was not found
43 AC_DEFUN([PKG_CHECK_MODULES],[ifelse([\$4], , :, [\$4])])
45 EOF
48 # Check for autopoint (GNU gettext)
49 export AUTOPOINT
50 test "$AUTOPOINT" || AUTOPOINT=autopoint
51 if ! "$AUTOPOINT" --dry-run --force >/dev/null 2>&1; then
52 AUTOPOINT=true
53 cat << EOF
54 NOTE: GNU gettext appears to be missing or out-of-date.
55 Please install or update GNU gettext.
56 Also check if you have cvs, a dependency of autopoint.
57 Otherwise, you will not be able to build a source tarball.
58 ==============================================================
60 EOF
63 # Check for contrib directory
64 if test -d extras/contrib/build/bin; then
65 PATH="`pwd`/extras/contrib/build/bin:$PATH"
66 if test -d extras/contrib/build/share/aclocal; then
67 ACLOCAL_ARGS="${ACLOCAL_ARGS} -I extras/contrib/build/share/aclocal"
69 if test ".`uname -s`" = ".Darwin"; then
70 LD_LIBRARY_PATH=./extras/contrib/build/lib:$LD_LIBRARY_PATH
71 DYLD_LIBRARY_PATH=./extras/contrib/build/lib:$DYLD_LIBRARY_PATH
72 export LD_LIBRARY_PATH
73 export DYLD_LIBRARY_PATH
77 ###
78 ### Generate the modules makefile, by parsing modules/**/Modules.am
79 ###
81 echo "generating modules/**/Makefile.am"
82 find modules/ -name Modules.am | \
83 sed -ne 's,modules/\(.*\)/Modules.am,\1,p' | \
84 while read d; do
85 sh modules/genmf "$d"
86 printf "."
87 done
88 printf "\n"
90 set -x
92 ###
93 ### classic bootstrap stuff
94 ###
96 # Automake complains if these are not present
97 echo > ABOUT-NLS
98 cp -f INSTALL INSTALL.git
100 autoreconf --install --force --verbose ${ACLOCAL_ARGS}
101 rm -f po/Makevars.template ABOUT-NLS
102 echo > ABOUT-NLS
103 mv -f INSTALL.git INSTALL
106 ## files which need to be regenerated
108 rm -f stamp-h*
110 # Shut up
111 set +x
112 echo "Successfully bootstrapped"