Magellan Linux

Contents of /branches/R11-stable/core/xfsprogs/xfsprogs-3.1.10-r1.smage2

Parent Directory Parent Directory | Revision Log Revision Log


Revision 15003 - (show annotations) (download)
Wed Jan 2 09:48:13 2013 UTC (11 years, 4 months ago) by niro
File size: 2084 byte(s)
-release branches/R11-stable
1 # $Id$
2
3 PNAME="xfsprogs"
4 PVER="3.1.10"
5 PBUILD="r1"
6
7 PCAT="sys-fs"
8
9 DESCRIPTION="Administration and debugging tools for the XFS file system."
10 HOMEPAGE="http://oss.sgi.com/projects/xfs/"
11
12 DEPEND=">= virtual/glibc
13 >= sys-libs/libblkid-2.22
14 >= sys-libs/libuuid-2.22
15 >= sys-libs/readline-6.2"
16
17 SDEPEND=">= sys-dev/gettext-0.18
18 >= virtual/sed"
19
20 SRCFILE="${PNAME}-${PVER}.tar.gz"
21 SRCDIR="${BUILDDIR}/${PNAME}-${PVER}"
22
23 sminclude mtools
24
25 SRC_URI=(
26 ftp://oss.sgi.com/projects/xfs/cmd_tars/${SRCFILE}
27 ftp://oss.sgi.com/projects/xfs/previous/cmd_tars/${SRCFILE}
28 mirror://${PNAME}/${SRCFILE}
29 )
30
31 UP2DATE="updatecmd ftp://oss.sgi.com/projects/xfs/cmd_tars | grep ${PNAME} | lasttarball gz"
32
33 src_prepare()
34 {
35 munpack ${SRCFILE} || die
36 cd ${SRCDIR}
37
38 # fix CFLAGS and some install pathes
39 sed -i "/^PKG_DOC_DIR/s:=.*:= /usr/share/doc/${PNAME}-${PVER}:" \
40 include/builddefs.in || die
41
42 # remove static
43 sed -i '1iLLDFLAGS = -static' {estimate,fsr}/Makefile || die
44 sed -i "/LLDFLAGS/s:-static::" $(find -name Makefile) || die
45
46 # libdisk has broken blkid conditional checking
47 sed -i '/LIB_SUBDIRS/s:libdisk::' Makefile || die
48
49 # honor usr-move
50 sed -i -e "s:root_sbindir='/sbin':root_sbindir='/usr/sbin':" \
51 -e 's:root_libdir="/${base_libdir}":root_libdir="/usr/${base_libdir}":' \
52 configure.ac configure || die
53 }
54
55 src_compile()
56 {
57 cd ${SRCDIR}
58
59 # enable CFLAGS
60 export OPTIMIZER="${CFLAGS}"
61
62 # disable debug code
63 export DEBUG=-DNDEBUG
64
65 mconfigure \
66 --libexecdir=/usr/$(mlibdir) \
67 --enable-gettext \
68 --enable-readline \
69 --enable-blkid \
70 --disable-editline \
71 || die
72
73 mmake -j1 V=1 || die
74 }
75
76 src_install()
77 {
78 cd ${SRCDIR}
79
80 # needed directories
81 minstalldir /usr/$(mlibdir) || die
82
83 make DIST_ROOT=${BINDIR} \
84 DK_INC_DIR=${BINDIR}/usr/include/disk \
85 install install-dev \
86 || die
87
88 # we want compressed docs
89 rm -rf ${BINDIR}/usr/share/doc || die
90
91 # prune unneeded docs
92 rm doc/{CHANGES.gz,INSTALL,Makefile} || die
93
94 # sometime /var/tmp exist, remove it, to keep the right permissions
95 [[ -d ${BINDIR}/var ]] && rm -rf ${BINDIR}/var
96
97 minstalldocs doc/* || die
98 }