[svn] / trunk / xvidcore / build / generic / bootstrap.sh Repository:
ViewVC logotype

Diff of /trunk/xvidcore/build/generic/bootstrap.sh

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 877, Thu Feb 20 18:39:23 2003 UTC revision 1451, Fri May 21 14:40:15 2004 UTC
# Line 1  Line 1 
1  #!/bin/sh  #!/bin/sh
2  #  #
3    # - Bootstrap script -
4    #
5    # Copyright(C) 2003-2004 Edouard Gomez <ed.gomez@free.fr>
6    #
7  # This file builds the configure script and copies all needed files  # This file builds the configure script and copies all needed files
8  # provided by automake/libtoolize  # provided by automake/libtoolize
9  #  #
10  # $Id: bootstrap.sh,v 1.2 2003-02-20 18:39:23 edgomez Exp $  # $Id: bootstrap.sh,v 1.6 2004-05-21 14:40:15 edgomez Exp $
11    
12    
13  ##############################################################################  ##############################################################################
14  # Detect the right autoconf script  # Detect the right autoconf script
15  ##############################################################################  ##############################################################################
16    
17  # we first test Debian GNU/Linux autoconf for 2.50 series  # Find a suitable autoconf
18  AUTOCONF=`which autoconf2.50`  AUTOCONF="autoconf2.50"
19    $AUTOCONF --version 1>/dev/null 2>&1
20  if [ ! -x "$AUTOCONF" ] ; then  
21    if [ $? -ne 0 ] ; then
22      # Test failed, testing generic name -- many distros are shipping 2.13 with      AUTOCONF="autoconf"
23      # that name, that's why we have to perform an additional test for version.      $AUTOCONF --version 1>/dev/null 2>&1
     AUTOCONF=`which autoconf`  
24    
25      if [ ! -x "$AUTOCONF" ] ; then          if [ $? -ne 0 ] ; then
26          echo "No autoconf binary found in PATH"          echo "ERROR: 'autoconf' not found"
27          exit -1          exit -1
28      fi      fi
29    fi
30    
31      # Tests the autoconf version      # Tests the autoconf version
32      AC_VER=`$AUTOCONF --version | head -1 | sed 's/^[^0-9]*//i'`  AC_VER=`$AUTOCONF --version | head -1 | sed 's/'^[^0-9]*'/''/'`
33      AC_MAJORVER=`echo $AC_VER | cut -f1 -d'.'`      AC_MAJORVER=`echo $AC_VER | cut -f1 -d'.'`
34      AC_MINORVER=`echo $AC_VER | cut -f2 -d'.'`      AC_MINORVER=`echo $AC_VER | cut -f2 -d'.'`
35    
36      if [ "$AC_MAJORVER" -lt "2" ]; then      if [ "$AC_MAJORVER" -lt "2" ]; then
37          echo "This bootstrapper needs Autoconf >= 2.50 (detected $AC_VER)"      echo "ERROR: This bootstrapper requires Autoconf >= 2.50 (detected $AC_VER)"
38          exit -1          exit -1
39      fi      fi
40    
41      if [ "$AC_MINORVER" -lt "50" ]; then      if [ "$AC_MINORVER" -lt "50" ]; then
42          echo "This bootstrapper needs Autoconf >= 2.50 (detected $AC_VER)"      echo "ERROR: This bootstrapper requires Autoconf >= 2.50 (detected $AC_VER)"
43          exit -1          exit -1
44      fi      fi
45    
46    LIBTOOLIZE="libtoolize"
47    $LIBTOOLIZE --version 1>/dev/null 2>&1
48    
49    if [ $? -ne 0 ] ; then
50        LIBTOOLIZE="glibtoolize"
51        $LIBTOOLIZE --version 1>/dev/null 2>&1
52    
53        if [ $? -ne 0 ] ; then
54            echo "ERROR: 'libtoolize' not found"
55            exit -1
56        fi
57    fi
58    
59    AUTOMAKE="automake"
60    $AUTOMAKE --version 1>/dev/null 2>&1
61    
62    if [ $? -ne 0 ] ; then
63        echo "ERROR: 'automake' not found"
64            exit -1
65  fi  fi
66    
67  ##############################################################################  ##############################################################################
# Line 49  Line 72 
72  $AUTOCONF  $AUTOCONF
73    
74  echo "Copying files provided by automake"  echo "Copying files provided by automake"
75  automake -c -a 1>/dev/null 2>/dev/null  $AUTOMAKE -c -a 1>/dev/null 2>&1
76    
77  echo "Copying files provided by libtool"  echo "Copying files provided by libtool"
78  libtoolize -f -c 1>/dev/null 2>/dev/null  $LIBTOOLIZE -f -c 1>/dev/null 2>&1
79    
80  echo "Removing files that are not needed"  echo "Removing files that are not needed"
81  rm -rf autom4*  rm -rf autom4* 1>/dev/null 2>&1
82  rm -rf ltmain.sh  rm -rf ltmain.sh 1>/dev/null 2>&1

Legend:
Removed from v.877  
changed lines
  Added in v.1451

No admin address has been configured
ViewVC Help
Powered by ViewVC 1.0.4