wml: fix build and unbreak

This commit is contained in:
Luca Bruno 2015-09-03 10:16:29 +02:00
parent c7580cd175
commit ad99ea6912

View File

@ -20,30 +20,40 @@ perlPackages.buildPerlPackage rec {
sed -i '/p2_mp4h\/doc/d' Makefile.in sed -i '/p2_mp4h\/doc/d' Makefile.in
''; '';
buildInputs = [ perlPackages.perl ncurses lynx makeWrapper ]; buildInputs = with perlPackages;
[ perl TermReadKey GD BitVector ncurses lynx makeWrapper ImageSize ];
patches = [ ./redhat-with-thr.patch ./dynaloader.patch ./no_bitvector.patch ]; patches = [ ./redhat-with-thr.patch ./dynaloader.patch ./no_bitvector.patch ];
preFixup = '' postPatch = ''
substituteInPlace $out/bin/wml \ substituteInPlace wml_frontend/wml.src \
--replace "File::PathConvert::realpath" "Cwd::realpath" \ --replace "File::PathConvert::realpath" "Cwd::realpath" \
--replace "File::PathConvert::abs2rel" "File::Spec->abs2rel" \ --replace "File::PathConvert::abs2rel" "File::Spec->abs2rel" \
--replace "File::PathConvert" "File::Spec" --replace "File::PathConvert" "File::Spec"
for i in wml_include/des/imgbg.src wml_include/des/imgdot.src; do
substituteInPlace $i \
--replace "WML::GD" "GD"
done
rm wml_test/t/11-wmk.t
'';
preFixup = ''
wrapProgram $out/bin/wml \ wrapProgram $out/bin/wml \
--set PERL5LIB ${with perlPackages; stdenv.lib.makePerlPath [ --set PERL5LIB ${with perlPackages; stdenv.lib.makePerlPath [
BitVector TermReadKey ImageSize BitVector TermReadKey ImageSize
]} ]}
''; '';
enableParallelBuilding = true; enableParallelBuilding = false;
installTargets = "install";
meta = with stdenv.lib; { meta = with stdenv.lib; {
homepage = http://thewml.org/; homepage = http://thewml.org/;
description = "Off-line HTML generation toolkit for Unix"; description = "Off-line HTML generation toolkit for Unix";
license = licenses.gpl2; license = licenses.gpl2;
platforms = platforms.linux; platforms = platforms.linux;
# Not sure what broke this build, it used to work
broken = true;
}; };
} }