diff options
author | Sven 'sleipnir' Rebhan <odinshorse@googlemail.com> | 2009-04-02 19:22:21 +0000 |
---|---|---|
committer | Sven 'sleipnir' Rebhan <odinshorse@googlemail.com> | 2009-04-02 19:22:21 +0000 |
commit | 66fb6b8db135f5feea63f7de186d8b14eb64dbec (patch) | |
tree | 137fbd24d7ddec32e1ee6c5fc1325adb2dee5fe8 | |
parent | Make dialog cross-compile by hacking around ncurses-config. (diff) | |
download | embedded-cross-66fb6b8db135f5feea63f7de186d8b14eb64dbec.tar.gz embedded-cross-66fb6b8db135f5feea63f7de186d8b14eb64dbec.tar.bz2 embedded-cross-66fb6b8db135f5feea63f7de186d8b14eb64dbec.zip |
Fix the dialog package. This is still somewhat hacky, but better than the site file hack.
-rw-r--r-- | dev-util/dialog/Manifest | 3 | ||||
-rw-r--r-- | dev-util/dialog/dialog-1.1.20080819.ebuild | 59 | ||||
-rw-r--r-- | dev-util/dialog/files/dialog-1.1-cross-ncurses-config.patch | 13 | ||||
-rw-r--r-- | portage-flags-host/arm-linux-gnueabi | 9 |
4 files changed, 75 insertions, 9 deletions
diff --git a/dev-util/dialog/Manifest b/dev-util/dialog/Manifest new file mode 100644 index 0000000..5b9e16a --- /dev/null +++ b/dev-util/dialog/Manifest @@ -0,0 +1,3 @@ +AUX dialog-1.1-cross-ncurses-config.patch 422 RMD160 e6f4dbc28de2ed2ea794bffc773834a6b7e95785 SHA1 bb5ded77cd540667be5022eb10a11de1625b8b1c SHA256 f552f435dd1f38b4522aa5a5e740503b138fd9312574ae396e1c2f85283e474a +DIST dialog-1.1-20080819.tgz 378814 RMD160 c7e2ad63ccffb4a042a61e59dcc44e5c1e9a94b0 SHA1 068a46aa1ffbfe96fdbf5cedd480b795a4f6321a SHA256 c5d49b39c5998bcecd124c05cc6f096d22ccdc378ad455214611ae41a2f4b7d9 +EBUILD dialog-1.1.20080819.ebuild 1677 RMD160 cd64ee131664fc32ac248e1117c3c049a9abc45e SHA1 dbc346962fa2a66cf136c8b78409d0ca876e00b3 SHA256 2b55ef1562f0fa301a70e7ef9fc2f763af929a99046c8e6de8751478ed4bded8 diff --git a/dev-util/dialog/dialog-1.1.20080819.ebuild b/dev-util/dialog/dialog-1.1.20080819.ebuild new file mode 100644 index 0000000..778b3a5 --- /dev/null +++ b/dev-util/dialog/dialog-1.1.20080819.ebuild @@ -0,0 +1,59 @@ +# Copyright 1999-2009 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-util/dialog/dialog-1.1.20080819.ebuild,v 1.8 2009/03/18 15:00:27 ranger Exp $ + +inherit eutils autotools toolchain-funcs + +MY_PV="${PV/1.1./1.1-}" +S=${WORKDIR}/${PN}-${MY_PV} +DESCRIPTION="tool to display dialog boxes from a shell" +HOMEPAGE="http://invisible-island.net/dialog/dialog.html" +SRC_URI="ftp://invisible-island.net/${PN}/${PN}-${MY_PV}.tgz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="alpha amd64 arm hppa ia64 ~m68k ~mips ppc ppc64 s390 sh sparc ~sparc-fbsd x86 ~x86-fbsd" +IUSE="examples nls unicode" + +RDEPEND=">=app-shells/bash-2.04-r3 + >=sys-libs/ncurses-5.2-r5" +DEPEND="${RDEPEND} + nls? ( sys-devel/gettext )" + +pkg_setup() { + if use unicode && ! built_with_use sys-libs/ncurses unicode; then + eerror "Installing dialog with the unicode flag requires ncurses be" + eerror "built with it as well. Please make sure your /etc/make.conf" + eerror "or /etc/portage/package.use enables it, and re-install" + eerror "ncurses with \`emerge --oneshot sys-libs/ncurses\`." + die "Re-emerge ncurses with the unicode flag" + fi +} + +src_unpack() { + unpack ${A} + + cd ${S} + + # Use the correct prefix for ncurses during cross compilation + if tc-is-cross-compiler; then + epatch "${FILESDIR}"/${PN}-1.1-cross-ncurses-config.patch + fi +} + +src_compile() { + use unicode && ncursesw="w" + econf $(use_enable nls) \ + "--with-ncurses${ncursesw}" || die "configure failed" + emake || die "build failed" +} + +src_install() { + emake install DESTDIR="${D}" || die + dodoc CHANGES README VERSION + + if use examples; then + docinto samples + dodoc samples/* + fi +} diff --git a/dev-util/dialog/files/dialog-1.1-cross-ncurses-config.patch b/dev-util/dialog/files/dialog-1.1-cross-ncurses-config.patch new file mode 100644 index 0000000..b05e602 --- /dev/null +++ b/dev-util/dialog/files/dialog-1.1-cross-ncurses-config.patch @@ -0,0 +1,13 @@ +--- configure 2009-04-02 19:02:52.000000000 +0000 ++++ configure.new 2009-04-02 19:04:50.000000000 +0000 +@@ -7482,8 +7482,8 @@ + + cf_cv_ncurses_header=curses.h + +-CPPFLAGS="`$NCURSES_CONFIG --cflags` $CPPFLAGS" +-LIBS="`$NCURSES_CONFIG --libs` $LIBS" ++CPPFLAGS="`$NCURSES_CONFIG --prefix=${ROOT} --cflags` $CPPFLAGS" ++LIBS="`$NCURSES_CONFIG --exec-prefix=${ROOT} --libs` $LIBS" + + cat >>confdefs.h <<\EOF + #define NCURSES 1 diff --git a/portage-flags-host/arm-linux-gnueabi b/portage-flags-host/arm-linux-gnueabi index e7e6bb1..75d1395 100644 --- a/portage-flags-host/arm-linux-gnueabi +++ b/portage-flags-host/arm-linux-gnueabi @@ -113,12 +113,3 @@ ac_cv_alignof_CORBA_wchar=2 # urandom ac_cv_file___dev_urandom_=yes - -# ncurses -if test -n "$(which ncurses6-config 2>/dev/null)"; then - ac_cv_path_NCURSES_CONFIG="$(which ncurses6-config) --prefix=${ROOT}/usr --exec-prefix=${ROOT}/usr" -else - if test -n "$(which ncurses5-config 2>/dev/null)"; then - ac_cv_path_NCURSES_CONFIG="$(which ncurses5-config) --prefix=${ROOT}/usr --exec-prefix=${ROOT}/usr" - fi -fi |