2009-07-29 12:07:54 +02:00
|
|
|
#!/bin/sh
|
2011-03-02 16:30:40 +01:00
|
|
|
|
2011-11-01 18:06:11 +01:00
|
|
|
# Copyright (c) 2007-2009 iMatix Corporation
|
2011-03-02 16:30:40 +01:00
|
|
|
# Copyright (c) 2007-2011 Other contributors as noted in the AUTHORS file
|
2009-07-29 12:07:54 +02:00
|
|
|
#
|
|
|
|
# This file is part of 0MQ.
|
|
|
|
#
|
2011-07-04 09:27:50 +02:00
|
|
|
# 0MQ is free software; you can redistribute it and/or modify it under
|
|
|
|
# the terms of the GNU Lesser General Public License as published by
|
2009-07-29 12:07:54 +02:00
|
|
|
# the Free Software Foundation; either version 3 of the License, or
|
|
|
|
# (at your option) any later version.
|
2011-03-02 16:30:40 +01:00
|
|
|
#
|
2009-07-29 12:07:54 +02:00
|
|
|
# 0MQ is distributed in the hope that it will be useful,
|
|
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
2011-07-04 09:27:50 +02:00
|
|
|
# GNU Lesser General Public License for more details.
|
2011-03-02 16:30:40 +01:00
|
|
|
#
|
2011-07-04 09:27:50 +02:00
|
|
|
# You should have received a copy of the GNU Lesser General Public License
|
2009-07-29 12:07:54 +02:00
|
|
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
|
2010-03-15 15:45:38 +01:00
|
|
|
# Script to generate all required files from fresh git checkout.
|
2009-07-29 12:07:54 +02:00
|
|
|
|
2015-07-31 01:45:50 +02:00
|
|
|
# Debian and Ubuntu do not shipt libtool anymore, but OSX does not ship libtoolize.
|
|
|
|
command -v libtoolize >/dev/null 2>&1
|
2010-02-20 21:03:12 +01:00
|
|
|
if [ $? -ne 0 ]; then
|
2015-07-31 01:45:50 +02:00
|
|
|
command -v libtool >/dev/null 2>&1
|
|
|
|
if [ $? -ne 0 ]; then
|
|
|
|
echo "autogen.sh: error: could not find libtool. libtool is required to run autogen.sh." 1>&2
|
|
|
|
exit 1
|
|
|
|
fi
|
2010-02-20 21:03:12 +01:00
|
|
|
fi
|
|
|
|
|
2010-03-15 15:45:38 +01:00
|
|
|
command -v autoreconf >/dev/null 2>&1
|
2010-01-04 15:13:04 +01:00
|
|
|
if [ $? -ne 0 ]; then
|
2010-03-15 15:47:17 +01:00
|
|
|
echo "autogen.sh: error: could not find autoreconf. autoconf and automake are required to run autogen.sh." 1>&2
|
2010-03-15 15:45:38 +01:00
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
|
|
|
mkdir -p ./config
|
|
|
|
if [ $? -ne 0 ]; then
|
|
|
|
echo "autogen.sh: error: could not create directory: ./config." 1>&2
|
2010-01-05 11:05:03 +01:00
|
|
|
exit 1
|
2010-01-04 15:13:04 +01:00
|
|
|
fi
|
2010-01-05 11:05:03 +01:00
|
|
|
|
2009-07-29 12:07:54 +02:00
|
|
|
autoreconf --install --force --verbose -I config
|
|
|
|
if [ $? -ne 0 ]; then
|
2010-03-15 15:45:38 +01:00
|
|
|
echo "autogen.sh: error: autoreconf exited with status $?" 1>&2
|
2010-01-05 11:05:03 +01:00
|
|
|
exit 1
|
2009-07-29 12:07:54 +02:00
|
|
|
fi
|