diff options
author | Deposite Pirate | 2018-09-16 18:48:36 +0200 |
---|---|---|
committer | Deposite Pirate | 2018-09-16 18:48:36 +0200 |
commit | d150a5f3e462fa7fe194a805a4aa0076f4d03ab9 (patch) | |
tree | ce5e44d69c5f3175bfdbd1e3717b52c5dcca5638 /base/fs_ext/fs_ext.build | |
parent | f29d3519ce073ec30f99754d93304324f7f26d65 (diff) |
Add ports.
Diffstat (limited to 'base/fs_ext/fs_ext.build')
-rwxr-xr-x | base/fs_ext/fs_ext.build | 124 |
1 files changed, 124 insertions, 0 deletions
diff --git a/base/fs_ext/fs_ext.build b/base/fs_ext/fs_ext.build new file mode 100755 index 0000000..fc05ed8 --- /dev/null +++ b/base/fs_ext/fs_ext.build @@ -0,0 +1,124 @@ +#!/bin/bash +# +# Maintainer: Deposite Pirate <ofni.sknuplatem@etaripd> + +source /usr/src/ports/Build/build.sh + +NAME=fs_ext +VERSION=1.42.7 +BUILD=1 +OPTIONS="noinfoz" + +# Description + +cat > ${PKG}/install/slack-desc <<EOF +# HOW TO EDIT THIS FILE: +# The "handy ruler" below makes it easier to edit a package description. Line +# up the first '|' above the ':' following the base package name, and the '|' +# on the right side marks the last column you can put a character in. You must +# make exactly 11 lines for the formatting to be correct. It's also +# customary to leave one space after the ':'. + +$(padd)|-----handy-ruler------------------------------------------------------| +${NAME}: fs_ext (extended filesystems utilities) +${NAME}: +${NAME}: Utilities needed to create and maintain ext2, ext3 and ext4 +${NAME}: filesystems. +${NAME}: +${NAME}: These utilities were written by Remy Card (the developer and +${NAME}: maintainer of the ext2 fs) and Theodore T'so. +${NAME}: +${NAME}: +${NAME}: +${NAME}: +EOF + +cat >> ${PKG}/install/doinst.sh <<EOF +#!/bin/sh + +config() { + NEW="\$1" + OLD="\$(dirname \$NEW)/\$(basename \$NEW .new)" + # If there's no config file by that name, mv it over: + if [ ! -r \$OLD ]; then + mv \$NEW \$OLD + elif [ "\$(cat \$OLD | md5sum)" = "\$(cat \$NEW | md5sum)" ]; then + # toss the redundant copy + rm \$NEW + fi + # Otherwise, we leave the .new copy for the admin to consider... +} + +install_info() +{ + for file in "\${*}"; do + if [ -x usr/bin/install-info ]; then + usr/bin/install-info --info-dir=usr/share/info usr/share/info/\${file}.info.xz 2> /dev/null + fi + done +} + +config etc/mke2fs.conf.new + +# Install texinfo files + +install_info libext2fs +EOF + +# Sources + +SRCNAME[0]=e2fsprogs +SRCVERS[0]=${VERSION} +SRCPACK[0]=http://kernel.org/pub/linux/kernel/people/tytso/e2fsprogs/v${SRCVERS[0]}/${SRCNAME[0]}-${SRCVERS[0]}.tar.xz +SRCCOPY[0]="GPL2 LGPL2" + +build0() +{ +sed -i 's|$(libdir)/pkgconfig|$(datadir)/pkgconfig|g' */*/Makefile.in +CFLAGS="${FLAGS}" CXXFLAGS="${FLAGS}" \ +./configure \ + --build="${ARCH}-slackware-linux" \ + --disable-rpath \ + --prefix="${SYS_DIR[usr]}" \ + --mandir="${SYS_DIR[man]}" \ + --infodir="${SYS_DIR[info]}" \ + --docdir="${SYS_DIR[doc]}/${SRCNAME[0]}-${SRCVERS[0]}" \ + --sysconfdir="${SYS_DIR[etc]}" \ + --libdir="${SYS_DIR[lib]}" \ + --localstatedir="${SYS_DIR[var]}" \ + --enable-elf-shlibs \ + --disable-libblkid \ + --disable-libuuid \ + --disable-uuidd +make ${JOBS} V=1 +make install install-libs DESTDIR="${PKG}" +changelog RELEASE-NOTES +mv \ + ${PKG}${SYS_DIR[etc]}/mke2fs.conf \ + ${PKG}${SYS_DIR[etc]}/mke2fs.conf.new +( + for fstype in ext2 ext3 ext4 ext4dev; do + cd ${PKG}${SYS_DIR[sbin]} + rm -f fsck.${fstype} mkfs.${fstype} + ln -sf mke2fs mkfs.${fstype} + ln -sf e2fsck fsck.${fstype} + cd ${PKG}${SYS_DIR[man]}/man8 + rm -f fsck.${fstype} mkfs.${fstype} + echo ".so man8/mke2fs.8" > mkfs.${fstype} + echo ".so man8/e2fsck.8" > fsck.${fstype} + done +) +( + cd ${PKG}${SYS_DIR[sbin]} + rm -f e2label findfs + ln -sf tune2fs e2label + ln -sf mke2fs mke3fs + ln -sf mke2fs mke4fs + cd ${PKG}${SYS_DIR[man]}/man8 + echo ".so man8/mke2fs.8" > mke3fs.8 + echo ".so man8/mke2fs.8" > mke4fs.8 +) +sed -i -e 's/^AWK=.*/AWK=awk/' "${PKG}/usr/bin/compile_et" +sed -i -e 's#^SS_DIR=.*#SS_DIR="/usr/share/ss"#' "${PKG}/usr/bin/mk_cmds" +sed -i -e 's#^ET_DIR=.*#ET_DIR="/usr/share/et"#' "${PKG}/usr/bin/compile_et" +} |