diff --git a/srcpkgs/coreutils-doc b/srcpkgs/coreutils-doc deleted file mode 120000 index a4b710b178..0000000000 --- a/srcpkgs/coreutils-doc +++ /dev/null @@ -1 +0,0 @@ -coreutils \ No newline at end of file diff --git a/srcpkgs/coreutils/template b/srcpkgs/coreutils/template index 6a13d91bd4..6db9486c10 100644 --- a/srcpkgs/coreutils/template +++ b/srcpkgs/coreutils/template @@ -4,7 +4,7 @@ version=8.23 revision=6 bootstrap=yes makedepends="gmp-devel acl-devel libcap-devel" -replaces="chroot-coreutils>=0" +replaces="chroot-coreutils>=0 coreutils-doc>=0" short_desc="The GNU core utilities" maintainer="Juan RP " homepage="http://www.gnu.org/software/coreutils" @@ -17,6 +17,18 @@ if [ "$CHROOT_READY" ]; then hostmakedepends="perl" fi +pre_configure() { + # Build natively all utils for the host, we need this to generate + # the manpages via help2man. + if [ "$CROSS_BUILD" ]; then + CC=cc LD=ld AR=ar RANLIB=ranlib CFLAGS=-Os CXXFLAGS=-Os LDFLAGS= \ + ./configure --prefix=${wrksrc}/coreutils-${XBPS_MACHINE} + make ${makejobs} + make install + make distclean + fi +} + do_configure() { if [ "$CROSS_BUILD" ]; then configure_args+=" fu_cv_sys_stat_statfs2_bsize=no @@ -51,22 +63,8 @@ do_build() { } do_install() { make DESTDIR=${DESTDIR} install - if [ "$CROSS_BUILD" ]; then - rm -rf ${DESTDIR}/usr/share/info + mv ${wrksrc}/coreutils-${XBPS_MACHINE}/share/man \ + ${DESTDIR}/usr/share fi } - -if [ -z "$CROSS_BUILD" ]; then - -coreutils-doc_package() { - noarch=yes - short_desc+=" - documentation files" - replaces="coreutils<8.20_4" - pkg_install() { - vmove usr/share/info - vmove usr/share/man - } -} - -fi