1 # Build recipe for xfsprogs.
3 # Copyright (c) 2019-2020 Matias Fonzo, <selk@dragora.org>.
5 # Licensed under the Apache License, Version 2.0 (the "License");
6 # you may not use this file except in compliance with the License.
7 # You may obtain a copy of the License at
9 # http://www.apache.org/licenses/LICENSE-2.0
11 # Unless required by applicable law or agreed to in writing, software
12 # distributed under the License is distributed on an "AS IS" BASIS,
13 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 # See the License for the specific language governing permissions and
15 # limitations under the License.
21 # Define a category for the output of the package name
24 tarname=${program}-${version}.tar.gz
27 fetch=http://mirrors.edge.kernel.org/pub/linux/utils/fs/xfs/xfsprogs/$tarname
30 A high-performance journaling filesystem.
32 XFS combines advanced journaling technology with full 64-bit addressing
33 and scalable structures and algorithms. This combination delivers the
34 most scalable high-performance filesystem ever conceived.
37 homepage=http://xfs.org
38 license="GPLv2+, LGPLv2.1"
40 # Source documentation
41 docs="README VERSION LICENSES/*"
42 docsdir="${docdir}/${program}-${version}"
44 # Limit parallel jobs for this build
51 unpack "${tardir}/$tarname"
55 # Set sane permissions
56 chmod -R u+w,go-w,a+rX-s .
58 ./configure LDFLAGS="$QILDFLAGS" \
59 OPTIMIZER="$QICFLAGS -O3" DEBUG="-DNDEBUG" \
61 --libdir=/usr/lib${libSuffix} \
62 --libexecdir=/usr/libexec/xfsprogs \
68 --enable-gettext=yes \
71 --build="$(gcc -dumpmachine)"
76 DIST_ROOT="$destdir" \
77 PKG_ROOT_SBIN_DIR="/usr/sbin" \
78 PKG_ROOT_LIB_DIR="/usr/lib${libSuffix}" \
81 # Remove cron job for the experimental xfs_scrub utility
82 rm -f "${destdir}/usr/lib${libSuffix}/xfsprogs/xfs_scrub_all.cron"
83 rmdir "${destdir}/usr/lib${libSuffix}/xfsprogs"
85 # Compress and link man pages (if needed)
86 if test -d "${destdir}/$mandir"
89 cd "${destdir}/$mandir"
90 find . -type f -exec lzip -9 '{}' +
91 find . -type l | while read -r file
93 ln -sf "$(readlink -- "$file").lz" "${file}.lz"
101 # Remove non-versioned location
102 rm -rf "${destdir}/usr/share/doc/xfsprogs"
104 mkdir -p "${destdir}${docsdir}"
105 cp -p $docs "${destdir}${docsdir}/"