Merge pull request #354 from jcumming/recode.130305

recode: update to 3.7-git
This commit is contained in:
Vladimír Čunát 2013-03-06 06:32:03 -08:00
commit 00de01f58b
3 changed files with 15 additions and 74 deletions

View File

@ -1,46 +1,29 @@
{stdenv, fetchurl, autoconf, automake, libtool, gettext, perl}:
# XXX: this may need -liconv on non-glibc systems..
let
asIfPatch = ./recode-3.6-as-if.patch;
{stdenv, fetchgit, python, perl}:
gettextPatch = ./recode-3.6-gettextfix.diff;
stdenv.mkDerivation rec {
name = "recode-3.7-pff85fdbd";
debianPatch = fetchurl {
url = "http://ftp.de.debian.org/debian/pool/main/r/recode/recode_3.6-15.diff.gz";
sha256 = "114qxm29wk95w5760bswgd46d5p00g5kbfai5wchjvcbi722p5qf";
};
in
stdenv.mkDerivation {
name = "recode-3.6";
src = fetchurl {
url = "ftp://ftp.halifax.rwth-aachen.de/gnu/recode/recode-3.6.tar.gz";
sha256 = "1krgjqfhsxcls4qvxhagc45sm1sd0w69jm81nwm0bip5z3rs9rp3";
src = fetchgit {
url = https://github.com/pinard/Recode.git;
rev = "2fd8385658e5a08700e3b916053f6680ff85fdbd";
sha256 = "1xhlfmqld6af16l444jli9crj9brym2jihg1n6lkxh2gar68f5l7";
};
buildInputs = [ autoconf automake libtool gettext perl ];
patchPhase = ''
patch -Np1 -i ${asIfPatch}
patch -Np1 -i ${gettextPatch}
gunzip <${debianPatch} | patch -Np1 -i -
sed -i '1i#include <stdlib.h>' src/argmatch.c
rm -f acinclude.m4
autoreconf -fi
libtoolize
'';
configureFlags = "--without-included-gettext";
buildInputs = [ python perl ];
doCheck = true;
preCheck = ''
checkFlagsArray=(LDFLAGS="-L../src/.libs -Wl,-rpath=../src/.libs")
'';
meta = {
homepage = "http://www.gnu.org/software/recode/";
description = "Converts files between various character sets and usages";
license = "GPLv2+";
platforms = stdenv.lib.platforms.unix;
maintainers = [];
license = stdenv.lib.licenses.gpl2Plus;
maintainers = with stdenv.lib.maintainers; [ jcumming ];
};
}

View File

@ -1,19 +0,0 @@
http://bugs.gentoo.org/283029
--- a/m4/flex.m4
+++ b/m4/flex.m4
@@ -8,11 +8,11 @@ dnl ad_AC_PROG_FLEX
dnl Look for flex or missing, then run AC_PROG_LEX and AC_DECL_YYTEXT
AC_DEFUN(ad_AC_PROG_FLEX,
[AC_CHECK_PROGS(LEX, flex, missing)
-if test "$LEX" = missing; then
+AS_IF([test "$LEX" = missing], [dnl
LEX="\$(top_srcdir)/$ac_aux_dir/missing flex"
LEX_OUTPUT_ROOT=lex.yy
AC_SUBST(LEX_OUTPUT_ROOT)dnl
-else
+], [:
AC_PROG_LEX
AC_DECL_YYTEXT
-fi])
+])])

View File

@ -1,23 +0,0 @@
http://bugs.gentoo.org/239372
patch by Dmitry Karasik
--- recode-3.6/m4/gettext.m4
+++ recode-3.6/m4/gettext.m4
@@ -109,12 +109,12 @@
else
ac_items="$LINGUAS"
for ac_item in $ac_items; do
- case "$ALL_LINGUAS" in
- *$ac_item*)
+ for supported_item in $ALL_LINGUAS; do
+ if test "$ac_item" = "$supported_item"; then
ac_print="$ac_print $ac_item"
MOFILES="$MOFILES $ac_item.mo"
- ;;
- esac
+ fi
+ done
done
fi
AC_SUBST(MOFILES)