From 35fb120222e63ae9cac8e80a077a83688682553c Mon Sep 17 00:00:00 2001 From: pancake Date: Wed, 27 Mar 2013 12:49:48 +0100 Subject: [PATCH] radare2: fix crossbuild and update -git package --- srcpkgs/radare2-git/template | 12 +++------- srcpkgs/radare2/patches/fix-crossbuild.patch | 24 ++++++++++++++++++++ 2 files changed, 27 insertions(+), 9 deletions(-) create mode 100644 srcpkgs/radare2/patches/fix-crossbuild.patch diff --git a/srcpkgs/radare2-git/template b/srcpkgs/radare2-git/template index 8105dd62b88..9b3ab0baba4 100644 --- a/srcpkgs/radare2-git/template +++ b/srcpkgs/radare2-git/template @@ -1,22 +1,16 @@ # Template file for 'radare2-git' pkgname=radare2-git version="$(date -u +%Y%m%d)" -revision=1 +revision=2 build_style=gnu-configure -makedepends="pkg-config flex openssl-devel" +makedepends="git" provides="radare2-9999" replaces="radare2>=0" subpackages="radare2-devel-git" short_desc="Advanced command line debugger and hexadecimal editor (git snapshot)" -maintainer="Juan RP " +maintainer="pancake " license="LGPL-3" homepage="http://radare.org" -long_desc=" - It is composed by an hexadecimal editor (radare) with a wrapped IO layer - supporting multiple backends for local/remote files, accessing filesystems, - debugger (osx,bsd,linux,w32), stream analyzer, assembler/disassembler - (rasm) for x86,arm,ppc,m68k,java,msil,sparc, etc." - nofetch=yes noextract=yes diff --git a/srcpkgs/radare2/patches/fix-crossbuild.patch b/srcpkgs/radare2/patches/fix-crossbuild.patch new file mode 100644 index 00000000000..9cf39365f27 --- /dev/null +++ b/srcpkgs/radare2/patches/fix-crossbuild.patch @@ -0,0 +1,24 @@ +diff -ru configure configure +--- configure 2013-03-27 12:41:35.959376909 +0100 ++++ configure 2013-03-27 12:41:55.542960992 +0100 +@@ -36,7 +36,7 @@ + ENVWORDS="${ENVWORDS} $1_CPU $1_OS" + STR=`eval "echo ${S}$1"` + SPLIT_CPU="`echo "$STR" | cut -d - -f 1`" +-SPLIT_OS="`echo "$STR" | awk -F - '{if(NF==4){print $4}else{print $3}}'`" ++SPLIT_OS="`echo "$STR" | awk -F - '{if(NF==4){print $4}else{print $2}}'`" + eval "$1_CPU=\"$SPLIT_CPU\"" + eval "$1_OS=\"$SPLIT_OS\"" + shift +diff -ru libr/syscall/d/Makefile libr/syscall/d/Makefile +--- libr/syscall/d/Makefile 2013-03-27 12:41:35.948377143 +0100 ++++ libr/syscall/d/Makefile 2013-03-27 12:42:15.245542518 +0100 +@@ -39,7 +39,7 @@ + ${SDB}: + cp -rf $(LTOP)/db/sdb/src $(LTOP)/db/sdb/src-native + #cd $(LTOP)/db/sdb/src-native && ${MAKE} -j ${MAKE_JOBS} ARCH=xxx CC=gcc clean sdb +- cd $(LTOP)/db/sdb/src-native && ${MAKE} -j 1 ARCH=xxx CC=gcc clean sdb ++ cd $(LTOP)/db/sdb/src-native && CFLAGS='' ${MAKE} -j 1 ARCH=xxx CC=gcc clean sdb + cp -f $(LTOP)/db/sdb/src-native/sdb $(LTOP)/db/sdb/sdb + rm -rf $(LTOP)/db/sdb/src-native +