2021-01-11 07:54:33 +00:00
|
|
|
{ lib, stdenv, fetchurl
|
2018-12-31 03:40:47 +00:00
|
|
|
, xorgproto, motif, libX11, libXt, libXpm, bison
|
2019-02-26 11:45:54 +00:00
|
|
|
, flex, automake, autoconf, libtool, runtimeShell
|
2016-07-30 15:35:51 +01:00
|
|
|
}:
|
2009-02-08 16:28:31 +00:00
|
|
|
|
2016-07-30 15:35:51 +01:00
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 13:41:18 +01:00
|
|
|
pname = "alliance";
|
2016-07-30 15:35:51 +01:00
|
|
|
version = "5.1.1";
|
2009-02-08 16:28:31 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
2019-08-15 13:41:18 +01:00
|
|
|
url = "http://www-asim.lip6.fr/pub/alliance/distribution/5.0/${pname}-${version}.tar.bz2";
|
2016-07-30 15:35:51 +01:00
|
|
|
sha256 = "046c9qwl1vbww0ljm4xyxf5jpz9nq62b2q0wdz9xjimgh4c207w1";
|
2009-02-08 16:28:31 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
|
2016-07-30 15:35:51 +01:00
|
|
|
nativeBuildInputs = [ libtool automake autoconf flex ];
|
2018-12-31 03:40:47 +00:00
|
|
|
buildInputs = [ xorgproto motif libX11 libXt libXpm bison ];
|
2016-07-30 15:35:51 +01:00
|
|
|
|
|
|
|
sourceRoot = "alliance/src/";
|
|
|
|
|
|
|
|
configureFlags = [
|
|
|
|
"--prefix=$(out)"
|
|
|
|
];
|
|
|
|
|
|
|
|
preConfigure = ''
|
|
|
|
mkdir -p $out/etc
|
|
|
|
|
|
|
|
#texlive for docs seems extreme
|
|
|
|
mkdir -p $out/share/alliance
|
|
|
|
mv ./documentation $out/share/alliance
|
|
|
|
substituteInPlace autostuff \
|
|
|
|
--replace "$newdirs documentation" "$newdirs" \
|
|
|
|
--replace documentation Solaris
|
|
|
|
|
|
|
|
substituteInPlace sea/src/DEF_grammar_lex.l \
|
|
|
|
--replace "ifndef FLEX_BETA" "if (YY_FLEX_MAJOR_VERSION <= 2) && (YY_FLEX_MINOR_VERSION < 6)"
|
|
|
|
./autostuff
|
|
|
|
'';
|
|
|
|
|
|
|
|
allianceInstaller = ''
|
2019-02-26 11:45:54 +00:00
|
|
|
#!${runtimeShell}
|
2016-07-30 15:35:51 +01:00
|
|
|
cp -v -r -n --no-preserve=mode $out/etc/* /etc/ > /etc/alliance-install.log
|
|
|
|
'';
|
|
|
|
|
|
|
|
allianceUnInstaller = ''
|
2019-02-26 11:45:54 +00:00
|
|
|
#!${runtimeShell}
|
2016-07-30 15:35:51 +01:00
|
|
|
awk '{print \$3}' /etc/alliance-install.log | xargs rm
|
|
|
|
awk '{print \$3}' /etc/alliance-install.log | xargs rmdir
|
|
|
|
rm /etc/alliance-install.log
|
|
|
|
'';
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
sed -i "s|ALLIANCE_TOP|$out|" distrib/*.desktop
|
|
|
|
mkdir -p $out/share/applications
|
|
|
|
cp -p distrib/*.desktop $out/share/applications/
|
|
|
|
mkdir -p $out/icons/hicolor/48x48/apps/
|
|
|
|
cp -p distrib/*.png $out/icons/hicolor/48x48/apps/
|
|
|
|
|
|
|
|
echo "${allianceInstaller}" > $out/bin/alliance-install
|
|
|
|
chmod +x $out/bin/alliance-install
|
|
|
|
|
|
|
|
echo "${allianceUnInstaller}" > $out/bin/alliance-uninstall
|
|
|
|
chmod +x $out/bin/alliance-uninstall
|
2009-02-08 16:28:31 +00:00
|
|
|
'';
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2016-07-30 15:35:51 +01:00
|
|
|
description = "Complete set of free CAD tools and portable libraries for VLSI design";
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "http://www-asim.lip6.fr/recherche/alliance/";
|
2016-07-30 15:35:51 +01:00
|
|
|
license = with licenses; gpl2Plus;
|
|
|
|
maintainers = with maintainers; [ ];
|
|
|
|
platforms = with platforms; linux;
|
2017-03-06 07:22:23 +00:00
|
|
|
broken = true;
|
2009-02-08 16:28:31 +00:00
|
|
|
};
|
|
|
|
}
|