#! /bin/bash # libxkbcommon # Source: https://github.com/lfs-book/libxkbcommon/archive/v1.10.0/libxkbcommon-1.10.0.tar.gz # # $BUILD = Directory to temporarily install # $PKGS = Directory to store built packages # # DEPS # Required: xkeyboard-config(for X support) # Recommended: libxcb, Wayland # Optional: Doxygen # If optimizing, use these flags with GCC export CFLAGS="-march=native -mtune=native -pipe " export CFLAGS+="-O3 -ffat-lto-objects -flto=4 " export CXXFLAGS=$CFLAGS export LDFLAGS="-flto=4 -Wl,-O2 -Wl,--as-needed " export PVER="1.10.0" # For building with Xorg Libraries meson setup --prefix=/usr \ --buildtype=release \ -Denable-docs=false \ -Denable-wayland=true \ -Denable-x11=true \ -Ddefault_library=both OUT && # For building without Xorg meson setup --prefix=/usr -Denable-docs=false \ -Denable-wayland=true \ -Denable-x11=false \ -Ddefault_library=both OUT && read -p "Compile?" && ninja -C OUT -j2 && sudo -S DESTDIR=$BUILD ninja -C OUT 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------------------------------------------------------| libxkbcommon: libxkbcommon (library to handle keyboard descriptions) libxkbcommon: libxkbcommon: libxkbcommon is a keymap compiler and support library which processes libxkbcommon: a reduced subset of keymaps as defined by the XKB specification. libxkbcommon: Primarily, a keymap is created from a set of libxkbcommon: Rules/Model/Layout/Variant/Options names, processed through an libxkbcommon: XKB ruleset, and compiled into a struct xkb_keymap, which is libxkbcommon: the base type for all xkbcommon operations. libxkbcommon: libxkbcommon: libxkbcommon does not distribute a dataset itself, other than for libxkbcommon: testing purposes. EOF sudo -S mv -v /tmp/slack-desc install/ && sudo -S makepkg -l y -c n $PKGS/libxkbcommon-$PVER-$PSUFFIX && cd /BMAN cat > /tmp/slack-desc << "EOF" libxkbcommon-doc: Manuals for libxkbcommon (library to handle keyboard descriptions) libxkbcommon-doc: libxkbcommon-doc: libxkbcommon is a keymap compiler and support library which processes libxkbcommon-doc: a reduced subset of keymaps as defined by the XKB specification. libxkbcommon-doc: Primarily, a keymap is created from a set of libxkbcommon-doc: Rules/Model/Layout/Variant/Options names, processed through an libxkbcommon-doc: XKB ruleset, and compiled into a struct xkb_keymap, which is libxkbcommon-doc: the base type for all xkbcommon operations. libxkbcommon-doc: libxkbcommon-doc: libxkbcommon does not distribute a dataset itself, other than for libxkbcommon-doc: testing purposes. EOF sudo -S mv -v /tmp/slack-desc install/ && sudo -S makepkg -l y -c n $PKGS/libxkbcommon-doc-$PVER-$NOPSUFFIX sudo -S rm -rf /BMAN/* sudo -S rm -rf ${BUILD}/*