Add custom Tecgraf patched FTGL
This commit is contained in:
@@ -5,8 +5,8 @@
|
||||
, gtk3
|
||||
, im
|
||||
, libGLU
|
||||
, ftgl
|
||||
, lua
|
||||
, ftgl-tecgraf
|
||||
, lib
|
||||
}:
|
||||
|
||||
@@ -27,15 +27,14 @@ stdenv.mkDerivation rec {
|
||||
buildInputs = [
|
||||
gtk3
|
||||
libGLU
|
||||
ftgl
|
||||
lua
|
||||
ftgl-tecgraf
|
||||
];
|
||||
|
||||
propagatedBuildInputs = [
|
||||
im
|
||||
];
|
||||
|
||||
# The PDF support relies on a proprietary paid-for library.
|
||||
postPatch = ''
|
||||
sed -i 's/\bcdpdf\b//g' src/Makefile
|
||||
sed -i 's/\bcdluapdf5\b//g' src/Makefile
|
||||
@@ -47,10 +46,12 @@ stdenv.mkDerivation rec {
|
||||
"USE_LUA_VERSION=52"
|
||||
"USE_GTK3=Yes"
|
||||
"GTK_DEFAULT=Yes"
|
||||
|
||||
"FTGL_LIB=${ftgl-tecgraf}/lib"
|
||||
"FTGL_INC=${ftgl-tecgraf}/include"
|
||||
];
|
||||
|
||||
NIX_CFLAGS_COMPILE = ''
|
||||
-Wno-implicit-function-declaration
|
||||
-Wno-incompatible-pointer-types
|
||||
'';
|
||||
|
||||
@@ -65,7 +66,7 @@ Description: A vector graphics toolkit with device independent output
|
||||
Version: ${version}
|
||||
Libs: -L${placeholder "out"}/lib -lcd -lcdcontextplus -lcdgl -lcdim
|
||||
Cflags: -I${placeholder "out"}/include
|
||||
Requires: im gtk+-3.0 glu ftgl
|
||||
Requires: im gtk+-3.0 glu
|
||||
'';
|
||||
|
||||
installPhase = ''
|
||||
@@ -94,7 +95,7 @@ EOF
|
||||
|
||||
meta = with lib; {
|
||||
description = "A vector graphics toolkit with device independent output";
|
||||
license = licenses.mit;
|
||||
license = with licenses; [ mit ];
|
||||
maintainers = [ eko5z ];
|
||||
platforms = with platforms; gnu ++ linux ++ darwin;
|
||||
};
|
||||
|
||||
@@ -0,0 +1,56 @@
|
||||
{ fetchurl
|
||||
, lib
|
||||
, stdenv
|
||||
, freetype
|
||||
, libGLU
|
||||
, pkg-config
|
||||
, lsb-release
|
||||
, tree
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "ftgl-tecgraf";
|
||||
version = "3.32";
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://sourceforge/iup/${version}/Docs%20and%20Sources/ftgl-2.1.5_Sources.tar.gz";
|
||||
sha256 = "sha256-v9XqBq5qOm2MxAeybOzCMCqsi7hsQhWtsGkUHVNAekw=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
lsb-release
|
||||
pkg-config
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
freetype
|
||||
libGLU
|
||||
];
|
||||
|
||||
makeFlags = [
|
||||
"NO_DEPEND=Yes"
|
||||
];
|
||||
|
||||
NIX_CFLAGS_COMPILE = ''
|
||||
-fpermissive
|
||||
'';
|
||||
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
|
||||
mkdir -p $out/{lib,include}
|
||||
|
||||
cp -v lib/Linux*/*.so $out/lib/
|
||||
cp -v lib/Linux*/*.a $out/lib/ || true
|
||||
cp -r include/* $out/include
|
||||
|
||||
runHook postInstall
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "Tecgraf patched FTGL used by CD/IUP";
|
||||
license = with licenses; mit;
|
||||
maintainers = [ eko5z ];
|
||||
platforms = with platforms; gnu ++ linux ++ darwin;
|
||||
};
|
||||
}
|
||||
@@ -8,9 +8,9 @@
|
||||
, libsoup_3
|
||||
, im
|
||||
, libGLU
|
||||
, ftgl
|
||||
, lua
|
||||
, lib
|
||||
, ftgl-tecgraf
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
|
||||
libsoup_3
|
||||
libGLU
|
||||
lua
|
||||
ftgl
|
||||
ftgl-tecgraf
|
||||
];
|
||||
|
||||
propagatedBuildInputs = [
|
||||
@@ -62,6 +62,8 @@ stdenv.mkDerivation rec {
|
||||
"IM_LIB=${im}/lib"
|
||||
"LUA_LIB=${lua}/lib"
|
||||
"LUA_INC=${lua}/include"
|
||||
"FTGL_LIB=${ftgl-tecgraf}/lib"
|
||||
"FTGL_INC=${ftgl-tecgraf}/include"
|
||||
];
|
||||
|
||||
NIX_CFLAGS_COMPILE = ''
|
||||
@@ -80,7 +82,7 @@ Description: A portable toolkit for building graphical user interfaces
|
||||
Version: ${version}
|
||||
Libs: -L${placeholder "out"}/lib -liup -liupgl -liupglcontrols -liupcontrols -liup_plot -liup_mglplot -liupcd -liupim -liupimglib -liup_scintilla -liuptuio -liupweb
|
||||
Cflags: -I${placeholder "out"}/include
|
||||
Requires: cd im gtk+-3.0 glu ftgl
|
||||
Requires: cd im gtk+-3.0 glu
|
||||
'';
|
||||
|
||||
installPhase = ''
|
||||
|
||||
Executable
BIN
Binary file not shown.
Executable
BIN
Binary file not shown.
Reference in New Issue
Block a user