blob: 93125668a5e0f04daa3516c6f1380c690c903a14 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
|
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/sys-libs/com_err/com_err-1.38.ebuild,v 1.16 2005/11/10 21:22:09 flameeyes Exp $
inherit eutils flag-o-matic toolchain-funcs
DESCRIPTION="common error display library"
HOMEPAGE="http://e2fsprogs.sourceforge.net/"
SRC_URI="mirror://sourceforge/e2fsprogs/e2fsprogs-${PV}.tar.gz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="alpha amd64 arm hppa ia64 m68k mips ppc ppc64 s390 sh sparc x86"
IUSE="nls"
RDEPEND=""
DEPEND="nls? ( sys-devel/gettext )"
S=${WORKDIR}/e2fsprogs-${PV}
src_unpack() {
unpack ${A}
cd "${S}"
epatch "${FILESDIR}"/${PN}-1.37-makefile.patch
}
src_compile() {
export LDCONFIG=/bin/true
export CC=$(tc-getCC)
export STRIP=/bin/true
local libtype
case ${USERLAND} in
Darwin) libtype=bsd;;
*) libtype=elf;;
esac
mkdir -p lib/{blkid,e2p,et,ext2fs,ss,uuid}/{checker,elfshared,pic,profiled} #102412
econf \
--enable-${libtype}-shlibs \
--with-ldopts="${LDFLAGS}" \
$(use_enable nls) \
|| die
emake -C lib/et || die
}
src_test() {
make -C lib/et check || die "make check failed"
}
src_install() {
export LDCONFIG=/bin/true
export CC=$(tc-getCC)
export STRIP=/bin/true
make -C lib/et DESTDIR="${D}" install || die
dosed '/^ET_DIR=/s:=.*:=/usr/share/et:' /usr/bin/compile_et
dosym et/com_err.h /usr/include/com_err.h
dolib.a lib/libcom_err.a || die "dolib.a"
if [[ ${USERLAND} == "Darwin" ]] ; then
dosym /usr/$(get_libdir)/libcom_err.*.dylib /usr/$(get_libdir)/libcom_err.dylib || die
else
dodir /$(get_libdir)
mv "${D}"/usr/$(get_libdir)/*$(get_libname)* "${D}"/$(get_libdir)/ || die "move .so"
gen_usr_ldscript libcom_err.so
fi
}
pkg_postinst() {
echo
einfo "PLEASE PLEASE take note of this"
einfo "Please make *sure* to run revdep-rebuild now"
einfo "Certain things on your system may have linked against a"
einfo "different version of com_err -- those things need to be"
einfo "recompiled. Sorry for the inconvenience"
echo
epause 10
ebeep
}
|