2012-11-28 11:25:08 +01:00
|
|
|
{ stdenv, fetchurl, qt4, muparser, which}:
|
2012-01-03 22:14:14 +01:00
|
|
|
|
|
|
|
stdenv.mkDerivation {
|
2012-11-28 11:25:08 +01:00
|
|
|
name = "librecad-1.0.2";
|
2012-01-03 22:14:14 +01:00
|
|
|
|
|
|
|
src = fetchurl {
|
2012-11-28 11:25:08 +01:00
|
|
|
url = https://github.com/LibreCAD/LibreCAD/tarball/v1.0.2;
|
|
|
|
name = "librecad-1.0.2.tar.gz";
|
|
|
|
sha256 = "13ee7e401e4f5fbc68c2e017b7189bec788038f4f6e77f559861ceb8cfb1907d";
|
2012-01-03 22:14:14 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
patchPhase = ''
|
|
|
|
sed -i -e s,/bin/bash,`type -P bash`, scripts/postprocess-unix.sh
|
2012-11-28 11:25:08 +01:00
|
|
|
sed -i -e s,/usr/share,$out/share, src/lib/engine/rs_system.cpp
|
2012-01-03 22:14:14 +01:00
|
|
|
'';
|
|
|
|
|
|
|
|
configurePhase = "qmake PREFIX=$out";
|
|
|
|
|
2012-11-28 11:25:08 +01:00
|
|
|
installPhase = ''
|
|
|
|
ensureDir $out/bin $out/share
|
|
|
|
cp -R unix/librecad $out/bin
|
|
|
|
cp -R unix/resources $out/share/librecad
|
|
|
|
'';
|
2012-01-03 22:14:14 +01:00
|
|
|
|
2012-11-28 11:25:08 +01:00
|
|
|
buildInputs = [ qt4 muparser which ];
|
2012-01-03 22:14:14 +01:00
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "A 2D CAD package based upon Qt";
|
|
|
|
homepage = http://librecad.org;
|
|
|
|
license = "GPLv2";
|
2012-11-28 11:25:08 +01:00
|
|
|
maintainers = with stdenv.lib.maintainers; [viric];
|
|
|
|
platforms = with stdenv.lib.platforms; linux;
|
2012-01-03 22:14:14 +01:00
|
|
|
};
|
|
|
|
}
|