Commit bc87a8ff authored by Hisham Muhammad's avatar Hisham Muhammad
Browse files

Remove bundled hwloc-1.2.1. Use either native Linux affinity support or an external libhwloc.

(for details see https://sourceforge.net/mailarchive/forum.php?thread_name=CAJpkDYeZpwqcWxZ77wq6bMrnhn-KzkU1xAqb3cU0drfnA3n9FQ%40mail.gmail.com&forum_name=htop-general )
parent 7ca10817
#! /bin/csh -f
#
# Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
# University Research and Technology
# Corporation. All rights reserved.
# Copyright (c) 2004-2005 The University of Tennessee and The University
# of Tennessee Research Foundation. All rights
# reserved.
# Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
# University of Stuttgart. All rights reserved.
# Copyright (c) 2004-2005 The Regents of the University of California.
# All rights reserved.
# Copyright © 2010 INRIA. All rights reserved.
# Copyright © 2009-2011 Cisco Systems, Inc. All rights reserved.
# $COPYRIGHT$
#
# Additional copyrights may follow
#
# $HEADER$
#
set builddir="`pwd`"
set srcdir="$1"
cd "$srcdir"
set srcdir=`pwd`
cd "$builddir"
set distdir="$builddir/$2"
set HWLOC_VERSION="$3"
set HWLOC_REPO_REV="$4"
if ("$distdir" == "") then
echo "Must supply relative distdir as argv[2] -- aborting"
exit 1
elif ("$HWLOC_VERSION" == "") then
echo "Must supply version as argv[1] -- aborting"
exit 1
endif
#========================================================================
if ("$srcdir" != "$builddir") then
set vpath=1
set vpath_msg=yes
else
set vpath=0
set vpath_msg=no
endif
# We can catch some hard (but possible) to do mistakes by looking at
# our tree's revision number, but only if we are in the source tree.
# Otherwise, use what configure told us, at the cost of allowing one
# or two corner cases in (but otherwise VPATH builds won't work).
set repo_rev=$HWLOC_REPO_REV
if (-d .svn) then
set repo_rev="r`svnversion .`"
endif
set start=`date`
cat <<EOF
Creating hwloc distribution
In directory: `pwd`
Srcdir: $srcdir
Builddir: $builddir
VPATH: $vpath_msg
Version: $HWLOC_VERSION
Started: $start
EOF
umask 022
if (! -d "$distdir") then
echo "*** ERROR: dist dir does not exist"
echo "*** ERROR: $distdir"
exit 1
endif
#
# See if we need to update the version file with the current repo
# revision number. Do this *before* entering the distribution tree to
# solve a whole host of problems with VPATH (since srcdir may be
# relative or absolute)
#
set cur_repo_rev="`grep '^repo_rev' ${distdir}/VERSION | cut -d= -f2`"
if ("$cur_repo_rev" == "-1") then
sed -e 's/^repo_rev=.*/repo_rev='$repo_rev'/' "${distdir}/VERSION" > "${distdir}/version.new"
cp "${distdir}/version.new" "${distdir}/VERSION"
rm -f "${distdir}/version.new"
# need to reset the timestamp to not annoy AM dependencies
touch -r "${srcdir}/VERSION" "${distdir}/VERSION"
echo "*** Updated VERSION file with repo rev number: $repo_rev"
else
echo "*** Did NOT update VERSION file with repo rev number"
endif
#
# VPATH builds only work if the srcdir has valid docs already built.
# If we're VPATH and the srcdir doesn't have valid docs, then fail.
#
if ($vpath == 1 && ! -d $srcdir/doc/doxygen-doc) then
echo "*** This is a VPATH 'make dist', but the srcdir does not already"
echo "*** have a doxygen-doc tree built. hwloc's config/distscript.csh"
echo "*** requores the docs to be built in the srcdir before executing"
echo "*** 'make dist' in a VPATH build."
exit 1
endif
#
# If we're not VPATH, force the generation of new doxygen documentation
#
if ($vpath == 0) then
# Not VPATH
echo "*** Making new doxygen documentation (doxygen-doc tree)"
echo "*** Directory: srcdir: $srcdir, distdir: $distdir, pwd: `pwd`"
cd doc
# We're still in the src tree, so kill any previous doxygen-docs
# tree and make a new one.
chmod -R a=rwx doxygen-doc
rm -rf doxygen-doc
make
if ($status != 0) then
echo ERROR: generating doxygen docs failed
echo ERROR: cannot continue
exit 1
endif
# Make new README file
echo "*** Making new README"
make readme
if ($status != 0) then
echo ERROR: generating new README failed
echo ERROR: cannot continue
exit 1
endif
else
echo "*** This is a VPATH build; assuming that the doxygen docs and REAME"
echo "*** are current in the srcdir (i.e., we'll just copy those)"
endif
echo "*** Copying doxygen-doc tree to dist..."
echo "*** Directory: srcdir: $srcdir, distdir: $distdir, pwd: `pwd`"
chmod -R a=rwx $distdir/doc/doxygen-doc
echo rm -rf $distdir/doc/doxygen-doc
rm -rf $distdir/doc/doxygen-doc
echo cp -rpf $srcdir/doc/doxygen-doc $distdir/doc
cp -rpf $srcdir/doc/doxygen-doc $distdir/doc
echo "*** Copying new README"
ls -lf $distdir/README
cp -pf $srcdir/README $distdir
#########################################################
# VERY IMPORTANT: Now go into the new distribution tree #
#########################################################
cd "$distdir"
echo "*** Now in distdir: $distdir"
#
# Remove all the latex source files from the distribution tree (the
# PDFs are still there; we're just removing the latex source because
# some of the filenames get really, really long...).
#
echo "*** Removing latex source from dist tree"
rm -rf doc/doxygen-doc/latex
#
# Get the latest config.guess and config.sub from ftp.gnu.org
#
echo "*** Downloading latest config.sub/config.guess from ftp.gnu.org..."
cd config
set configdir="`pwd`"
mkdir tmp.$$
cd tmp.$$
# Official HTTP git mirrors for config.guess / config.sub
wget -t 1 -T 10 -O config.guess 'http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=master'
wget -t 1 -T 10 -O config.sub 'http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=master'
chmod +x config.guess config.sub
# Recently, ftp.gnu.org has had zero-legnth config.guess / config.sub
# files, which causes the automated nightly SVN snapshot tarball to
# fail to be made correctly. This is a primitive attempt to fix that.
# If we got zero-length files from wget, use a config.guess /
# config.sub from a known location that is more recent than what ships
# in the current generation of auto* tools. Also check to ensure that
# the resulting scripts are runnable (Jan 2009: there are un-runnable
# scripts available right now because of some git vulnerability).
# Before you complain about this too loudly, remember that we're using
# unreleased software...
set happy=0
if (! -f config.guess || ! -s config.guess) then
echo " - WARNING: Got bad config.guess from ftp.gnu.org (non-existent or empty)"
else
./config.guess >& /dev/null
if ($status != 0) then
echo " - WARNING: Got bad config.guess from ftp.gnu.org (not executable)"
else
if (! -f config.sub || ! -s config.sub) then
echo " - WARNING: Got bad config.sub from ftp.gnu.org (non-existent or empty)"
else
./config.sub `./config.guess` >& /dev/null
if ($status != 0) then
echo " - WARNING: Got bad config.sub from ftp.gnu.org (not executable)"
else
echo " - Got good config.guess and config.sub from ftp.gnu.org"
chmod +w ../config.sub ../config.guess
cp config.sub config.guess ..
set happy=1
endif
endif
endif
endif
if ("$happy" == "0") then
echo " - WARNING: using included versions for both config.sub and config.guess"
endif
cd ..
rm -rf tmp.$$
cd ..
#
# All done
#
cat <<EOF
*** hwloc version $HWLOC_VERSION distribution created
Started: $start
Ended: `date`
EOF
This diff is collapsed.
This diff is collapsed.
# This macro set originally copied from Open MPI:
# Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
# University Research and Technology
# Corporation. All rights reserved.
# Copyright (c) 2004-2005 The University of Tennessee and The University
# of Tennessee Research Foundation. All rights
# reserved.
# Copyright (c) 2004-2007 High Performance Computing Center Stuttgart,
# University of Stuttgart. All rights reserved.
# Copyright (c) 2004-2005 The Regents of the University of California.
# All rights reserved.
# Copyright (c) 2006-2007 Cisco Systems, Inc. All rights reserved.
# and renamed for hwloc:
# Copyright (c) 2009 INRIA. All rights reserved.
# Copyright (c) 2009-2010 Université Bordeaux 1
# Copyright (c) 2010 Cisco Systems, Inc. All rights reserved.
# See COPYING in top-level directory.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:
#
# - Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
#
# - Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer listed
# in this license in the documentation and/or other materials
# provided with the distribution.
#
# - Neither the name of the copyright holders nor the names of its
# contributors may be used to endorse or promote products derived from
# this software without specific prior written permission.
#
# The copyright holders provide no reassurances that the source code
# provided does not infringe any patent, copyright, or any other
# intellectual property rights of third parties. The copyright holders
# disclaim any liability to any recipient for claims brought against
# recipient by any third party for infringement of that parties
# intellectual property rights.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
# _HWLOC_CHECK_VISIBILITY
# --------------------------------------------------------
AC_DEFUN([_HWLOC_CHECK_VISIBILITY],[
# Be safe for systems that have ancient Autoconf's (e.g., RHEL5)
m4_ifdef([AC_PROG_GREP],
[AC_REQUIRE([AC_PROG_GREP])],
[GREP=grep])
msg="whether to enable visibility"
# Check if the compiler has support for visibility, like some
# versions of gcc, icc.
AC_ARG_ENABLE(visibility,
AC_HELP_STRING([--enable-visibility],
[enable visibility feature of certain compilers/linkers (default: enabled)]))
case ${target} in
*-*-aix*|*-*-mingw*|*-*-cygwin*|*-*-hpux*)
enable_visibility=no
;;
esac
if test "$enable_visibility" = "no"; then
AC_MSG_CHECKING([$msg])
AC_MSG_RESULT([no (disabled)])
have_visibility=0
else
CFLAGS_orig="$CFLAGS"
CFLAGS="$CFLAGS_orig -fvisibility=hidden"
hwloc_add=
AC_CACHE_CHECK([if $CC supports -fvisibility],
[hwloc_cv_cc_fvisibility],
[AC_LINK_IFELSE([AC_LANG_PROGRAM([[
__attribute__((visibility("default"))) int foo;
]],[[int i;]])],
[hwloc_cv_cc_fvisibility=yes],
[if test -s conftest.err ; then
$GREP -iq "visibility" conftest.err
if test "$?" = "0" ; then
hwloc_cv_cc_fvisibility=no
else
hwloc_cv_cc_fvisibility=yes
fi
else
hwloc_cv_cc_fvisibility=yes
fi],
[hwloc_cv_cc_fvisibility=no])
])
if test "$hwloc_cv_cc_fvisibility" = "yes" ; then
hwloc_add=" -fvisibility=hidden"
have_visibility=1
AC_MSG_CHECKING([$msg])
AC_MSG_RESULT([yes (via$hwloc_add)])
elif test "$enable_visibility" = "yes"; then
AC_MSG_ERROR([Symbol visibility support requested but compiler does not seem to support it. Aborting])
else
AC_MSG_CHECKING([$msg])
AC_MSG_RESULT([no (unsupported)])
have_visibility=0
fi
CFLAGS=$CFLAGS_orig
HWLOC_VISIBILITY_CFLAGS=$hwloc_add
unset hwloc_add
fi
AC_DEFINE_UNQUOTED([HWLOC_C_HAVE_VISIBILITY], [$have_visibility],
[Whether C compiler supports -fvisibility])
])
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
# ltversion.m4 -- version numbers -*- Autoconf -*-
#
# Copyright (C) 2004 Free Software Foundation, Inc.
# Written by Scott James Remnant, 2004
#
# This file is free software; the Free Software Foundation gives
# unlimited permission to copy and/or distribute it, with or without
# modifications, as long as this notice is preserved.
# @configure_input@
# serial 3293 ltversion.m4
# This file is part of GNU Libtool
m4_define([LT_PACKAGE_VERSION], [2.4])
m4_define([LT_PACKAGE_REVISION], [1.3293])
AC_DEFUN([LTVERSION_VERSION],
[macro_version='2.4'
macro_revision='1.3293'
_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
_LT_DECL(, macro_revision, 0)
])
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment