linux-ext4.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Build script for a hermetic build of xfstests
@ 2011-07-21 23:54 Ted Ts'o
  0 siblings, 0 replies; only message in thread
From: Ted Ts'o @ 2011-07-21 23:54 UTC (permalink / raw)
  To: Ext4 Developers List, xfs-oss

With the six patches which I just sent (3 for xfsprogs, 3 for
xfstests), I'm now able to build xfstests hermetically using the
following script.  It's still a bit rough, but I offer it up if anyone
else wants to be able to build xfstests without having to worry about
hidden dependencies in the distro-supplied /usr/include/xfs
directories, etc.

						- Ted

#!/bin/bash -vx

DESTDIR=$(pwd)/bld

mkdir -p $DESTDIR

export CFLAGS="-I$DESTDIR/include"
export LDFLAGS="-static -L$DESTDIR/lib"

(cd e2fsprogs-libs; ./configure --prefix=/; make ; make DESTDIR=$DESTDIR install)

(cd attr; ./configure --prefix=$DESTDIR; make LLDFLAGS=-all-static ; make install-dev ; make install)

(cd acl; ./configure --prefix=$DESTDIR; make LLDFLAGS=-all-static; make install-dev; make install)

(cd libaio; make prefix=$DESTDIR install)

export DIST_ROOT=$DESTDIR
export LIBS=-lpthread
(cd xfsprogs-dev; make realclean ; make configure ; ./configure --prefix=/; make LLDFLAGS=-all-static BUILD_VERBOSE=1; make install; make install-dev)
unset LIBS
unset DIST_ROOT

export LIBTOOL="/usr/bin/libtool --tag=CC"
(cd dmapi; CFLAGS="-I$DESTDIR/include  -L$DESTDIR/lib" LDFLAGS=-static ./configure --prefix=$DESTDIR; make LLDFLAGS=-all-static; make install-dev; make install)
unset LIBTOOL

find . -name \*.la | xargs rm -f      # Die, libtool, die!!!!
cp $DESTDIR/include/xfs/dmapi.h $DESTDIR/include
set

export LIBS=-lpthread
export CFLAGS="-I$DESTDIR/include  -fno-stack-protector"
(cd xfstests-dev; ./configure ; make LLDFLAGS=-all-static BUILD_VERBOSE=1)


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2011-07-21 23:54 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-07-21 23:54 Build script for a hermetic build of xfstests Ted Ts'o

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).