Merge pull request #9691 from samuelrivas/update-argyllcms
Update argyllcms
This commit is contained in:
commit
529fad3fcf
@ -1,4 +1,4 @@
|
|||||||
{stdenv, fetchurl}:
|
{stdenv, fetchurl, yacc}:
|
||||||
|
|
||||||
let
|
let
|
||||||
bindir = if stdenv.system == "i686-linux" then "bin.linuxx86"
|
bindir = if stdenv.system == "i686-linux" then "bin.linuxx86"
|
||||||
@ -13,6 +13,8 @@ stdenv.mkDerivation {
|
|||||||
sha256 = "04c6khd7gdkqkvx4h3nbz99lyz7waid4fd221hq5chcygyx1sj3i";
|
sha256 = "04c6khd7gdkqkvx4h3nbz99lyz7waid4fd221hq5chcygyx1sj3i";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
buildInputs = [ yacc ];
|
||||||
|
|
||||||
installPhase = ''
|
installPhase = ''
|
||||||
mkdir -p $out/bin
|
mkdir -p $out/bin
|
||||||
cp ${bindir}/jam $out/bin
|
cp ${bindir}/jam $out/bin
|
||||||
|
@ -1,13 +1,20 @@
|
|||||||
{ stdenv, fetchurl, jam, unzip, libX11, libXxf86vm, libXrandr, libXinerama
|
{ stdenv, fetchzip, jam, unzip, libX11, libXxf86vm, libXrandr, libXinerama
|
||||||
, libXrender, libXext, libtiff, libjpeg, libXScrnSaver, writeText
|
, libXrender, libXext, libtiff, libjpeg, libpng, libXScrnSaver, writeText
|
||||||
, libXdmcp, libXau, lib }:
|
, libXdmcp, libXau, lib, openssl, zlib }:
|
||||||
|
let
|
||||||
|
version = "1.8.2";
|
||||||
|
in
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
name = "argyllcms-1.4.0";
|
name = "argyllcms-${version}";
|
||||||
|
|
||||||
src = fetchurl {
|
src = fetchzip {
|
||||||
url = "http://www.argyllcms.com/Argyll_V1.4.0_src.zip";
|
# Kind of flacky URL, it was reaturning 406 and inconsistent binaries for a
|
||||||
sha256 = "1a5i0972cjp6asmawmyzih2y4bv3i0qvf7p6z5lxnr199mq38cfk";
|
# while on me. It might be good to find a mirror
|
||||||
|
url = "http://www.argyllcms.com/Argyll_V${version}_src.zip";
|
||||||
|
sha256 = "0hnsciwak5chy4a421l8fz7amxzg8kbmy57a07dn460gdg6r63cy";
|
||||||
|
|
||||||
|
# The argyllcms web server doesn't like curl ...
|
||||||
|
curlOpts = "--user-agent 'Mozilla/5.0'";
|
||||||
};
|
};
|
||||||
|
|
||||||
# The contents of this file comes from the Jamtop file from the
|
# The contents of this file comes from the Jamtop file from the
|
||||||
@ -17,21 +24,30 @@ stdenv.mkDerivation rec {
|
|||||||
jamTop = writeText "argyllcms_jamtop" ''
|
jamTop = writeText "argyllcms_jamtop" ''
|
||||||
DESTDIR = "/" ;
|
DESTDIR = "/" ;
|
||||||
REFSUBDIR = "ref" ;
|
REFSUBDIR = "ref" ;
|
||||||
|
|
||||||
# Keep this DESTDIR anchored to Jamtop. PREFIX is used literally
|
# Keep this DESTDIR anchored to Jamtop. PREFIX is used literally
|
||||||
ANCHORED_PATH_VARS = DESTDIR ;
|
ANCHORED_PATH_VARS = DESTDIR ;
|
||||||
|
|
||||||
# Tell standalone libraries that they are part of Argyll:
|
# Tell standalone libraries that they are part of Argyll:
|
||||||
DEFINES += ARGYLLCMS ;
|
DEFINES += ARGYLLCMS ;
|
||||||
|
|
||||||
# Use libusb1 rather than libusb0 & libusb0-win32
|
# enable serial instruments & support
|
||||||
USE_LIBUSB1 = true ;
|
USE_SERIAL = true ;
|
||||||
|
|
||||||
# Make the USB V1 library static
|
# enable fast serial instruments & support
|
||||||
LIBUSB_IS_DLL = false ;
|
USE_FAST_SERIAL = true ; # (Implicit in USE_SERIAL too)
|
||||||
|
|
||||||
# Set the libubs1 library name.
|
# enable USB instruments & support
|
||||||
LIBUSB1NAME = libusb-1A ;
|
USE_USB = true ;
|
||||||
|
|
||||||
|
# enable dummy Demo Instrument (only if code is available)
|
||||||
|
USE_DEMOINST = true ;
|
||||||
|
|
||||||
|
# Use ArgyllCMS version of libusb (deprecated - don't use)
|
||||||
|
USE_LIBUSB = false ;
|
||||||
|
|
||||||
|
# For testing CCast
|
||||||
|
DEFINES += CCTEST_PATTERN ;
|
||||||
|
|
||||||
JPEGLIB = ;
|
JPEGLIB = ;
|
||||||
JPEGINC = ;
|
JPEGINC = ;
|
||||||
@ -41,10 +57,22 @@ stdenv.mkDerivation rec {
|
|||||||
TIFFINC = ;
|
TIFFINC = ;
|
||||||
HAVE_TIFF = true ;
|
HAVE_TIFF = true ;
|
||||||
|
|
||||||
|
PNGLIB = ;
|
||||||
|
PNGINC = ;
|
||||||
|
HAVE_PNG = true ;
|
||||||
|
|
||||||
|
ZLIB = ;
|
||||||
|
ZINC = ;
|
||||||
|
HAVE_Z = true ;
|
||||||
|
|
||||||
|
SSLLIB = ;
|
||||||
|
SSLINC = ;
|
||||||
|
HAVE_SSL = true ;
|
||||||
|
|
||||||
LINKFLAGS +=
|
LINKFLAGS +=
|
||||||
${lib.concatStringsSep " " (map (x: "-L${x}/lib") buildInputs)}
|
${lib.concatStringsSep " " (map (x: "-L${x}/lib") buildInputs)}
|
||||||
-ldl -lrt -lX11 -lXext -lXxf86vm -lXinerama -lXrandr -lXau -lXdmcp -lXss
|
-ldl -lrt -lX11 -lXext -lXxf86vm -lXinerama -lXrandr -lXau -lXdmcp -lXss
|
||||||
-ljpeg -ltiff ;
|
-ljpeg -ltiff -lpng -lssl ;
|
||||||
'';
|
'';
|
||||||
|
|
||||||
nativeBuildInputs = [ jam unzip ];
|
nativeBuildInputs = [ jam unzip ];
|
||||||
@ -52,27 +80,31 @@ stdenv.mkDerivation rec {
|
|||||||
preConfigure = ''
|
preConfigure = ''
|
||||||
cp ${jamTop} Jamtop
|
cp ${jamTop} Jamtop
|
||||||
substituteInPlace Makefile --replace "-j 3" "-j $NIX_BUILD_CORES"
|
substituteInPlace Makefile --replace "-j 3" "-j $NIX_BUILD_CORES"
|
||||||
# Remove tiff and jpg to be sure the nixpkgs-provided ones are used
|
# Remove tiff, jpg and png to be sure the nixpkgs-provided ones are used
|
||||||
rm -rf tiff jpg
|
rm -rf tiff jpg png
|
||||||
'';
|
'';
|
||||||
|
|
||||||
buildInputs = [
|
buildInputs = [
|
||||||
libtiff libjpeg libX11 libXxf86vm libXrandr libXinerama libXext
|
libtiff libjpeg libpng libX11 libXxf86vm libXrandr libXinerama libXext
|
||||||
libXrender libXScrnSaver libXdmcp libXau
|
libXrender libXScrnSaver libXdmcp libXau openssl
|
||||||
];
|
];
|
||||||
|
|
||||||
buildFlags = "PREFIX=$(out) all";
|
buildFlags = "PREFIX=$(out) all";
|
||||||
|
|
||||||
installFlags = "PREFIX=$(out)";
|
installFlags = "PREFIX=$(out)";
|
||||||
|
|
||||||
# Install udev rules, but remove lines that set up the udev-acl and plugdev
|
# Install udev rules, but remove lines that set up the udev-acl
|
||||||
# stuff, since that is handled by udev's own rules (70-udev-acl.rules)
|
# stuff, since that is handled by udev's own rules (70-udev-acl.rules)
|
||||||
|
#
|
||||||
|
# Move ref to a better place (there must be a way to make the install target
|
||||||
|
# do that for us)
|
||||||
postInstall = ''
|
postInstall = ''
|
||||||
rm -v $out/bin/License.txt
|
rm -v $out/bin/License.txt
|
||||||
mkdir -p $out/etc/udev/rules.d
|
mkdir -p $out/etc/udev/rules.d
|
||||||
sed -i '/udev-acl/d' libusb1/55-Argyll.rules
|
sed -i '/udev-acl/d' usb/55-Argyll.rules
|
||||||
sed -i '/plugdev/d' libusb1/55-Argyll.rules
|
cp -v usb/55-Argyll.rules $out/etc/udev/rules.d/
|
||||||
cp -v libusb1/55-Argyll.rules $out/etc/udev/rules.d/
|
mkdir -p $out/share/
|
||||||
|
mv $out/ref $out/share/argyllcms
|
||||||
'';
|
'';
|
||||||
|
|
||||||
meta = with stdenv.lib; {
|
meta = with stdenv.lib; {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user