#! /bin/bash # gptfdisk # Source: https://downloads.sourceforge.net/gptfdisk/gptfdisk-1.0.9.tar.gz # # $BUILD = Directory to temporarily install # $PKGS = Directory to store built packages # # DEPS # Required: popt # Recommended: NONE # Optional: ICU patch -Np1 -i ../patches/gptfdisk-lfs/gptfdisk-1.0.9-convenience-1.patch && sed -i 's|ncursesw/||' gptcurses.cc && sed -i 's|sbin|usr/sbin|' Makefile # May have an error: # /usr/bin/ld: gptcurses.o: undefined reference to symbol 'LINES@@NCURSES6_TINFO_5.0.19991023' # /usr/bin/ld: /usr/lib/libtinfow.so.6: error adding symbols: DSO missing from command line # fix with: export LDFLAGS=" -Wl,--as-needed -ltinfow" read -p "Compile?" && make -j2 && sudo -S make DESTDIR=$BUILD install && sudo -S mkdir -pv /BMAN/install && \ sudo -S mkdir -pv /BMAN/usr && \ sudo -S mv $BUILD/usr/share /BMAN/usr/ cd $BUILD && sudo -S mkdir -v ${BUILD}/install && cat > /tmp/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 ':' except on otherwise blank lines. |-----handy-ruler------------------------------------------------------| gptfdisk: gptfdisk (GPT fdisk utilities) gptfdisk: gptfdisk: GPT fdisk (consisting of the gdisk, cgdisk, sgdisk, and fixparts gptfdisk: programs) is a set of text-mode partitioning tools for using a GPT gptfdisk: (GUID Partition Table), rather than the traditional MBR (Master Boot gptfdisk: Record) partition tables. It features several partitioning tools, gptfdisk: recovery tools to help you deal with corrupt partition tables, and the gptfdisk: ability to convert MBR disks to GPT format. gptfdisk: gptfdisk: gptfdisk home: http://sourceforge.net/projects/gptfdisk/ gptfdisk: EOF sudo -S mv -v /tmp/slack-desc install/ && sudo -S makepkg -l y -c n $PKGS/gptfdisk-1.0.9-$(uname -m)-mlfs.txz && cd /BMAN cat > /tmp/slack-desc << "EOF" gptfdisk-doc: Manuals for gptfdisk (GPT fdisk utilities) gptfdisk-doc: gptfdisk-doc: GPT fdisk (consisting of the gdisk, cgdisk, sgdisk, and fixparts gptfdisk-doc: programs) is a set of text-mode partitioning tools for using a GPT gptfdisk-doc: (GUID Partition Table), rather than the traditional MBR (Master Boot gptfdisk-doc: Record) partition tables. It features several partitioning tools, gptfdisk-doc: recovery tools to help you deal with corrupt partition tables, and the gptfdisk-doc: ability to convert MBR disks to GPT format. gptfdisk-doc: gptfdisk-doc: gptfdisk home: http://sourceforge.net/projects/gptfdisk/ EOF sudo -S mv -v /tmp/slack-desc install/ && \ sudo -S makepkg -l y -c n $PKGS/gptfdisk-doc-1.0.9-noarch-mlfs.txz sudo -S rm -rf /BMAN/* sudo -S rm -rf ${BUILD}/*