]> git.sesse.net Git - vlc/blob - extras/contrib/bootstrap
* broken URL
[vlc] / extras / contrib / bootstrap
1 #!/bin/sh
2 # ***************************************************************************
3 # bootstrap : Set up config.mak
4 # ***************************************************************************
5 # Copyright (C) 2003 VideoLAN
6 # $Id: bootstrap,v 1.2 2003/11/15 02:38:25 hartman Exp $
7 #
8 # Authors: Christophe Massiot <massiot@via.ecp.fr>
9 #
10 # This program is free software; you can redistribute it and/or modify
11 # it under the terms of the GNU General Public License as published by
12 # the Free Software Foundation; either version 2 of the License, or
13 # (at your option) any later version.
14 #
15 # This program is distributed in the hope that it will be useful,
16 # but WITHOUT ANY WARRANTY; without even the implied warranty of
17 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18 # GNU General Public License for more details.
19 #
20 # You should have received a copy of the GNU General Public License
21 # along with this program; if not, write to the Free Software
22 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111, USA.
23 # ***************************************************************************
24
25 if test "$#" != "0"; then
26   echo "Usage: $0" >&2
27   echo "  Prepare config.mak file." >&2
28   exit 1
29 fi
30
31 LANG=C
32 export LANG
33 set -e
34 set -x
35
36 echo -e "# Automatically generated by bootstrap.\n# Make changes if you know what you're doing.\n" >| config.mak
37
38 if test ".`uname -s`" = ".Darwin"; then
39         echo "SYS = DARWIN" >> config.mak
40         echo "EXTRA_CPPFLAGS = -no-cpp-precomp" >> config.mak
41         echo "CONTRIB_URL = http://www.videolan.org/pub/videolan/devtools/contrib-macosx.tar.bz2" >> config.mak
42 else
43         echo "SYS = UNKNOWN" >> config.mak
44 fi
45
46 if which curl >/dev/null; then
47         echo "WGET = curl -O" >> config.mak
48 elif which wget >/dev/null; then
49         echo "WGET = wget" >> config.mak
50 else
51         echo "You need at least wget or curl to fetch the packages." >&2
52         exit 1
53 fi
54
55 echo "PREFIX = `pwd`" >> config.mak