lprof: fix build
This commit is contained in:
parent
297a9ae1bd
commit
d881b024d4
@ -19,27 +19,16 @@ stdenv.mkDerivation {
|
||||
sha256 = "0q8x24fm5yyvm151xrl3l03p7hvvciqnkbviprfnvlr0lyg9wsrn";
|
||||
};
|
||||
|
||||
# The sed commands disable header checks and add LDFLAGS NIX_CFLAGS_COMPILE
|
||||
# to the gcc environment
|
||||
buildPhase = ''
|
||||
mkdir -p $out
|
||||
export CXX=g++
|
||||
sed -i SConstruct \
|
||||
-e 's/def CheckForQt(context):/def CheckForQt(context):\n return 1/' \
|
||||
-e "s/not config.CheckHeader('lcms.h')/False/" \
|
||||
-e "s/not config.CheckHeader('tiff.h')/False/" \
|
||||
-e "s/not config.CheckCXXHeader('vigra\/impex.hxx')/False/" \
|
||||
\
|
||||
-e "s/^\( 'LDFLAGS'.*\)/\1\n,'hardeningDisable' : os.environ['hardeningDisable']/" \
|
||||
-e "s/^\( 'LDFLAGS'.*\)/\1\n,'NIX_CFLAGS_COMPILE' : os.environ['NIX_CFLAGS_COMPILE']/" \
|
||||
-e "s/^\( 'LDFLAGS'.*\)/\1\n,'NIX_LDFLAGS' : os.environ['NIX_LDFLAGS']/"
|
||||
|
||||
scons PREFIX=$out SYSLIBS=1 install
|
||||
'';
|
||||
|
||||
installPhase = ":";
|
||||
|
||||
patches = [ ./lcms-1.17.patch ];
|
||||
patches = [ ./lcms-1.17.patch ./keep-environment.patch ];
|
||||
|
||||
meta = {
|
||||
description = "Little CMS ICC profile construction set";
|
||||
|
16
pkgs/tools/graphics/lprof/keep-environment.patch
Normal file
16
pkgs/tools/graphics/lprof/keep-environment.patch
Normal file
@ -0,0 +1,16 @@
|
||||
--- lprof-1.11.4.1.org/SConstruct 2006-06-06 02:11:32.000000000 +0100
|
||||
+++ lprof-1.11.4.1/SConstruct 2017-08-29 12:56:13.425654683 +0100
|
||||
@@ -22,12 +22,7 @@
|
||||
# opts.Add(BoolOption('qt-mt-lib', 'Flag used to set QT library to either qt-mt or qt. Value of 1 = qt-mt, 0 = qt.', 'yes'))
|
||||
|
||||
# setup base environemnt
|
||||
-env = Environment(
|
||||
- ENV = {
|
||||
- 'PATH' : os.environ[ 'PATH' ],
|
||||
- 'HOME' : os.environ[ 'HOME' ], # required for distcc
|
||||
- 'LDFLAGS' : ''
|
||||
- }, options = opts)
|
||||
+env = Environment(ENV = os.environ, options = opts)
|
||||
|
||||
opts.Update(env)
|
||||
opts.Save('lprof.conf', env) # Save, so user doesn't have to
|
Loading…
Reference in New Issue
Block a user