Fixed Inkscape build

svn path=/nixpkgs/trunk/; revision=12114
This commit is contained in:
Michael Raskin 2008-06-16 09:09:58 +00:00
parent c750b3e602
commit 4577779af6
2 changed files with 9 additions and 5 deletions

View File

@ -5,7 +5,7 @@
with_python="no"
else
- checkPYTHON_LIBS=`python -c "import distutils.sysconfig ; print '%s/%s %s' % (distutils.sysconfig.get_config_var('LIBPL'),distutils.sysconfig.get_config_var('LDLIBRARY'),distutils.sysconfig.get_config_var('LIBS'))" 2>/dev/null`
+ checkPYTHON_LIBS=`python -c "import distutils.sysconfig ; print '-L%s -lpython2.4 %s' % (distutils.sysconfig.get_config_var('LIBDIR'),distutils.sysconfig.get_config_var('LIBS'))" 2>/dev/null`
+ checkPYTHON_LIBS=`python -c "import distutils.sysconfig ; print '-L%s -lpython2.5 %s' % (distutils.sysconfig.get_config_var('LIBDIR'),distutils.sysconfig.get_config_var('LIBS'))" 2>/dev/null`
if test "$?" -gt "0"; then
with_python="no"
else

View File

@ -1,15 +1,16 @@
args: with args;
stdenv.mkDerivation rec {
name = "inkscape-0.45.1";
name = "inkscape-0.46";
src = fetchurl {
url = "mirror://sf/inkscape/${name}.tar.gz";
sha256 = "1y0b9bm8chn6a2ip99dj4dhg0188yn67v571ha0x38wrlmvn4k0d";
sha256 = "0flrjqa68vnnn8lrhj86xpa6h2cyzrvjy6873v9id092f86ix1li";
};
# Work around Python misdetection and set `PYTHON_LIBS' to
# "-L/nix/store/... -lpython2.4" instead of "/nix/store/.../libpython2.4.so".
# Changed to 2.5
patches = [ ./configure-python-libs.patch ];
propagatedBuildInputs = [
@ -26,13 +27,16 @@ stdenv.mkDerivation rec {
configureFlags = "--with-python";
preBuild = ''
export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE -I./extension/script"
'';
postInstall = ''
# Make sure PyXML modules can be found at run-time.
for i in "$out/bin/"*
do
# FIXME: We're assuming Python 2.4.
wrapProgram "$i" --prefix PYTHONPATH : \
"${pyxml}/lib/python2.4/site-packages" || \
"$(toPythonPath ${pyxml})" || \
exit 2
done
'';