26

Re: [Collection] Compilation of packages and ports (not in repositories)

Package for gradio:

# Maintainer: Tobias Dausend <throgh@hyperbola.info>

pkgname=gradio
pkgver=7.3
pkgrel=1
pkgdesc="GTK+ based application for finding and listening to internet radio stations"
arch=('i686' 'x86_64')
license=('GPL-3')
url='https://github.com/haecker-felix/gradio'
depends=('gtk' 'gstreamer' 'libsoup' 'sqlite' 'json-glib' 'gst-plugins-base')
makedepends=('meson' 'vala' 'cmake' 'gettext-tiny')
source=("${pkgname}-${pkgver}.tar.gz::https://github.com/haecker-felix/Gradio/archive/refs/tags/v${pkgver}.tar.gz")
sha512sums=('d2bfd49ead90627b0516c320a5260f14ba2ea9ab5e417dafc38babc7eaaa706395986122d103bde931406f4240212210d2a7dbee6b69bddb901dc5705cac977b')

build() {
  hyperbola-meson Gradio-$pkgver build
  ninja -C build
}

package() {
  DESTDIR="$pkgdir" meson install -C build

  # remove unwanted data and interfaces
  rm -rf "$pkgdir/usr/share/"{dbus-1,gnome-shell}

  install -Dm644 "$srcdir/Gradio-$pkgver/LICENSE.md" -t "$pkgdir/usr/share/licenses/$pkgname"
}

Attention: Application is starting but malfunctional nevertheless as it is no longer possible to search for any internet-radio.
This package won't be added to Hyperbola! Just meant as "proof of concept" for packaging.

Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!

27

Re: [Collection] Compilation of packages and ports (not in repositories)

Package hostapd

PKGBUILD

# Maintainer (Arch): Sergej Pupykin <pupykin.s+arch@gmail.com>
# Contributor (Arch): David Runge <dvzrv@archlinux.org>
# Maintainer: Tobias Dausend <throgh@hyperbola.info>

pkgname=hostapd
pkgver=2.10
pkgrel=1
pkgdesc="IEEE 802.11 AP, IEEE 802.1X/WPA/WPA2/EAP/RADIUS Authenticator"
arch=('i686' 'x86_64')
url='https://w1.fi/hostapd/'
license=('Modified-BSD' 'ISC' 'Public-Domain')
depends=('glibc' 'libnl' 'libressl' 'sqlite')
backup=("etc/${pkgname}/${pkgname}."{accept,conf,deny,eap_user,radius_clients,vlan,wpa_psk})
source=("https://w1.fi/releases/$pkgname-$pkgver.tar.gz"{,.asc}
        "config"
        "copyright::https://metadata.ftp-master.debian.org/changelogs//main/w/wpa/wpa_2.10-12_copyright"
        "${pkgname}.initd"
        "${pkgname}.confd")
sha512sums=('243baa82d621f859d2507d8d5beb0ebda15a75548a62451dc9bca42717dcc8607adac49b354919a41d8257d16d07ac7268203a79750db0cfb34b51f80ff1ce8f'
            'SKIP'
            'eacd2ad295ec8786dac9814218a785eba0ca88e3dcf8b6f3694cba6a8330a8d020ac137623ef35bb0e5c1248f489c79c7fe07a7129a643d5e0dc4804e47f8b17'
            'd2241b2234e5db13b9601f699a8895f9bc7306fd08f6f5ce02c204fb8258d3a9d07a8e09d9704be6e13f14cb8e1da22f0d5efb9660199377be40cd09aa906c49'
            '1771078a125926d5aa9ab1d4c72c8eec6214a0a10767ea312ca9fb7b288ecf46aab1650addb934fd927be0842011205cbd70a821036494ae47d08143a4bf1f7d'
            '0882263bbd7c0b05bf51f51d66e11a23a0b8ca7da2a3b8a30166d2c5f044c0c134e6bccb1d02c9e81819ca8fb0c0fb55c7121a08fe7233ccaa73ff8ab9a238fe')
validpgpkeys=('EC4AA0A991A5F2464582D52D2B6EF432EFC895FA') # Jouni Malinen <j@w1.fi>

prepare() {
  cd "$pkgname-$pkgver"
  # fix include locations in main configuration file
  sed -e 's|/etc/hostapd|/etc/hostapd/hostapd|g' \
      -e 's|/var/run|/run|g' \
      -e 's|radius_attr.sqlite|/var/lib/hostapd/radius_attr.sqlite|g' \
      -e 's|hostapd.cred|/var/lib/hostapd/hostapd.cred|g' \
      -e 's|hostapd.ap_settings|/var/lib/hostapd/hostapd.ap_settings|g' \
      -e 's|hostapd_wps_pin_requests|hostapd/wps_pin_requests|g' \
      -i "${pkgname}/${pkgname}.conf"

  # extract license
  cat "${pkgname}/README" |head -n47 |tail -n5 > LICENSE

  # link build configuration into place:
  # an up-to-date version of the build configuration can be found in
  # hostapd/defconfig and should be diffed with the packaged one before every
  # build
  ln -sv "${srcdir}/config" "${pkgname}/.config"
}

build() {
  make -C $pkgname-$pkgver/$pkgname
}

package() {
  cd "$pkgname-$pkgver"
  make -C "${pkgname}" install DESTDIR="${pkgdir}" BINDIR="/usr/sbin"
  # license
  install -vDm 644 LICENSE "${srcdir}/copyright" -t "$pkgdir/usr/share/licenses/$pkgname/"
  # config
  install -vDm 640 "${pkgname}/${pkgname}."{accept,conf,deny,eap_user,radius_clients,vlan,wpa_psk} -t "${pkgdir}/etc/${pkgname}"
  # docs
  install -vDm 644 "${pkgname}/"{hostapd.sim_db,wired.conf,hlr_auc_gw.{txt,milenage_db}} "${pkgname}/"{README*,ChangeLog} -t "${pkgdir}/usr/share/doc/${pkgname}"
  # man pages
  install -vDm 644 "${pkgname}/${pkgname}.8" -t "$pkgdir/usr/share/man/man8/"
  install -vDm 644 "${pkgname}/${pkgname}_cli.1" -t "$pkgdir/usr/share/man/man1/"
  # state dir
  install -vdm 750 "${pkgdir}/var/lib/${pkgname}"
  # service-configuration
  install -vDm 644 "${srcdir}/${pkgname}.confd" "${pkgdir}/etc/conf.d/${pkgname}"
  install -vDm 755 "${srcdir}/${pkgname}.initd" "${pkgdir}/etc/init.d/${pkgname}"
}

config

# Example hostapd build time configuration
#
# This file lists the configuration options that are used when building the
# hostapd binary. All lines starting with # are ignored. Configuration option
# lines must be commented out complete, if they are not to be included, i.e.,
# just setting VARIABLE=n is not disabling that variable.
#
# This file is included in Makefile, so variables like CFLAGS and LIBS can also
# be modified from here. In most cass, these lines should use += in order not
# to override previous values of the variables.

# Driver interface for Host AP driver
CONFIG_DRIVER_HOSTAP=y

# Driver interface for wired authenticator
CONFIG_DRIVER_WIRED=y

# Driver interface for drivers using the nl80211 kernel interface
CONFIG_DRIVER_NL80211=y

# QCA vendor extensions to nl80211
#CONFIG_DRIVER_NL80211_QCA=y

# driver_nl80211.c requires libnl. If you are compiling it yourself
# you may need to point hostapd to your version of libnl.
#
#CFLAGS += -I$<path to libnl include files>
#LIBS += -L$<path to libnl library files>

# Use libnl v2.0 (or 3.0) libraries.
#CONFIG_LIBNL20=y

# Use libnl 3.2 libraries (if this is selected, CONFIG_LIBNL20 is ignored)
CONFIG_LIBNL32=y


# Driver interface for FreeBSD net80211 layer (e.g., Atheros driver)
#CONFIG_DRIVER_BSD=y
#CFLAGS += -I/usr/local/include
#LIBS += -L/usr/local/lib
#LIBS_p += -L/usr/local/lib
#LIBS_c += -L/usr/local/lib

# Driver interface for no driver (e.g., RADIUS server only)
#CONFIG_DRIVER_NONE=y

# WPA2/IEEE 802.11i RSN pre-authentication
CONFIG_RSN_PREAUTH=y

# Support Operating Channel Validation
#CONFIG_OCV=y

# Integrated EAP server
CONFIG_EAP=y

# EAP Re-authentication Protocol (ERP) in integrated EAP server
CONFIG_ERP=y

# EAP-MD5 for the integrated EAP server
CONFIG_EAP_MD5=y

# EAP-TLS for the integrated EAP server
CONFIG_EAP_TLS=y

# EAP-MSCHAPv2 for the integrated EAP server
CONFIG_EAP_MSCHAPV2=y

# EAP-PEAP for the integrated EAP server
CONFIG_EAP_PEAP=y

# EAP-GTC for the integrated EAP server
CONFIG_EAP_GTC=y

# EAP-TTLS for the integrated EAP server
CONFIG_EAP_TTLS=y

# EAP-SIM for the integrated EAP server
CONFIG_EAP_SIM=y

# EAP-AKA for the integrated EAP server
CONFIG_EAP_AKA=y

# EAP-AKA' for the integrated EAP server
# This requires CONFIG_EAP_AKA to be enabled, too.
#CONFIG_EAP_AKA_PRIME=y

# EAP-PAX for the integrated EAP server
CONFIG_EAP_PAX=y

# EAP-PSK for the integrated EAP server (this is _not_ needed for WPA-PSK)
CONFIG_EAP_PSK=y

# EAP-pwd for the integrated EAP server (secure authentication with a password)
#CONFIG_EAP_PWD=y

# EAP-SAKE for the integrated EAP server
CONFIG_EAP_SAKE=y

# EAP-GPSK for the integrated EAP server
CONFIG_EAP_GPSK=y
# Include support for optional SHA256 cipher suite in EAP-GPSK
CONFIG_EAP_GPSK_SHA256=y

# EAP-FAST for the integrated EAP server
#CONFIG_EAP_FAST=y

# EAP-TEAP for the integrated EAP server
# Note: The current EAP-TEAP implementation is experimental and should not be
# enabled for production use. The IETF RFC 7170 that defines EAP-TEAP has number
# of conflicting statements and missing details and the implementation has
# vendor specific workarounds for those and as such, may not interoperate with
# any other implementation. This should not be used for anything else than
# experimentation and interoperability testing until those issues has been
# resolved.
#CONFIG_EAP_TEAP=y

# Wi-Fi Protected Setup (WPS)
CONFIG_WPS=y
# Enable UPnP support for external WPS Registrars
CONFIG_WPS_UPNP=y
# Enable WPS support with NFC config method
CONFIG_WPS_NFC=y

# EAP-IKEv2
#CONFIG_EAP_IKEV2=y

# Trusted Network Connect (EAP-TNC)
#CONFIG_EAP_TNC=y

# EAP-EKE for the integrated EAP server
#CONFIG_EAP_EKE=y

# PKCS#12 (PFX) support (used to read private key and certificate file from
# a file that usually has extension .p12 or .pfx)
CONFIG_PKCS12=y

# RADIUS authentication server. This provides access to the integrated EAP
# server from external hosts using RADIUS.
CONFIG_RADIUS_SERVER=y

# Build IPv6 support for RADIUS operations
CONFIG_IPV6=y

# IEEE Std 802.11r-2008 (Fast BSS Transition)
CONFIG_IEEE80211R=y

# Use the hostapd's IEEE 802.11 authentication (ACL), but without
# the IEEE 802.11 Management capability (e.g., FreeBSD/net80211)
#CONFIG_DRIVER_RADIUS_ACL=y

# Wireless Network Management (IEEE Std 802.11v-2011)
# Note: This is experimental and not complete implementation.
#CONFIG_WNM=y

# IEEE 802.11ac (Very High Throughput) support
CONFIG_IEEE80211AC=y

# IEEE 802.11ax HE support
# Note: This is experimental and work in progress. The definitions are still
# subject to change and this should not be expected to interoperate with the
# final IEEE 802.11ax version.
CONFIG_IEEE80211AX=y

# Remove debugging code that is printing out debug messages to stdout.
# This can be used to reduce the size of the hostapd considerably if debugging
# code is not needed.
#CONFIG_NO_STDOUT_DEBUG=y

# Add support for writing debug log to a file: -f /tmp/hostapd.log
# Disabled by default.
#CONFIG_DEBUG_FILE=y

# Send debug messages to syslog instead of stdout
#CONFIG_DEBUG_SYSLOG=y

# Add support for sending all debug messages (regardless of debug verbosity)
# to the Linux kernel tracing facility. This helps debug the entire stack by
# making it easy to record everything happening from the driver up into the
# same file, e.g., using trace-cmd.
#CONFIG_DEBUG_LINUX_TRACING=y

# Remove support for RADIUS accounting
#CONFIG_NO_ACCOUNTING=y

# Remove support for RADIUS
#CONFIG_NO_RADIUS=y

# Remove support for VLANs
#CONFIG_NO_VLAN=y

# Enable support for fully dynamic VLANs. This enables hostapd to
# automatically create bridge and VLAN interfaces if necessary.
#CONFIG_FULL_DYNAMIC_VLAN=y

# Use netlink-based kernel API for VLAN operations instead of ioctl()
# Note: This requires libnl 3.1 or newer.
#CONFIG_VLAN_NETLINK=y

# Remove support for dumping internal state through control interface commands
# This can be used to reduce binary size at the cost of disabling a debugging
# option.
#CONFIG_NO_DUMP_STATE=y

# Enable tracing code for developer debugging
# This tracks use of memory allocations and other registrations and reports
# incorrect use with a backtrace of call (or allocation) location.
#CONFIG_WPA_TRACE=y
# For BSD, comment out these.
#LIBS += -lexecinfo
#LIBS_p += -lexecinfo
#LIBS_c += -lexecinfo

# Use libbfd to get more details for developer debugging
# This enables use of libbfd to get more detailed symbols for the backtraces
# generated by CONFIG_WPA_TRACE=y.
#CONFIG_WPA_TRACE_BFD=y
# For BSD, comment out these.
#LIBS += -lbfd -liberty -lz
#LIBS_p += -lbfd -liberty -lz
#LIBS_c += -lbfd -liberty -lz

# hostapd depends on strong random number generation being available from the
# operating system. os_get_random() function is used to fetch random data when
# needed, e.g., for key generation. On Linux and BSD systems, this works by
# reading /dev/urandom. It should be noted that the OS entropy pool needs to be
# properly initialized before hostapd is started. This is important especially
# on embedded devices that do not have a hardware random number generator and
# may by default start up with minimal entropy available for random number
# generation.
#
# As a safety net, hostapd is by default trying to internally collect
# additional entropy for generating random data to mix in with the data
# fetched from the OS. This by itself is not considered to be very strong, but
# it may help in cases where the system pool is not initialized properly.
# However, it is very strongly recommended that the system pool is initialized
# with enough entropy either by using hardware assisted random number
# generator or by storing state over device reboots.
#
# hostapd can be configured to maintain its own entropy store over restarts to
# enhance random number generation. This is not perfect, but it is much more
# secure than using the same sequence of random numbers after every reboot.
# This can be enabled with -e<entropy file> command line option. The specified
# file needs to be readable and writable by hostapd.
#
# If the os_get_random() is known to provide strong random data (e.g., on
# Linux/BSD, the board in question is known to have reliable source of random
# data from /dev/urandom), the internal hostapd random pool can be disabled.
# This will save some in binary size and CPU use. However, this should only be
# considered for builds that are known to be used on devices that meet the
# requirements described above.
#CONFIG_NO_RANDOM_POOL=y

# Should we attempt to use the getrandom(2) call that provides more reliable
# yet secure randomness source than /dev/random on Linux 3.17 and newer.
# Requires glibc 2.25 to build, falls back to /dev/random if unavailable.
#CONFIG_GETRANDOM=y

# Should we use poll instead of select? Select is used by default.
#CONFIG_ELOOP_POLL=y

# Should we use epoll instead of select? Select is used by default.
#CONFIG_ELOOP_EPOLL=y

# Should we use kqueue instead of select? Select is used by default.
#CONFIG_ELOOP_KQUEUE=y

# Select TLS implementation
# openssl = OpenSSL (default)
# gnutls = GnuTLS
# internal = Internal TLSv1 implementation (experimental)
# linux = Linux kernel AF_ALG and internal TLSv1 implementation (experimental)
# none = Empty template
#CONFIG_TLS=openssl

# TLS-based EAP methods require at least TLS v1.0. Newer version of TLS (v1.1)
# can be enabled to get a stronger construction of messages when block ciphers
# are used.
#CONFIG_TLSV11=y

# TLS-based EAP methods require at least TLS v1.0. Newer version of TLS (v1.2)
# can be enabled to enable use of stronger crypto algorithms.
#CONFIG_TLSV12=y

# Select which ciphers to use by default with OpenSSL if the user does not
# specify them.
#CONFIG_TLS_DEFAULT_CIPHERS="DEFAULT:!EXP:!LOW"

# If CONFIG_TLS=internal is used, additional library and include paths are
# needed for LibTomMath. Alternatively, an integrated, minimal version of
# LibTomMath can be used. See beginning of libtommath.c for details on benefits
# and drawbacks of this option.
#CONFIG_INTERNAL_LIBTOMMATH=y
#ifndef CONFIG_INTERNAL_LIBTOMMATH
#LTM_PATH=/usr/src/libtommath-0.39
#CFLAGS += -I$(LTM_PATH)
#LIBS += -L$(LTM_PATH)
#LIBS_p += -L$(LTM_PATH)
#endif
# At the cost of about 4 kB of additional binary size, the internal LibTomMath
# can be configured to include faster routines for exptmod, sqr, and div to
# speed up DH and RSA calculation considerably
#CONFIG_INTERNAL_LIBTOMMATH_FAST=y

# Interworking (IEEE 802.11u)
# This can be used to enable functionality to improve interworking with
# external networks.
#CONFIG_INTERWORKING=y

# Hotspot 2.0
#CONFIG_HS20=y

# Enable SQLite database support in hlr_auc_gw, EAP-SIM DB, and eap_user_file
CONFIG_SQLITE=y

# Enable Fast Session Transfer (FST)
#CONFIG_FST=y

# Enable CLI commands for FST testing
#CONFIG_FST_TEST=y

# Testing options
# This can be used to enable some testing options (see also the example
# configuration file) that are really useful only for testing clients that
# connect to this hostapd. These options allow, for example, to drop a
# certain percentage of probe requests or auth/(re)assoc frames.
#
#CONFIG_TESTING_OPTIONS=y

# Automatic Channel Selection
# This will allow hostapd to pick the channel automatically when channel is set
# to "acs_survey" or "0". Eventually, other ACS algorithms can be added in
# similar way.
#
# Automatic selection is currently only done through initialization, later on
# we hope to do background checks to keep us moving to more ideal channels as
# time goes by. ACS is currently only supported through the nl80211 driver and
# your driver must have survey dump capability that is filled by the driver
# during scanning.
#
# You can customize the ACS survey algorithm with the hostapd.conf variable
# acs_num_scans.
#
# Supported ACS drivers:
# * ath9k
# * ath5k
# * ath10k
#
# For more details refer to:
# https://wireless.wiki.kernel.org/en/users/documentation/acs
#
CONFIG_ACS=y

# Multiband Operation support
# These extensions facilitate efficient use of multiple frequency bands
# available to the AP and the devices that may associate with it.
#CONFIG_MBO=y

# Client Taxonomy
# Has the AP retain the Probe Request and (Re)Association Request frames from
# a client, from which a signature can be produced which can identify the model
# of client device like "Nexus 6P" or "iPhone 5s".
#CONFIG_TAXONOMY=y

# Fast Initial Link Setup (FILS) (IEEE 802.11ai)
#CONFIG_FILS=y
# FILS shared key authentication with PFS
#CONFIG_FILS_SK_PFS=y

# Include internal line edit mode in hostapd_cli. This can be used to provide
# limited command line editing and history support.
#CONFIG_WPA_CLI_EDIT=y

# Opportunistic Wireless Encryption (OWE)
# Experimental implementation of draft-harkins-owe-07.txt
#CONFIG_OWE=y

# Airtime policy support
#CONFIG_AIRTIME_POLICY=y

# Override default value for the wpa_disable_eapol_key_retries configuration
# parameter. See that parameter in hostapd.conf for more details.
#CFLAGS += -DDEFAULT_WPA_DISABLE_EAPOL_KEY_RETRIES=1

# Wired equivalent privacy (WEP)
# WEP is an obsolete cryptographic data confidentiality algorithm that is not
# considered secure. It should not be used for anything anymore. The
# functionality needed to use WEP is available in the current hostapd
# release under this optional build parameter. This functionality is subject to
# be completely removed in a future release.
#CONFIG_WEP=y

# Remove all TKIP functionality
# TKIP is an old cryptographic data confidentiality algorithm that is not
# considered secure. It should not be used anymore. For now, the default hostapd
# build includes this to allow mixed mode WPA+WPA2 networks to be enabled, but
# that functionality is subject to be removed in the future.
#CONFIG_NO_TKIP=y

# Pre-Association Security Negotiation (PASN)
# Experimental implementation based on IEEE P802.11z/D2.6 and the protocol
# design is still subject to change. As such, this should not yet be enabled in
# production use.
# This requires CONFIG_IEEE80211W=y to be enabled, too.
#CONFIG_PASN=y

# Device Provisioning Protocol (DPP) (also known as Wi-Fi Easy Connect)
CONFIG_DPP=y
# DPP version 2 support
CONFIG_DPP2=y
# DPP version 3 support (experimental and still changing; do not enable for
# production use)
#CONFIG_DPP3=y

# custom configuration options

# IEEE 802.11F/IAPP
CONFIG_IAPP=y

# IEEE 802.11w (management frame protection)
CONFIG_IEEE80211W=y

# IEEE 802.11n (High Throughput) support
CONFIG_IEEE80211N=y

CONFIG_MESH=y
CONFIG_SAE=y
CONFIG_WPS2=y

hostapd.initd

#!/sbin/openrc-run
# Copyright 1999-2006 Gentoo Foundation
# Modifications for Hyperbola Project 2024
# Distributed under the terms of the GNU General Public License v2

command="/usr/sbin/hostapd"
command_args="-B ${OPTIONS} ${CONFIGS}"
extra_started_commands="reload"
required_files="$CONFIGS"

depend() {
    need net
    after firewall
    use logger
}

reload() {
    ebegin "Reloading ${SVCNAME} configuration"
    kill -HUP $(pidof /usr/bin/hostapd) > /dev/null 2>&1
    eend $?
}

hostapd.confd

# Space separated list of configuration files
CONFIGS="/etc/hostapd/hostapd.conf"

# Extra options to pass to hostapd, see hostapd(8)
OPTIONS=""
Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!

28

Re: [Collection] Compilation of packages and ports (not in repositories)

Package mtr and mtr-gtk

PKGBUILD

# Maintainer (Arch): Levente Polyak <anthraxx[at]archlinux[dot]org>
# Contributor (Arch): Ionut Biru <ibiru@archlinux.org>
# Contributor (Arch): Douglas Soares de Andrade <douglas@archlinux.org>
# Maintainer: Tobias Dausend <throgh@hyperbola.info>

pkgbase=mtr
pkgname=('mtr' 'mtr-gtk')
pkgver=0.95
pkgrel=1
pkgdesc="Combines the functionality of traceroute and ping into one tool"
url='https://www.bitwizard.nl/mtr/'
arch=('i686' 'x86_64')
license=('GPL-2')
makedepends=('gdk-pixbuf2' 'glibc' 'gtk' 'jansson' 'libcap' 'ncurses')
install=mtr.install
source=(https://github.com/traviscross/mtr/archive/v${pkgver}/${pkgname}-${pkgver}.tar.gz)
sha512sums=('a7d69e0c551a10ae80a650a34588119e6c6b124a8c2c93d3de29e5daa6ef99f9217d875529d443c3760cd6fd7bd04d1e9abe33ef12635826c66a98bd776c1690')

prepare() {
  (cd ${pkgbase}-${pkgver}
    echo "${pkgver}" > .tarball-version
    autoreconf -fiv
  )
  cp -ra ${pkgbase}-${pkgver}{,-cli}
}

build() {
  (cd ${pkgbase}-${pkgver}-cli
    ./configure \
      --prefix=/usr \
      --without-gtk \
      --sbindir=/usr/bin
    make
  )
  (cd ${pkgbase}-${pkgver}
    ./configure \
      --prefix=/usr \
      --sbindir=/usr/bin
    make
  )
}

package_mtr() {
  pkgdesc="Combines the functionality of traceroute and ping into one tool (CLI version)"
  depends=('glibc' 'jansson' 'libcap' 'ncurses')
  optdepends=('bash-completion: bash completion support')
  cd ${pkgbase}-${pkgver}-cli
  make DESTDIR="${pkgdir}" install
  install -Dm644 COPYING -t "${pkgdir}/usr/share/licenses/${pkgname}"
}

package_mtr-gtk() {
  pkgdesc="Combines the functionality of traceroute and ping into one tool (GTK version)"
  depends=('gdk-pixbuf2' 'glib2' 'glibc' 'gtk' 'jansson' 'libcap' 'ncurses')
  optdepends=('bash-completion: bash completion support')
  conflicts=('mtr')
  provides=("mtr=${pkgver}")
  cd ${pkgbase}-${pkgver}
  make DESTDIR="${pkgdir}" install
  install -Dm644 COPYING -t "${pkgdir}/usr/share/licenses/${pkgname}"
}

mtr.install

post_install() {
  setcap cap_net_bind_service,cap_net_raw+ep usr/bin/mtr-packet
}

post_upgrade() {
  post_install
}
Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!

29

Re: [Collection] Compilation of packages and ports (not in repositories)

Package cataclysm-dda

# Maintainer (Arch): Sven-Hendrik Haase <svenstaro@archlinux.org>
# Contributor (Arch): Kyle Keen <keenerd@gmail.com>
# Maintainer: Tobias Dausend <throgh@hyperbola.info>

pkgbase=cataclysm-dda
pkgname=('cataclysm-dda' 'cataclysm-dda-tiles')
pkgname=cataclysm-dda
pkgver=0.F
_pkgver=0.F
_debver=$_pkgver
_debrel=3-9
pkgrel=1
pkgdesc="A post-apocalyptic, roguelike, free and libre game"
url='https://cataclysmdda.org/'
arch=('i686' 'x86_64')
license=('CC-BY-SA-3.0' 'Modified-BSD' 'Boost-1.0' 'GPL-3' 'Expat')
groups=('games')
depends=('ncurses' 'hicolor-icon-theme' 'gettext-tiny')
makedepends=('sdl2_image' 'sdl2_ttf' 'sdl2_mixer' 'freetype2' 'astyle' 'quilt')
source=("$pkgname-$_pkgver.tar.gz::https://github.com/CleverRaven/Cataclysm-DDA/archive/$_pkgver.tar.gz"
        "https://deb.debian.org/debian/pool/main/c/cataclysm-dda/cataclysm-dda_$_debver-$_debrel.debian.tar.xz")
sha512sums=('9dd32f6fda936b77007a1f0e3fca85c25c3c87f41819fa55b0c454c2cc756664a688c910bd981bc1ba14859401d0d8eebd1515d1b9d4a34d6ffe0303e699eb0b'
            '2aa1ebe42034e4f3ee48125db21baa299da8407f97bff81a42c04d82906e81298057f22e427b68f5738b9674b0d5bec06c51acc7a0c8ec67be1d6aa2d54b933e')

prepare() {
  cd "Cataclysm-DDA-$_pkgver"
  if [[ ${pkgver%.*} = ${_debver%.*} ]]; then
    # Debian patches
    export QUILT_PATCHES=debian/patches
    export QUILT_REFRESH_ARGS='-p ab --no-timestamps --no-index'
    export QUILT_DIFF_ARGS='--no-timestamps'

    mv "$srcdir"/debian/ ./

    quilt push -av
  fi
}

build() {
  cd "Cataclysm-DDA-$_pkgver"

  export CXXFLAGS="${CXXFLAGS/-Wp,-D_GLIBCXX_ASSERTIONS}"
  export CXXFLAGS="${CXXFLAGS/-fcf-protection}"
  export CXXFLAGS="${CXXFLAGS/-fstack-clash-protection}"

  make PREFIX=/usr PCH=0 ASTYLE=0 RELEASE=1 USE_XDG_DIR=1 LTO=1 RUNTESTS=0 LOCALIZE=1 LANGUAGES=all
  make PREFIX=/usr PCH=0 ASTYLE=0 RELEASE=1 USE_XDG_DIR=1 LTO=1 RUNTESTS=0 LOCALIZE=1 LANGUAGES=all TILES=1 SOUND=1
  ./lang/compile_mo.sh
}

package_cataclysm-dda() {
  cd "Cataclysm-DDA-$_pkgver"

  make DESTDIR="$pkgdir" PREFIX=/usr PCH=0 RELEASE=1 USE_XDG_DIR=1 LTO=1 RUNTESTS=0 LOCALIZE=1 LANGUAGES=all install

  # Docs
  install -d "$pkgdir/usr/share/doc/cataclysm-dda"
  cp -r doc/* "$pkgdir/usr/share/doc/cataclysm-dda"
  # undo symlink
  rm "$pkgdir/usr/share/doc/cataclysm-dda/JSON_LOADING_ORDER.md"
  cp 'data/json/LOADING_ORDER.md' "$pkgdir/usr/share/doc/cataclysm-dda/JSON_LOADING_ORDER.md"

  # Manpage
  rm "$pkgdir/usr/share/doc/cataclysm-dda/"*.6
  install -Dm644 -t "$pkgdir/usr/share/man/man6" "doc/cataclysm.6"

  # License
  install -Dm644 LICENSE.txt debian/copyright -t "$pkgdir/usr/share/licenses/$pkgname"

  # Languages
  cd lang/mo
  for i in *; do
    install -d "${pkgdir}/usr/share/locale/${i}/LC_MESSAGES"
    cp "${i}/LC_MESSAGES/cataclysm-dda.mo" "${pkgdir}/usr/share/locale/${i}/LC_MESSAGES"
  done
}

package_cataclysm-dda-tiles() {
  pkgdesc="A post-apocalyptic, roguelike, free and libre game (with graphics)"
  depends=('cataclysm-dda' 'sdl2_image' 'sdl2_ttf' 'freetype2' 'sdl2_mixer')
  cd "Cataclysm-DDA-$_pkgver"

  make DESTDIR="$pkgdir" PREFIX=/usr PCH=0 RELEASE=1 USE_XDG_DIR=1 LTO=1 LOCALIZE=1 LANGUAGES=all TILES=1 SOUND=1 install

  # Icons
  cd build-data/osx/AppIcon.iconset
  for i in *.png
  do
    local _isize="$(echo "$i" | sed -Ee 's/icon_([[:digit:]]+)x\1\.png/\1x\1/')"
    install -Dm644 "$i" "$pkgdir/usr/share/icons/hicolor/$_isize/apps/cataclysm-dda.png"
  done
  cd "$srcdir/Cataclysm-DDA-$_pkgver"

  # Manpage
  install -Dm644 -t "$pkgdir/usr/share/man/man6" "doc/cataclysm-tiles.6"

  # License
  install -Dm644 LICENSE.txt debian/copyright -t "$pkgdir/usr/share/licenses/$pkgname"

  # Remove overlapping files
  cd "$pkgdir/../cataclysm-dda"
  find . -type f -exec rm -f "$pkgdir"/{} \;
  cd "$pkgdir"
  find . -type d -empty -delete
}
Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!

30

Re: [Collection] Compilation of packages and ports (not in repositories)

Package desmume

PKGBUILD

# Maintainer (Arch): schuay <jakob.gruber@gmail.com>
# Contributor (Arch): Jonathan Conder <jonno dot conder at gmail dot com>
# Contributor (Arch): Brad Fanella <bradfanella@archlinux.us>
# Contributor (Arch): Arkham <arkham at archlinux dot us>
# Contributor (Arch): Nathan Jones <nathanj@insightbb.com>
# Contributor (Arch): Javier "Phrodo_00" Aravena <phrodo.00 at gmail dot com>
# Contributor (Arch): angvp <angvp at archlinux dot us>
# Contributor (Arch): Allan <mcrae_allan at hotmail dot com>
# Contributor (Arch): w0rm <w0rmtux at gmail dot com>
# Contributor (Arch): vEX <vex at niechift dot com>
# Contributor (Arch): Asher256 <achrafcherti at gmail dot com>
# Maintainer: Tobias Dausend <throgh@hyperbola.info>

pkgname=desmume
pkgver=0.9.11
_debver=$pkgver
_debrel=4.1
pkgrel=2
pkgdesc="Nintendo DS emulator"
arch=('i686' 'x86_64')
url="https://desmume.org/"
license=('GPL-2')
depends=('desktop-file-utils' 'libpcap' 'soundtouch' 'alsa-lib' 'glu' 'sdl' 'gtk2' 'zziplib' 'tinyxml')
makedepends=('quilt' 'intltool' 'mesa' 'clang')
source=("https://downloads.sourceforge.net/${pkgname}/${pkgname}-${pkgver}.tar.gz"
        "https://deb.debian.org/debian/pool/main/d/desmume/desmume_${_debver}-${_debrel}.debian.tar.xz")
sha512sums=('160cb6ec0ede04ad1fbddde2b7b04aa41fa464c8338d7eb9d7536196a82d8d716889b40be4fb831a22e3fe8532b947f7f0b41311601b6842be2516dff7cae46c'
            '22979722b6adfcbe44c908e727b563e3ee7653a36a372df36bba81b2743eaa24d328f11ccf378903288537c2459de7e6ed1f84716e2c52ba1235829a2db13705')

prepare() {
  cd "$srcdir/$pkgname-$pkgver"

  if [[ ${pkgver%.*} = ${_debver%.*} ]]; then
    # Debian patches
    export QUILT_PATCHES=debian/patches
    export QUILT_REFRESH_ARGS='-p ab --no-timestamps --no-index'
    export QUILT_DIFF_ARGS='--no-timestamps'

    mv "$srcdir"/debian .

    quilt push -av
  fi
}

build() {
  cd "$srcdir/$pkgname-$pkgver"

  ./configure \
    --prefix=/usr \
    --enable-wifi \
    --enable-openal
  make
}

package() {
  cd "$srcdir/$pkgname-$pkgver"

  make DESTDIR="$pkgdir/" install
  install -Dm644 COPYING -t "$pkgdir/usr/share/licenses/$pkgname"
}

gcc6_fixes.patch

From: zeromus
Origin: upstream, https://sourceforge.net/p/desmume/code/5514, https://sourceforge.net/p/desmume/code/5517, https://sourceforge.net/p/desmume/code/5430
Subject: fix GCC6 issues
Bug: https://sourceforge.net/p/desmume/bugs/1570/
Bug-Debian: http://bugs.debian.org/811691

Index: desmume/src/MMU_timing.h
===================================================================
--- desmume/src/MMU_timing.h    (revision 5513)
+++ desmume/src/MMU_timing.h    (revision 5517)
@@ -155,8 +155,8 @@
     enum { ASSOCIATIVITY = 1 << ASSOCIATIVESHIFT };
     enum { BLOCKSIZE = 1 << BLOCKSIZESHIFT };
     enum { TAGSHIFT = SIZESHIFT - ASSOCIATIVESHIFT };
-    enum { TAGMASK = (u32)(~0 << TAGSHIFT) };
-    enum { BLOCKMASK = ((u32)~0 >> (32 - TAGSHIFT)) & (u32)(~0 << BLOCKSIZESHIFT) };
+    enum { TAGMASK = (u32)(~0U << TAGSHIFT) };
+    enum { BLOCKMASK = ((u32)~0U >> (32 - TAGSHIFT)) & (u32)(~0U << BLOCKSIZESHIFT) };
     enum { WORDSIZE = sizeof(u32) };
     enum { WORDSPERBLOCK = (1 << BLOCKSIZESHIFT) / WORDSIZE };
     enum { DATAPERWORD = WORDSIZE * ASSOCIATIVITY };
Index: desmume/src/ctrlssdl.cpp
===================================================================
--- desmume/src/ctrlssdl.cpp    (revision 5513)
+++ desmume/src/ctrlssdl.cpp    (revision 5517)
@@ -200,7 +200,7 @@
           break;
         case SDL_JOYAXISMOTION:
           /* Dead zone of 50% */
-          if( (abs(event.jaxis.value) >> 14) != 0 )
+          if( ((u32)abs(event.jaxis.value) >> 14) != 0 )
             {
               key = ((event.jaxis.which & 15) << 12) | JOY_AXIS << 8 | ((event.jaxis.axis & 127) << 1);
               if (event.jaxis.value > 0) {
@@ -370,7 +370,7 @@
          Note: button constants have a 1bit offset. */
     case SDL_JOYAXISMOTION:
       key_code = ((event->jaxis.which & 15) << 12) | JOY_AXIS << 8 | ((event->jaxis.axis & 127) << 1);
-      if( (abs(event->jaxis.value) >> 14) != 0 )
+      if( ((u32)abs(event->jaxis.value) >> 14) != 0 )
         {
           if (event->jaxis.value > 0)
             key_code |= 1;
Index: desmume/src/wifi.cpp
===================================================================
--- desmume/src/wifi.cpp    (revision 5429)
+++ desmume/src/wifi.cpp    (revision 5430)
@@ -320,9 +320,9 @@
 
 #if (WIFI_LOGGING_LEVEL >= 1)
     #if WIFI_LOG_USE_LOGC
-        #define WIFI_LOG(level, ...) if(level <= WIFI_LOGGING_LEVEL) LOGC(8, "WIFI: "__VA_ARGS__);
+        #define WIFI_LOG(level, ...) if(level <= WIFI_LOGGING_LEVEL) LOGC(8, "WIFI: " __VA_ARGS__);
     #else
-        #define WIFI_LOG(level, ...) if(level <= WIFI_LOGGING_LEVEL) printf("WIFI: "__VA_ARGS__);
+        #define WIFI_LOG(level, ...) if(level <= WIFI_LOGGING_LEVEL) printf("WIFI: " __VA_ARGS__);
     #endif
 #else
 #define WIFI_LOG(level, ...) {}

gcc7_fixes.patch

From e1f7039f1b06add4fb75b2f8774000b8f05574af Mon Sep 17 00:00:00 2001
From: rogerman <rogerman@users.sf.net>
Date: Mon, 17 Aug 2015 21:15:04 +0000
Subject: Fix bug with libfat string handling.

diff --git a/src/utils/libfat/directory.cpp b/src/utils/libfat/directory.cpp
index 765d7ae5..b6d7f01f 100644
--- a/src/utils/libfat/directory.cpp
+++ b/src/utils/libfat/directory.cpp
@@ -139,7 +139,7 @@ static size_t _FAT_directory_mbstoucs2 (ucs2_t* dst, const char* src, size_t len
     int bytes;
     size_t count = 0;
 
-    while (count < len-1 && src != '\0') {
+    while (count < len-1 && *src != '\0') {
         bytes = mbrtowc (&tempChar, src, MB_CUR_MAX, &ps);
         if (bytes > 0) {
             *dst = (ucs2_t)tempChar;
Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!

31

Re: [Collection] Compilation of packages and ports (not in repositories)

Package lua-compat53

PKGBUILD

# Maintainer (Arch): Daurnimator <daurnimator@archlinux.org>
# Maintainer (Arch): Caleb Maclennan <caleb@alerque.com>
# Maintainer: Tobias Dausend <throgh@hyperbola.info>

pkgbase=lua-compat53
pkgname=('lua51-compat53' 'lua52-compat53')
pkgver=0.14.3
pkgrel=1
pkgdesc="Compatibility module providing Lua-5.3-style APIs"
arch=('i686' 'x86_64')
url='https://github.com/lunarmodules/lua-compat-5.3'
license=('Expat')
makedepends=('lua51' 'lua52')
source=("$pkgname-$pkgver.tar.gz::https://github.com/lunarmodules/lua-compat-5.3/archive/v$pkgver.tar.gz")
sha512sums=('9e355df0d1a165b7bbdc69c39fe49467ae5a7d93e02b875ade5863e2d44ba80955287210376fccbc5f2370970f5552774d84c812a9681d49a78b8eceeab37442')

build() {
  cd "lua-compat-5.3-$pkgver"
  mkdir 5.1 5.2

  gcc $CPPFLAGS $CFLAGS -fPIC -I/usr/include/lua5.1 -c lutf8lib.c -o 5.1/lutf8lib.o
  gcc $CPPFLAGS $CFLAGS -fPIC -I/usr/include/lua5.1 -c lstrlib.c -o 5.1/lstrlib.o
  gcc $CPPFLAGS $CFLAGS -fPIC -I/usr/include/lua5.1 -c ltablib.c -o 5.1/ltablib.o
  gcc -shared $LDFLAGS -o 5.1/utf8.so 5.1/lutf8lib.o
  gcc -shared $LDFLAGS -o 5.1/string.so 5.1/lstrlib.o
  gcc -shared $LDFLAGS -o 5.1/table.so 5.1/ltablib.o

  gcc $CPPFLAGS $CFLAGS -fPIC -I/usr/include/lua5.2 -c lutf8lib.c -o 5.2/lutf8lib.o
  gcc $CPPFLAGS $CFLAGS -fPIC -I/usr/include/lua5.2 -c lstrlib.c -o 5.2/lstrlib.o
  gcc $CPPFLAGS $CFLAGS -fPIC -I/usr/include/lua5.2 -c ltablib.c -o 5.2/ltablib.o
  gcc -shared $LDFLAGS -o 5.2/utf8.so 5.2/lutf8lib.o
  gcc -shared $LDFLAGS -o 5.2/string.so 5.2/lstrlib.o
  gcc -shared $LDFLAGS -o 5.2/table.so 5.2/ltablib.o
}

package_lua51-compat53() {
  pkgdesc="Compatibility module providing Lua-5.3-style APIs for Lua 5.1"

  cd "lua-compat-5.3-$pkgver"
  install -Dm644 compat53/{init,module,file_mt}.lua -t "$pkgdir/usr/share/lua/5.1/compat53"
  install -D 5.1/{utf8,string,table}.so -t "$pkgdir/usr/lib/lua/5.1/compat53/"
  install -Dm644 LICENSE -t "$pkgdir/usr/share/licenses/$pkgname"
}

package_lua52-compat53() {
  pkgdesc="Compatibility module providing Lua-5.3-style APIs for Lua 5.2"

  cd "lua-compat-5.3-$pkgver"
  install -Dm644 compat53/{init,module,file_mt}.lua -t "$pkgdir/usr/share/lua/5.2/compat53"
  install -D 5.2/{utf8,string,table}.so -t "$pkgdir/usr/lib/lua/5.2/compat53/"
  install -Dm644 LICENSE -t "$pkgdir/usr/share/licenses/$pkgname"
}
Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!

32

Re: [Collection] Compilation of packages and ports (not in repositories)

Package ttf-gentium

PKGBUILD

# Maintainer (Arch): Ivy Foster <code@iff.ink>
# Contributor (Arch): Lukas Jirkovsky <l.jirkovsky@gmail.com>
# Maintainer: Tobias Dausend <throgh@hyperbola.info>

pkgname=ttf-gentium
pkgver=1.03
pkgrel=1
pkgdesc="Font supporting a wide range of Latin- and Cyrillic-based alphabets"
url='https://software.sil.org/gentium/'
license=('OFL-1.1')
arch=('any')
source=("${pkgname}-${pkgver}.tar.xz::https://deb.debian.org/debian/pool/main/f/fonts-sil-gentium/fonts-sil-gentium_${pkgver}.orig.tar.xz")
sha512sums=('09112edb483baaf73f8c8343aab3272afa1276b402a1a98b60ce17767e58c18f241fe9250d8013e327a2b9cc6fe14486cd7a458ba0c291d09274a37ffa26bbe8')

package() {
  cd "fonts-sil-gentium-$pkgver"

  install -Dm644 *.ttf -t "$pkgdir/usr/share/fonts/TTF"
  install -Dm644 OFL{,-FAQ}.txt -t "$pkgdir/usr/share/licenses/$pkgname"
  install -Dm644 GENTIUM-FAQ.txt README.txt -t "$pkgdir/usr/share/doc/$pkgname"
}
Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!

33

Re: [Collection] Compilation of packages and ports (not in repositories)

Package sile

(as possible replacement for LaTex)

PKGBUILD

# Maintainer: Tobias Dausend <throgh@hyperbola.info>

pkgname=sile
pkgdesc="Free and libre typesetting engine, fully customizable in Lua"
pkgver=0.9.4
pkgrel=1
arch=('i686' 'x86_64')
url='https://www.sile-typesetter.org'
license=('Expat')
_luadeps=(lpeg
          filesystem
          compat53
          expat)
depends=("${_luadeps[@]/#/lua51-}" 'fontconfig' 'freetype2' 'ttf-gentium'
         'glibc' 'harfbuzz' 'icu' 'libpng' 'luajit' 'zlib')
source=("https://github.com/sile-typesetter/sile/releases/download/v${pkgver}/${pkgname}-${pkgver}.tar.bz2")
sha512sums=('194a6279aa2cd21772fb20adfd20e0d92e95fe652f9ba193e26d872bb5f9b5367f0e6cd15228f7a077881b510d82cc8fe7d0e90b40236fa0d4590971c6824108')

build () {
  cd "${pkgname}-${pkgver}"
  ./configure \
    --prefix /usr \
    --docdir /usr/share/doc/$pkgname
  make all
}

package () {
  cd "${pkgname}-${pkgver}"
  make install DESTDIR="$pkgdir"
  install -Dm644 LICENSE -t "$pkgdir/usr/share/licenses/$pkgname"
}
Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!

34

Re: [Collection] Compilation of packages and ports (not in repositories)

Package mariadb

We have removed mariadb out of the reasoning of being not fully compliant to community-oriented software. Sharing now the removed data from the commit here: https://git.hyperbola.info:50100/~team/ … 1d9aede210
Perhaps there is interest to create further packages from and for the community in a separate repository.

PKGBUILD

# Maintainer (Arch): Bartłomiej Piotrowski <bpiotrowski@archlinux.org>
# Maintainer (Arch): Christian Hesse <mail@eworm.de>
# Maintainer: André Silva <emulatorman@hyperbola.info>
# Contributor: Tobias Dausend <throgh@hyperbola.info>

pkgbase=mariadb
pkgname=('mariadb-libs' 'mariadb-clients' 'mariadb' 'mytop')
pkgver=10.3.24
_debver=$pkgver
_debrel=2
pkgrel=9
arch=('i686' 'x86_64')
license=('GPL-2')
url='https://mariadb.org/'
makedepends=('boost' 'bzip2' 'cmake' 'jemalloc' 'libaio' 'libxcrypt' 'libressl' 'libxml2'
             'lz4' 'lzo' 'zlib' 'quilt')
source=("https://archive.mariadb.org/mariadb-$pkgver/source/mariadb-$pkgver.tar.gz"{,.asc}
        "https://repo.hyperbola.info:50000/sources/${pkgbase}/${pkgbase}-10.3_$_debver-$_debrel.debian.tar.xz"{,.sig}
        "mariadb.initd"
        "mariadb.run"
        "mariadb_log.run"
        "fix-cmake.patch")
sha512sums=('cfd0154d984ddc344554cd3df1d02b0811f8e35c90caf745532491688850736d079c67d40e9414daba83f2bd0c06569bfc99213d5280c63cf051c68abd7c56b5'
            'SKIP'
            'f406e0d7f85654ad33ef2f9722ca40b4763b882d83083b547aead7f6033813c424cdae9b986351edf415c4eaff8f6a43cd5039ad2d98b962395018b8702cf3fd'
            'SKIP'
            '5661610576977b87b5435a304d8409962c4451389d6cd6801666c507e871e9182c37b56daa37c580a62ccf60ebfff34a9c1dc85da62a2dac5a69b8776c218020'
            '208f1246a3fc7478262e6a7d8e6d82d83377d8fd86ef7a7f3a03e2c2383367b9c0560e2ecbb4e686e4b6d64e48bb29f2b75780e4e449a4146fcb3d95e2e67c60'
            'ceccc2ceae499524322ec99d3929e088aaed4f94e52274d8a1691a22c0a322781dc93ac00fb28a91f3d0d1541e95de95d588d91011c4b0293b322c5f49d5fd69'
            '15179f2e10bd18612ad03d332cc27bde7751c29a7a0bd6661745f43370f93b947138618ab11f7c43831f47f1324538d563962d465b75e23b03f58eb558f194a3')
validpgpkeys=('199369E5404BD5FC7D2FE43BCBCB082A1BB943DB'  # MariaDB Package Signing Key <package-signing-key@mariadb.org>
              'C92BAA713B8D53D3CAE63FC9E6974752F9704456') # André Silva

prepare() {
  cd $pkgbase-$pkgver/

  if [[ ${pkgver%.*} = ${_debver%.*} ]]; then
    # Debian patches
    export QUILT_PATCHES=debian/patches
    export QUILT_REFRESH_ARGS='-p ab --no-timestamps --no-index'
    export QUILT_DIFF_ARGS='--no-timestamps'

    rm -r debian
    mv "$srcdir"/debian .

    quilt push -av
  fi
  patch -Np1 -i ${srcdir}/fix-cmake.patch
}

build() {
  local _cmake_options=(
    # build options
    -DCMAKE_BUILD_TYPE=RelWithDebInfo
    -Wno-dev

    # file paths
    # /etc
    -DINSTALL_SYSCONFDIR=/etc
    -DINSTALL_SYSCONF2DIR=/etc/my.cnf.d
    # /run
    -DINSTALL_UNIX_ADDRDIR=/run/mysqld/mysqld.sock
    # /usr
    -DCMAKE_INSTALL_PREFIX=/usr
    # /usr/bin /usr/include
    -DINSTALL_SCRIPTDIR=bin
    -DINSTALL_INCLUDEDIR=include/mysql
    # /usr/lib
    -DINSTALL_PLUGINDIR=lib/mysql/plugin
    # /usr/share
    -DINSTALL_SHAREDIR=share
    -DINSTALL_SUPPORTFILESDIR=share/mysql
    -DINSTALL_MYSQLSHAREDIR=share/mysql
    -DINSTALL_DOCREADMEDIR=share/doc/mariadb
    -DINSTALL_DOCDIR=share/doc/mariadb
    -DINSTALL_MANDIR=share/man
    # /var
    -DMYSQL_DATADIR=/var/lib/mysql

    # default settings
    -DDEFAULT_CHARSET=utf8mb4
    -DDEFAULT_COLLATION=utf8mb4_unicode_ci

    # features
    -DENABLED_LOCAL_INFILE=ON
    -DPLUGIN_EXAMPLE=NO
    -DPLUGIN_FEDERATED=NO
    -DPLUGIN_FEEDBACK=NO
    -DWITH_EMBEDDED_SERVER=ON
    -DWITH_EXTRA_CHARSETS=complex
    -DWITH_LIBWRAP=OFF
    -DWITH_PCRE=bundled
    -DWITH_READLINE=ON
    -DWITH_JEMALLOC=system
    -DWITH_SSL=system
    -DWITH_SYSTEMD=no
    -DWITH_UNIT_TESTS=OFF
    -DWITH_ZLIB=system
  )

  mkdir build
  cd build

  cmake ../"$pkgbase-$pkgver" "${_cmake_options[@]}"

  make
}

package_mariadb-libs() {
  pkgdesc='MariaDB libraries'
  depends=('bzip2' 'libaio' 'libxcrypt' 'libressl' 'lz4' 'lzo' 'xz' 'zlib')
  conflicts=('libmysqlclient' 'libmariadbclient' 'mariadb-connector-c')
  provides=('libmariadbclient' 'mariadb-connector-c')
  replaces=('libmariadbclient')

  cd build

  for dir in libmariadb libmysqld libservices include; do
    make -C $dir DESTDIR="$pkgdir" install
  done

  ln -s mariadb_config "$pkgdir"/usr/bin/mysql_config
  install -D -m0644 "$srcdir"/$pkgbase-$pkgver/man/mysql_config.1 "$pkgdir"/usr/share/man/man1/mysql_config.1

  install -D -m0644 support-files/mariadb.pc "$pkgdir"/usr/share/pkgconfig/mariadb.pc
  install -D -m0644 "$srcdir"/$pkgbase-$pkgver/support-files/mysql.m4 "$pkgdir"/usr/share/aclocal/mysql.m4

  # remove static libraries
  rm "$pkgdir"/usr/lib/*.a

  # install license files
  install -dm0755 "$pkgdir"/usr/share/licenses/$pkgname
  install -m0644 "$srcdir"/$pkgbase-$pkgver/COPYING* "$pkgdir"/usr/share/licenses/$pkgname
}

package_mariadb-clients() {
  pkgdesc='MariaDB client tools'
  depends=("mariadb-libs=${pkgver}" 'jemalloc')
  conflicts=('mysql-clients')
  provides=("mysql-clients=$pkgver")

  cd build

  make -C client DESTDIR="$pkgdir" install

  # install man pages
  for man in mysql mysql_plugin mysql_upgrade mysqladmin mysqlbinlog mysqlcheck mysqldump mysqlimport mysqlshow mysqlslap mysqltest; do
    install -D -m0644 "$srcdir"/$pkgbase-$pkgver/man/$man.1 "$pkgdir"/usr/share/man/man1/$man.1
  done

  # install license files
  install -dm0755 "$pkgdir"/usr/share/licenses/$pkgname
  install -m0644 "$srcdir"/$pkgbase-$pkgver/COPYING* "$pkgdir"/usr/share/licenses/$pkgname
}

package_mariadb() {
  pkgdesc='Fast SQL database server, drop-in replacement for MySQL'
  backup=('etc/my.cnf'
          'etc/my.cnf.d/client.cnf'
          'etc/my.cnf.d/enable_encryption.preset'
          'etc/my.cnf.d/mysql-clients.cnf'
          'etc/my.cnf.d/server.cnf')
  install=mariadb.install
  depends=("mariadb-clients=${pkgver}" 'inetutils' 'libxml2')
  optdepends=('perl-dbd-mysql: for mysqlhotcopy, mysql_convert_table_format and mysql_setpermission'
              'logger: message logging support')
  conflicts=('mysql')
  provides=("mysql=$pkgver")
  options=('emptydirs')

  cd build

  make DESTDIR="$pkgdir" install

  cd "$pkgdir"

  rm -r etc/init.d
  rm usr/bin/rcmysql
  rm usr/share/mysql/{binary-configure,mysql{,d_multi}.server}

  install -Dm0755 "${srcdir}"/mariadb.initd etc/init.d/mariadb

  install -Dm0755 "${srcdir}"/mariadb.run etc/sv/mariadb/run
  install -Dm0755 "${srcdir}"/mariadb_log.run etc/sv/mariadb/log/run

  install -dm0700 var/lib/mysql
  chown -R 89:89 var/lib/mysql &>/dev/null

  # move mysqld to /usr/sbin
  install -dm0755 usr/sbin
  mv usr/{,s}bin/mysqld

  # install license files
  install -dm0755 "$pkgdir"/usr/share/licenses/$pkgname
  install -m0644 "$srcdir"/$pkgbase-$pkgver/COPYING* "$pkgdir"/usr/share/licenses/$pkgname

  # move it where one might look for it
  mv usr/share/{groonga{,-normalizer-mysql},doc/mariadb/}

  # provided by mariadb-libs
  rm usr/bin/mariadb_config
  rm usr/bin/mysql_config
  rm -r usr/include/
  rm usr/share/man/man1/mysql_config.1
  rm -r usr/share/aclocal
  rm usr/lib/lib*
  rm usr/lib/mysql/plugin/{auth_gssapi_client,caching_sha2_password,client_ed25519,dialog,mysql_clear_password,sha256_password}.so
  rm -r usr/lib/pkgconfig/

  # provided by mariadb-clients
  rm usr/bin/{mysql,mysql_plugin,mysql_upgrade,mysqladmin,mysqlbinlog,mysqlcheck,mysqldump,mysqlimport,mysqlshow,mysqlslap,mysqltest}
  rm usr/share/man/man1/{mysql,mysql_plugin,mysql_upgrade,mysqladmin,mysqlbinlog,mysqlcheck,mysqldump,mysqlimport,mysqlshow,mysqlslap,mysqltest}.1

  # provided by mytop
  rm usr/bin/mytop

  # not needed
  rm -r usr/{data,mysql-test,sql-bench}
  rm usr/share/man/man1/mysql-test-run.pl.1
}

package_mytop() {
  pkgdesc='Top clone for MariaDB'
  depends=('perl' 'perl-dbd-mysql' 'perl-term-readkey')

  cd build

  install -Dm0755 scripts/mytop "$pkgdir"/usr/bin/mytop

  # install license files
  install -dm0755 "$pkgdir"/usr/share/licenses/$pkgname
  install -m0644 "$srcdir"/$pkgbase-$pkgver/COPYING* "$pkgdir"/usr/share/licenses/$pkgname
}

fix-cmake.patch

--- a/libmariadb/cmake/ConnectorName.cmake    2020-08-06 17:15:46.000000000 +0200
+++ b/libmariadb/cmake/ConnectorName.cmake    2023-01-22 10:49:08.416903691 +0100
@@ -11,18 +11,22 @@
   SET(IS64 1)
 ENDIF()
 
-SET (PLAFORM_NAME CMAKE_SYSTEM_NAME)
-SET (MACHINE_NAME CMAKE_SYSTEM_PROCESSOR)
+SET (PLATFORM_NAME ${CMAKE_SYSTEM_NAME})
+SET (MACHINE_NAME ${CMAKE_SYSTEM_PROCESSOR})
 SET (CONCAT_SIGN "-")
 
 IF(CMAKE_SYSTEM_NAME MATCHES "Windows")
   SET(PLATFORM_NAME "win")
   SET(CONCAT_SIGN "")
   IF(IS64)
-    SET(MACHINE_NAME "x64")
+    IF(CMAKE_C_COMPILER_ARCHITECTURE_ID)
+      STRING(TOLOWER "${CMAKE_C_COMPILER_ARCHITECTURE_ID}" MACHINE_NAME)
+    ELSE()
+      SET(MACHINE_NAME x64)
+    ENDIF()
   ELSE()
     SET(MACHINE_NAME "32")
-  END()
+  ENDIF()
 ENDIF()
 
 SET(product_name "mysql-connector-c-${CPACK_PACKAGE_VERSION}-${PLATFORM_NAME}${CONCAT_SIGN}${MACHINE_NAME}")

mariadb.initd

#!/sbin/openrc-run
# Copyright 2018 Hyperbola Project
# Distributed under the terms of the GNU General Public License v2

getconf() {
    v=$(my_print_defaults --mysqld | grep ^--$1)
    [ -z $v ] && echo $2 || echo ${v#*=}
}

retry="60"
command="/usr/bin/mysqld_safe"
command_args="--syslog --nowatch"
command_user="mysql"

depend() {
    use logger net
    need localmount
}

start_pre() {
    pidfile=$(getconf pid-file "/run/mysqld/mysqld.pid")
    command_args="$command_args --pid-file=$pidfile"
    required_dirs=$(getconf datadir "/var/lib/mysql")
    if [ ! -d $required_dirs/mysql ]; then
        eerror "Datadir '$required_dirs' is empty or invalid."
        eerror "Run 'mysql_install_db --user=mysql --basedir=/usr --datadir=/var/lib/mysql' to create a new database."
    fi
    checkpath --directory --owner mysql:mysql --mode 0755 /run/mysqld
}

start_post() {
    ewaitfile 10 $(getconf socket "/run/mysqld/mysqld.sock")
}

stop_pre() {
    pidfile=$(getconf pid-file "/run/mysqld/mysqld.pid")
}

mariadb.install

post_install(){
  if ! getent group mysql &>/dev/null; then
    groupadd -g 89 mysql >/dev/null
  fi
  if ! getent passwd mysql &>/dev/null; then
    useradd -u 89 -g 89 -d /var/lib/mysql -s /bin/nologin mysql >/dev/null
  fi
  if ! groups mysql | grep adm &>/dev/null; then
    gpasswd -a mysql adm >/dev/null
  fi
  mysql_shell=$(getent passwd mysql | cut -d: -f7)
  if [ "$mysql_shell" != '/bin/nologin' ]; then
    chsh -s /bin/nologin mysql &>/dev/null
  fi

  echo ":: You need to initialize the MariaDB data directory prior to starting"
  echo "   the service. This can be done with mysql_install_db command, e.g.:"
  echo "   mysql_install_db --user=mysql --basedir=/usr --datadir=/var/lib/mysql"
}

post_upgrade(){
  if ! getent group mysql &>/dev/null; then
    groupadd -g 89 mysql >/dev/null
  fi
  if ! getent passwd mysql &>/dev/null; then
    useradd -u 89 -g 89 -d /var/lib/mysql -s /bin/nologin mysql >/dev/null
  fi
  if ! groups mysql | grep adm &>/dev/null; then
    gpasswd -a mysql adm >/dev/null
  fi
  mysql_shell=$(getent passwd mysql | cut -d: -f7)
  if [ "$mysql_shell" != '/bin/nologin' ]; then
    chsh -s /bin/nologin mysql &>/dev/null
  fi

  if [[ "$(vercmp $2 5.5.25-4)" -lt 0 ]] && [[ -d /data ]]; then
    for x in data/*; do
      cp -r $x /var/lib/mysql
    done
    rm -rf data
  fi
}

post_remove() {
  if getent passwd mysql &>/dev/null; then
    userdel mysql >/dev/null
  fi
  if getent group mysql &>/dev/null; then
    groupdel mysql >/dev/null
  fi
}

mariadb.run

#!/bin/sh
[ ! -d /run/mysqld ] && mkdir -p /run/mysqld
chown mysql:mysql /run/mysqld
exec chpst -U mysql:mysql mysqld --user=mysql 2>&1
Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!

35

Re: [Collection] Compilation of packages and ports (not in repositories)

Package perl-dbd-mysql

PKGBUILD

# Maintainer (Arch): Felix Yan <felixonmars@archlinux.org>
# Contributor (Arch): Bartłomiej Piotrowski <bpiotrowski@archlinux.org>
# Contributor (Arch): kevin <kevin@archlinux.org>
# Contributor (Arch): Eric Johnson <eric@coding-zone.com>
# Maintainer: André Silva <emulatorman@hyperbola.info>

pkgname=perl-dbd-mysql
pkgver=4.050
_debver=4.050
_debrel=3
pkgrel=1
pkgdesc='Perl/CPAN DBD::mysql module for interacting with MySQL via DBD'
arch=('i686' 'x86_64')
license=('GPL-1')
url="https://metacpan.org/release/DBD-mysql"
depends=('mariadb-libs' 'perl-dbi')
makedepends=('perl-devel-checklib' 'quilt')
checkdepends=('mariadb' 'perl-test-deep')
options=('!emptydirs')
source=(https://search.cpan.org/CPAN/authors/id/D/DV/DVEEDEN/DBD-mysql-${pkgver}.tar.gz
        https://deb.debian.org/debian/pool/main/libd/libdbd-mysql-perl/libdbd-mysql-perl_$_debver-$_debrel.debian.tar.xz
        mariadb-10.3.13-zerofill.patch)
sha512sums=('910f5b4ba7a7890d50a79f37d04ec8971a4f62acd0fe30bf3ab634f66e3128f0cd6513e5c9da8c807a0f4477d0cc766682ea8dd0d8072d02821b78df51f37879'
            '91a2f1e0137228d23a07271a6f2231c3c1966ef4d8d39407117942409f4ac94b089710f846f6f845d3dc1faa28a9eeaa9b89be228c388179060b279d50de7344'
            '090039d383d05958c5d0cf23f13b8062ba89158583ca6dad9ce7c72b28bc3eccc039d4f815aef13592ea35a57662c80156b25aaa04ace171d64a15f5ac489a09')

prepare() {
  cd DBD-mysql-$pkgver

  if [[ ${pkgver%.*} = ${_debver%.*} ]]; then
    # Debian patches
    export QUILT_PATCHES=debian/patches
    export QUILT_REFRESH_ARGS='-p ab --no-timestamps --no-index'
    export QUILT_DIFF_ARGS='--no-timestamps'

    mv "$srcdir"/debian .

    quilt push -av
  else
    # https://github.com/perl5-dbi/DBD-mysql/issues/304
    patch -Np1 -i ../mariadb-10.3.13-zerofill.patch
  fi
}

build() {
  cd DBD-mysql-$pkgver
  perl Makefile.PL INSTALLDIRS=vendor --testsocket=/tmp/socket.mysql
  make
}

check() {
  cd DBD-mysql-$pkgver
  mkdir -p /tmp/mysql_test
  mysql_install_db \
     --basedir=/usr \
     --datadir=/tmp/mysql_test
  mysqld -P 17999 \
     --socket=/tmp/socket.mysql \
     --datadir=/tmp/mysql_test &
  sleep 10
  DAEMON_PORT=$!
  make test
  kill -9 $DAEMON_PORT
}

package() {
  cd DBD-mysql-$pkgver
  make install DESTDIR="$pkgdir"
  install -Dm644 LICENSE $pkgdir/usr/share/licenses/$pkgname/LICENSE
}

mariadb-10.3.13-zerofill.patch

From 19734814ed4beeebd48180ad4c123047e3743ff2 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Dani=C3=ABl=20van=20Eeden?= <git@myname.nl>
Date: Tue, 5 Mar 2019 16:24:17 +0100
Subject: [PATCH] Fix for MariaDB 10.3.13 with zerofil

Issue: #304
---
 dbdimp.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/dbdimp.c b/dbdimp.c
index a9c37cf..0cea5c8 100644
--- a/dbdimp.c
+++ b/dbdimp.c
@@ -4055,9 +4055,13 @@ int dbd_describe(SV* sth, imp_sth_t* imp_sth)
         break;
 
       default:
-#if MYSQL_VERSION_ID > 100300
+#if (MYSQL_VERSION_ID > 100300) && (MYSQL_VERSION_ID < 10313)
         // https://jira.mariadb.org/browse/MDEV-18143
         buffer->buffer_length= fields[i].max_length ? fields[i].max_length : 2;
+#elif MYSQL_VERSION_ID > 100312
+        // https://jira.mariadb.org/browse/MDEV-18823
+        buffer->buffer_length= fields[i].max_length ? fields[i].max_length + 1 : 2;
+        buffer->buffer_length= fields[i].length > fields[i].max_length ? fields[i].length + 1 : 2;
 #else
         buffer->buffer_length= fields[i].max_length ? fields[i].max_length : 1;
 #endif
Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!

36

Re: [Collection] Compilation of packages and ports (not in repositories)

Package iec16022

PKGBUILD

# Maintainer (Arch): Balló György <ballogyor+arch at gmail dot com>
# Maintainer: Tobias Dausend <throgh@hyperbola.info>

pkgname=iec16022
pkgver=0.3.1
pkgrel=1
pkgdesc='Produce 2D barcodes often also referenced as DataMatrix'
arch=('i686' 'x86_64')
url='https://rdoeffinger.github.io/'
license=('GPL-2')
depends=('popt' 'zlib')
source=("https://github.com/rdoeffinger/$pkgname/releases/download/v$pkgver/$pkgname-$pkgver.tar.xz")
sha512sums=('90044be3b4b8750a7c99399c33084612dc58912b138789239dbabdab7cc2d526040e325f7ade7b129aa14ee044cf032c6b928dc2b4761b48de6cd17b3051416c')

build() {
  cd $pkgname-$pkgver
  ./configure \
    --prefix=/usr
  make
}

package() {
  cd $pkgname-$pkgver
  make DESTDIR="$pkgdir" install
  install -Dm644 COPYING -t "$pkgdir/usr/share/licenses/$pkgname"
}
Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!

37

Re: [Collection] Compilation of packages and ports (not in repositories)

Package lzdoom

PKGBUILD

# Maintainer (Arch): Lawrence González <pentestian [at] airmail [dot] cc>
# Contributor (Arch): Jan Cholasta <grubber at grubber cz>
# Maintainer: Tobias Dausend <throgh@hyperbola.info>

_name=gzdoom
pkgname=lzdoom
pkgver=3.88
pkgrel=1
pkgdesc="Advanced Doom source port with OpenGL support (legacy version)"
arch=('i686' 'x86_64')
url='http://www.zdoom.org/'
license=('Modified-BSD' 'custom:dumb' 'custom:bzip2' 'GPL-3' 'LGPL-3' 'Expat')
depends=('hicolor-icon-theme' 'libjpeg-turbo' 'sdl2' 'alsa-lib')
makedepends=('cmake' 'fluidsynth>=2' 'gtk' 'graphicsmagick')
optdepends=('fluidsynth>=2: FluidSynth MIDI device'
            'freedoom: Freedoom game data'
            'freedm: FreeDM game data'
            'blasphemer: Blasphemer game data'
            'gtk: IWAD selection dialog'
            'libsndfile: WAV/FLAC/OGG audio support'
            'mpg123: MP3 audio support'
            'openal: in-game sound'
            'soundfont-fluid: FluidR3 soundfont for FluidSynth'
            'xenocara-xmessage: crash dialog (other)')
groups=('games')
source=("${pkgname}-${pkgver}.tar.gz::https://github.com/drfrag666/${_name}/archive/refs/tags/${pkgver}.tar.gz"
        "${pkgname}.desktop")
sha512sums=('0b883991b35bbe44943404a04e59f47848bbd9ffc7d6b4949a2c6f1f365a90e116a567f3b276697e83587e991c385c32f9ee1d7c6bb86776400dfbdf2606018b'
            '0c5d97ec8e43ea65c62a5bbf261c016beaf8144bfa521e17540db563df165c17569829e4d83a4b9e55900b0620efe6a788ff2c828fd24b3918f3bc0349d16bda')

prepare() {
  cd "$srcdir/${_name}-$pkgver"

  # Patches GCC 11 errors
  sed -i '/^#include "types.h"$/a \#include <limits>' src/scripting/types.cpp

  # Patches soundfonts paths
  sed -i -f - src/gameconfigfile.cpp <<- "EOF"
        \%^\t\tSetValueForKey("Path", "/usr/share/games/doom/fm_banks", true);$% a \
        \t\tSetValueForKey("Path", SHARE_DIR "/soundfonts", true);\
        \t\tSetValueForKey("Path", SHARE_DIR "/fm_banks", true);\
        \t\tSetValueForKey("Path", "/usr/share/soundfonts", true);
        EOF
}

build() {
  cd "$srcdir/${_name}-$pkgver"

  local _cflags="-ffile-prefix-map=\"$PWD\"=. \
                 -DSHARE_DIR=\\\"/usr/share/games/$pkgname\\\" \
                 -DFLUIDSYNTHLIB2=\\\"libfluidsynth.so.2\\\""
  cmake -DCMAKE_BUILD_TYPE=Release \
                 -DCMAKE_C_FLAGS="${CFLAGS} ${_cflags}" \
                 -DCMAKE_CXX_FLAGS="${CXXFLAGS} ${_cflags}" \
                 -DCMAKE_EXE_LINKER_FLAGS="${LDFLAGS} -Wl,-z,noexecstack" \
                 -DCMAKE_INSTALL_PREFIX=/usr \
                 -DINSTALL_PATH=games \
                 -DINSTALL_PK3_PATH="share/games/$pkgname" \
                 .
  make
}

package() {
  cd "$srcdir/${_name}-$pkgver"

  make install DESTDIR="$pkgdir"
  install -D -m644 "soundfonts/${pkgname}.sf2" \
    "$pkgdir/usr/share/games/$pkgname/soundfonts/${pkgname}.sf2"
  install -D -m644 fm_banks/GENMIDI.GS.wopl \
    "$pkgdir/usr/share/games/$pkgname/fm_banks/GENMIDI.GS.wopl"
  install -D -m644 fm_banks/gs-by-papiezak-and-sneakernets.wopn \
    "$pkgdir/usr/share/games/$pkgname/fm_banks/gs-by-papiezak-and-sneakernets.wopn"

  install -D -m644 "$srcdir/${pkgname}.desktop" \
    "$pkgdir/usr/share/applications/${pkgname}.desktop"
  for SIZE in 16 24 32 48 64 96 128 256; do
    # set modify/create for reproducible builds
    gm convert -scale ${SIZE} +set date:create +set date:modify \
      "ico_${pkgname}.png" \
      "${srcdir}"/$pkgname.png
    install -Dm644 "${srcdir}"/$pkgname.png "${pkgdir}/usr/share/icons/hicolor/${SIZE}x${SIZE}/apps/$pkgname.png"
  done

  install -D -m644 -t "$pkgdir/usr/share/licenses/$pkgname" docs/licenses/*
}

lzdoom.desktop

[Desktop Entry]
Type=Application
Version=1.0
Name=LZDoom
Comment=Advanced Doom source port with OpenGL.
Icon=lzdoom
Exec=lzdoom %F
Terminal=false
MimeType=application/x-doom-wad;
Categories=Game;ActionGame;
Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!

38

Re: [Collection] Compilation of packages and ports (not in repositories)

Package perp

PKGBUILD

# Maintainer: Tobias Dausend <throgh@hyperbola.info>

pkgname=perp
pkgver=2.07
pkgrel=1
arch=('i686' 'x86_64')
pkgdesc="Perp, a persistent process supervisor"
url='http://b0llix.net/perp/'
license=('Simplified-BSD')
install=$pkgname.install
source=("http://b0llix.net/perp/distfiles/$pkgname-$pkgver.tar.gz")
sha512sums=('7b9ddd5b72ac88f34598ffe82e5cb1cc460a1d84daa6d52222aaa3ce891e7fa9b12839fc87cae80c913349684ec369155bae3955a8d06067859b57bbd4818c7e')

build() {
  cd $srcdir/$pkgname-$pkgver
  make
}

package() {
  cd $srcdir/$pkgname-$pkgver
  make DESTDIR=$pkgdir install
  install -Dm644 LICENSE -t $pkgdir/usr/share/licenses/$pkgname
}

perp.install

post_install() {
echo " >> to activate perp, run the commands "
echo " >> # perp-setup /etc/perp"
echo " >> # kill -HUP 1"
echo " >> become familiar with perp's configuration and operation. skim the manual pages for perp_intro(8), perpd(8), and perpetrate(5)."
}

post_upgrade() {
echo " >> If upgrading a previous perp installation, follow all the steps above. The perp-setup(8) utility script will not disturb any previous 
configuration it finds in any of /etc/inittab, /etc/rc.local, or /etc/perp/.boot."
echo " >> As a special case, if upgrading from perp-0.00 to a later release in"
echo " >> the perp-2.* series, it will be necessary to remove a couple of old"
echo " >> files from the earlier release manually. These are:"
echo " >> /usr/sbin/perpetrate"
echo " >> /usr/share/man/man8/perpetrate.8"
} 
Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!

39

Re: [Collection] Compilation of packages and ports (not in repositories)

Package wesnoth-legacy

PKGBUILD

# Maintainer (Arch): Sven-Hendrik Haase <svenstaro@gmail.com>
# Contributor (Arch): Jan de Groot <jgc@archlinux.org>
# Contributor (Arch): Tobias Powalowski <tpowa@archlinux.org>
# Contributor (Arch): Jacobo Arvelo <unix4all@ya.com>
# Contributor (Arch): Douglas Soares de Andrade <douglas@archlinux.org>
# Maintainer: Tobias Dausend <throgh@hyperbola.info>

_realpkgname=wesnoth
pkgname=$_realpkgname-legacy
pkgver=1.16.9
pkgrel=1
pkgdesc="A free, libre and turn-based strategy game on a fantasy world (legacy version)"
arch=('i686' 'x86_64')
license=('GPL-2')
url='https://github.com/wesnoth/wesnoth'
depends=('sdl2_ttf' 'sdl2_net' 'sdl2_mixer' 'sdl2_image' 'fribidi' 'boost-libs' 'pango' 'lua' 'tauthon')
makedepends=('boost' 'cmake' 'intltool' 'gettext-tiny')
groups=('games')
options=(!emptydirs)
source=("${_realpkgname}-${pkgver}.tar.gz::https://github.com/wesnoth/wesnoth/archive/refs/tags/${pkgver}.tar.gz")
sha512sums=('313aaad95c66757a952c00f1e5a515ce61bcf7564d6555802bc2619714d038a9a5607f3395e3e8afe5f216205e5b9b07b651789a749b4de37b30f8b8a47cb47f')

build() {
  cmake \
    -S $_realpkgname-$pkgver \
    -B build \
    -DCMAKE_INSTALL_PREFIX="/usr/" \
    -DCMAKE_INSTALL_BINDIR="/usr/games" \
    -DCMAKE_INSTALL_DATAROOTDIR="/usr/share/games" \
    -DCMAKE_INSTALL_MANDIR="/usr/share/man" \
    -DDATADIRNAME="wesnoth" \
    -DLOCALEDIR="locale" \
    -DENABLE_DISPLAY_REVISION=OFF
  make -C build
}

package() {
  make DESTDIR="$pkgdir" -C build install

  # correcting wrong folder-location
  mv "$pkgdir/usr/share/games/"{applications,doc,icons,metainfo} "$pkgdir/usr/share"

  # license
  install -Dm644 "$srcdir/$_realpkgname-$pkgver/COPYING" -t "${pkgdir}/usr/share/licenses/$pkgname"
}
Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!

40

Re: [Collection] Compilation of packages and ports (not in repositories)

Package sbcl-legacy

PKGBUILD

# Maintainer (Arch): Juergen Hoetzel <juergen@archlinux.org>
# Contributor (Arch): John Proctor <jproctor@prium.net>
# Contributor (Arch): Daniel White <daniel@whitehouse.id.au>
# Contributor (Arch): Leslie Polzer (skypher)
# Maintainer: Tobias Dausend <throgh@hyperbola.info>

_realpkgname=sbcl
pkgname=$_realpkgname-legacy
pkgver=2.2.5
pkgrel=1
pkgdesc="Steel Bank Common Lisp (legacy version)"
url='https://www.sbcl.org/'
arch=('i686' 'x86_64')
license=('Expat' 'Modified-BSD')
depends=('zlib')
provides=('common-lisp' 'cl-asdf')
makedepends=('clisp')
source=("https://downloads.sourceforge.net/project/sbcl/sbcl/$pkgver/$_realpkgname-$pkgver-source.tar.bz2"
        "fixes.lisp")
sha512sums=('9d581535348bb709ca1f7edbe5ad92f079fd1cbc9a462524220fb229bd78770f7855c0b1a8641b990a1d663fb559edc0c2ca0f029281d4b0c80a5917b45d7b72'
            '0f3680e3eddbc7c8837f036de6bacd36c4c3916cfcf265b2dffcc8cde5b29c7c9dc1588f0b9ac33cc86c020d83379a078fbfa7c02286396bd4a1399eced0265b')

build() {
  cd "$srcdir/$_realpkgname-$pkgver"
  export CFLAGS+=" -D_GNU_SOURCE -fno-omit-frame-pointer -DSBCL_HOME=/usr/lib/sbcl"
  export GNUMAKE="make"

  # build system uses LINKFLAGS and OS_LIBS to build LDFLAGS
  export LINKFLAGS="$LDFLAGS"
  unset LDFLAGS
  unset MAKEFLAGS
  sh make.sh clisp --prefix=/usr --fancy
  make -C doc/manual info
}

package() {
  cd "$srcdir/$_realpkgname-$pkgver"

  # cannot have both SBCL_HOME and INSTALL_ROOT
  SBCL_HOME="" INSTALL_ROOT="$pkgdir/usr" sh install.sh

  src/runtime/sbcl --core output/sbcl.core --script "${srcdir}/fixes.lisp"
  mv sbcl-new.core "${pkgdir}/usr/lib/sbcl/sbcl.core"

  # sources
  mkdir -p "$pkgdir/usr/share/sbcl-source"
  cp -R -t "$pkgdir/usr/share/sbcl-source" "$srcdir/$_realpkgname-$pkgver/"{src,contrib}

  # license
  install -D -m644 "$srcdir/$_realpkgname-$pkgver/COPYING" -t "$pkgdir/usr/share/licenses/$pkgname"

  # drop unwanted files
  find "$pkgdir" \( -name Makefile -o -name .cvsignore \) -delete
  find "$pkgdir/usr/share/sbcl-source" -type f \
    \( -name \*.fasl -o -name \*.o -o -name \*.log -o -name \*.so -o -name a.out \) -delete

  rm "$pkgdir/usr/share/sbcl-source/src/runtime/sbcl"
}

fixes.lisp

(in-package "COMMON-LISP-USER")

(let* ((parent (make-pathname :directory '(:absolute "usr" "share" "sbcl-source")))
       (src
    (merge-pathnames
     (make-pathname :directory '(:relative "src" :wild-inferiors)
            :name :wild :type :wild)
     parent))
         (contrib
          (merge-pathnames
           (make-pathname :directory '(:relative "contrib" :wild-inferiors)
                          :name :wild :type :wild)
           parent)))
  (setf (logical-pathname-translations "SYS")
    `(("SYS:SRC;**;*.*.*" ,src)
      ("SYS:CONTRIB;**;*.*.*" ,contrib))))

(ignore-errors
  (sb-ext:gc :full t)
  (sb-ext:enable-debugger)
  (sb-ext:save-lisp-and-die "sbcl-new.core"))
Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!

41

Re: [Collection] Compilation of packages and ports (not in repositories)

Package abbayedesmorts

PKGBUILD

# Maintainer: Tobias Dausend <throgh@hyperbola.info>

pkgname=abbayedesmorts
pkgver=2.0.4
pkgrel=1
pkgdesc="l'Abbaye des Morts - An obsolete, free and libre video game for a dark passage of history"
arch=('i686' 'x86_64')
url='https://github.com/nevat/abbayedesmorts-gpl'
license=('GPL-3' 'CC-BY-3.0')
depends=('sdl2' 'sdl2_image' 'sdl2_mixer')
groups=('games')
source=("${pkgname}-${pkgver}.tar.gz::https://github.com/nevat/abbayedesmorts-gpl/archive/refs/tags/v${pkgver}.tar.gz"
        "fhs-compliant.patch")
sha512sums=('46e2384c2f176dd54c3056d2e8a7ea1ea40da918bc1598414c68a2449f198e49c3dba30dc8c3c771f8d37e7a6eaa38caccbc2275d1712b7a8e5332ca400c5562'
            '0e57c75c0887f0016c1508d980099c55ab6ae1ef2fdb9a7e1359a6f4e1fd958ec6a116d77de4dcf8436f65c66bb4dec5813488691d41880c704aa584cb97f3e6')

prepare() {
  mv "${pkgname}-gpl-${pkgver}" "${pkgname}-${pkgver}"
  cd "${pkgname}-${pkgver}"
  patch -Np1 -i "$srcdir/fhs-compliant.patch"
}

build() {
  cd "${pkgname}-${pkgver}"
  make
}

package() {
  cd "${pkgname}-${pkgver}"
  mkdir -p "$pkgdir/usr/games"
  mkdir -p "$pkgdir/usr/share"
  mkdir -p "$pkgdir/usr/share/applications"
  mkdir -p "$pkgdir/usr/share/pixmaps"
  make DESTDIR="$pkgdir" install

  # license
  install -Dm644 {COPYING,ReadMe.md} -t "$pkgdir/usr/share/licenses/$pkgname"
}

fhs-compliant.patch

--- a/Makefile    2024-09-23 23:18:05.000000000 +0200
+++ b/Makefile    2024-12-15 02:36:43.892348396 +0100
@@ -23,7 +23,7 @@
 DATADIR= "\"./\""
 endif
 
-DATADIR?="\"$(PREFIX)/share/abbayev2\""
+DATADIR?="\"$(PREFIX)/share/games/abbayev2\""
 LDFLAGS?=    -Wl,-z,relro
 
 CFLAGS+=    `sdl2-config --cflags` -DDATADIR=$(DATADIR)
@@ -61,28 +61,28 @@
 
 # Installation
 install: $(PROG)
-    mkdir -p $(DESTDIR)$(PREFIX)/bin
-    cp $(PROG) $(DESTDIR)$(PREFIX)/bin
+    mkdir -p $(DESTDIR)$(PREFIX)/games
+    cp $(PROG) $(DESTDIR)$(PREFIX)/games
     mkdir -p $(DESTDIR)$(PREFIX)/share/applications
     cp abbaye.desktop $(DESTDIR)$(PREFIX)/share/applications
-    mkdir -p $(DESTDIR)$(PREFIX)/share/abbayev2/sounds
-    cp ./sounds/* $(DESTDIR)$(PREFIX)/share/abbayev2/sounds
-    mkdir -p $(DESTDIR)$(PREFIX)/share/abbayev2/data
-    cp ./data/* $(DESTDIR)$(PREFIX)/share/abbayev2/data
+    mkdir -p $(DESTDIR)$(PREFIX)/share/games/abbayev2/sounds
+    cp ./sounds/* $(DESTDIR)$(PREFIX)/share/games/abbayev2/sounds
+    mkdir -p $(DESTDIR)$(PREFIX)/share/games/abbayev2/data
+    cp ./data/* $(DESTDIR)$(PREFIX)/share/games/abbayev2/data
     mkdir -p $(DESTDIR)$(PREFIX)/share/pixmaps
     cp abbaye.png $(DESTDIR)$(PREFIX)/share/pixmaps
-    mkdir -p $(DESTDIR)$(PREFIX)/share/abbayev2/graphics
-    cp -r ./graphics/* $(DESTDIR)$(PREFIX)/share/abbayev2/graphics
+    mkdir -p $(DESTDIR)$(PREFIX)/share/games/abbayev2/graphics
+    cp -r ./graphics/* $(DESTDIR)$(PREFIX)/share/games/abbayev2/graphics
     mkdir -p $(DESTDIR)$(PREFIX)/share/appdata
     cp ./appdata/abbaye.appdata.xml $(DESTDIR)$(PREFIX)/share/appdata
 
 uninstall:
-    rm $(DESTDIR)$(PREFIX)/bin/$(PROG)
+    rm $(DESTDIR)$(PREFIX)/games/$(PROG)
     rm $(DESTDIR)$(PREFIX)/share/applications/abbaye.desktop
     rm $(DESTDIR)$(PREFIX)/share/pixmaps/abbaye.png
-    rm -rf $(DESTDIR)$(PREFIX)/share/abbayev2
+    rm -rf $(DESTDIR)$(PREFIX)/share/games/abbayev2
     rm $(DESTDIR)$(PREFIX)/share/appdata/abbaye.appdata.xml
     # ignore if not empty
-    -rmdir $(DESTDIR)$(PREFIX)/bin
+    -rmdir $(DESTDIR)$(PREFIX)/games
     -rmdir $(DESTDIR)$(PREFIX)/share/applications
     -rmdir $(DESTDIR)$(PREFIX)/share/pixmaps
Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!

42

Re: [Collection] Compilation of packages and ports (not in repositories)

Package sar (Search and Rescue)

PKGBUILD

# Maintainer: Tobias Dausend <throgh@hyperbola.info>

pkgname=sar
_pkgbase=SearchAndRescue
_pkgname=searchandrescue
pkgver=1.5.0
_debver=$pkgver
_debrel=2.1
pkgdataver=1.3.0
pkgrel=1
pkgdesc="Fly aircraft to search (for) and rescue people in distress"
url='http://sourceforge.net/projects/searchandrescue/'
license=('GPL-2')
arch=('i686' 'x86_64')
depends=('glibc' 'glu' 'sdl' 'sdl_mixer' 'libx11' 'libxpm' 'libxxf86vm' 'libxext' 'libxmu')
makedepends=('clang')
groups=('games')
source=("https://deb.debian.org/debian/pool/main/s/searchandrescue/searchandrescue_${pkgver}.orig.tar.gz"
        "https://deb.debian.org/debian/pool/main/s/searchandrescue/searchandrescue_${_debver}-${_debrel}.diff.gz"
        "https://deb.debian.org/debian/pool/main/s/searchandrescue-data/searchandrescue-data_${pkgdataver}.orig.tar.gz")
sha512sums=('72a8e5c375bb2f5d11d1346bb3c81ea4678a9c58c36f53c048e9a16d32a926ff93c3ec9756867f0869aa2a8da5fb0bfe7764f704c4e79519ee0834d225513657'
            '7e3d76e54684f0a8f761dbbbc426a3bf68802d9a546864ef8c306b542b757976e9e73d0a9da70fba6c55a6c83d90c89b801815bd251f0462c7a463de061752cb'
            '5419376aeecb0f05570a8d2a0a6f830f3b22ce9d1d34a5e490485767546c6d0d1d2a2a3f37e5dfcef69e271a94a9c7dfc6b592e3c0dd62a8a6c38e4bf7d25ccd')
noextract=("searchandrescue-data_${pkgdataver}.orig.tar.gz")

prepare() {
  cd ${_pkgname}_${pkgver}
  patch -Np1 < ${srcdir}/${_pkgname}_${_debver}-${_debrel}.diff
}

build() {
  cd ${_pkgname}_${pkgver}
  make
}

package() {
  cd ${_pkgname}_${pkgver}
  make DESTDIR="$pkgdir/" install

  # install data-files
  install -d "${pkgdir}/usr/share/games/$_pkgname"
  tar -xzf "${srcdir}/searchandrescue-data_${pkgdataver}.orig.tar.gz" \
      -C   "${pkgdir}/usr/share/games/$_pkgname/"

  # install metadata-files
  install -Dm644 debian/$_pkgbase.desktop "${pkgdir}/usr/share/applications/"$_pkgbase.desktop

  # install license
  install -Dm644 LICENSE -t "${pkgdir}/usr/share/licenses/$pkgname/"
}
Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!

43

Re: [Collection] Compilation of packages and ports (not in repositories)

Package sar2 (Search and Rescue 2)

PKGBUILD

# Maintainer (Arch): Popolon <popolon@popolon.org>
# Maintainer: Tobias Dausend <throgh@hyperbola.info>

_name=SearchAndRescue2
pkgname=sar2
pkgver=2.5.0
pkgrel=2
pkgdesc="Free and libre helicopter simulator"
url='https://searchandrescue2.github.io/sar2/'
license=('GPL-2')
arch=('i686' 'x86_64')
depends=('freealut' 'openal' 'libvorbis' 'sdl2' 'libsm' 'libxmu' 'libxpm' 'glu')
makedepends=('scons' 'python-setuptools')
groups=('games')
source=("https://github.com/$_name/$pkgname/archive/v$pkgver.tar.gz"
        "fhs-compliant.patch")
sha512sums=('b5e6036e9ca0bce4245b951cdc16e676470f95906c714b28facf0006c4db838d86dbb57982712fa5f6abb9bd774c61b9d1c593c82b08325e9f28db25273a194a'
            '754ced777865fbd2eb4102eb79eeb8ebb6ffad3e4a0ff81c9cdf29a089d33adf779c146aaa8b25c914e6034fc52545f7d760e7e51a385b142a54f1893d2373b6')

prepare() {
  cd "$pkgname-$pkgver"
  patch -Np1 -i ${srcdir}/fhs-compliant.patch
}

build() {
  cd "$pkgname-$pkgver"
  scons
}

package() {
  cd "$pkgname-$pkgver"
  scons install --prefix=${pkgdir}/usr
  install -Dm644 extra/$pkgname.desktop "${pkgdir}/usr/share/applications/$pkgname.desktop"
  install -Dm644 LICENSE -t "${pkgdir}/usr/share/licenses/$pkgname"
}

fhs-compliant.patch

--- a/src/SConscript    2020-06-20 23:48:35.000000000 +0200
+++ b/src/SConscript    2021-10-24 17:56:07.030471759 +0200
@@ -177,11 +177,11 @@
 """)
 
 object_list = env.Object(source = sources)
-sar2 = env.Program(target='#bin/sar2', source=[object_list])
+sar2 = env.Program(target='#games/sar2', source=[object_list])
 data='#data'
 man='#man/sar2.6.bz2'
 pixmap='#extra/sar2.xpm'
-env.Alias("install", env.InstallAs('$DESTDIR/$PREFIX/share/sar2', data))
+env.Alias("install", env.InstallAs('$DESTDIR/$PREFIX/share/games/sar2', data))
 env.Alias("install", env.Install('$DESTDIR/$PREFIX/share/man/man6', man))
 env.Alias("install", env.Install('$DESTDIR/$PREFIX/share/pixmaps', pixmap))
-env.Alias("install", env.Install('$DESTDIR/$PREFIX/bin', sar2))
+env.Alias("install", env.Install('$DESTDIR/$PREFIX/games', sar2))
--- a/src/config.h    2020-06-20 23:48:35.000000000 +0200
+++ b/src/config.h    2021-10-24 18:06:58.489853438 +0200
@@ -502,7 +502,7 @@
 #define SAR_DEF_LOCAL_DATA_DIR  ".config/sar2"
 
 /* Game data dir */
-#define SAR_DEF_GLOBAL_DATA_DIR "/usr/share/sar2"
+#define SAR_DEF_GLOBAL_DATA_DIR "/usr/share/games/sar2"
 
 /* Subdirs, one of each in the local and global game dirs */
 #define SAR_DEF_AIRCRAFTS_DIR        "aircrafts"
Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!

44

Re: [Collection] Compilation of packages and ports (not in repositories)

Package enlightenment16

PKGBUILD

# Maintainer (Arch): Brian BIdulock <bidulock@openss7.org>
# Contributor (Arch): Eric Bélanger <eric@archlinux.org>
# Maintainer: André Silva <emulatorman@hyperbola.info>
# Contributor: Tobias Dausend <throgh@hyperbola.info>

pkgname=enlightenment16
pkgver=1.0.29
_themever=1.0.3
pkgrel=1
pkgdesc="A fast, flexible, and very extensible Window Manager"
arch=('i686' 'x86_64')
url='https://www.enlightenment.org/e16'
license=('Expat')
depends=('libxinerama' 'imlib2' 'perl' 'pango' 'libxcomposite' 'sndio' 'libxrandr' 'libxdamage' 'libsndfile')
makedepends=('libsndio')
source=("https://downloads.sourceforge.net/sourceforge/enlightenment/e16-${pkgver}.tar.gz"
        "https://downloads.sourceforge.net/enlightenment/e16-themes-${_themever}.tar.gz"
        "starte16")
sha512sums=('e95dc2ad05b4f2ec3f374c5268f8f790e9ddd212f4e5e60d3517ade8645e539de5207553a841e14d1c099496f8385271f3f95867ef8ebfd99c419201477ef299'
            '6c8d7d15233f401c9b6c406116d822c42b7eed9b81570f2f25824886eee0a8c51895dfeeffa5c6e820f5e9449d9d28ec55e029f1136b5cb55cd7072fe9f57cba'
            '99f382ddcb0951f38e3bff686cf4e2940e408729490719108e671c4bae7aae3708f8c6222b392ebf31bef21b788f8de7bdd894402b3e060dc0c9f716f78b0c22')

build() {
  pushd e16-${pkgver}
  ./configure \
    --prefix=/usr \
    --sysconfdir=/etc \
    --enable-sound=sndio \
    --enable-dbus=no \
    --with-gnome=no
  make
  popd
  
  cd e16-themes-${_themever}
  ./configure --prefix=/usr
}

package() {
  cd e16-${pkgver}
  make DESTDIR="${pkgdir}" install
  install -D -m644 COPYING -t "${pkgdir}/usr/share/licenses/${pkgname}"
  install -D -m644 fonts/COPYRIGHT.Vera -t "${pkgdir}/usr/share/licenses/${pkgname}"

  cd "${srcdir}/e16-themes-${_themever}"
  make DESTDIR="${pkgdir}" install
  chown -R root:root "${pkgdir}"/usr/share/*

  # removing unsupported
  rm "${pkgdir}"/usr/share/e16/misc/e16-dbus-cmd
  rm "${pkgdir}"/usr/share/e16/misc/starte16-gnome
  rm "${pkgdir}"/usr/share/e16/misc/starte16-kde
  rm "${pkgdir}"/usr/share/e16/misc/Xclients.e16-gnome.sh
  rm "${pkgdir}"/usr/share/e16/misc/Xclients.e16-kde.sh
  rm "${pkgdir}"/usr/share/xsessions/e16-kde-session.desktop

  # attach script
  rm "${pkgdir}"/usr/share/e16/misc/starte16
  cp "${srcdir}"/starte16  "${pkgdir}"/usr/share/e16/misc/
}

starte16

#!/bin/sh

s=$1
test -z "$s" && s=$0

case "$s" in
*window)
    exec /usr/bin/e16 -w ${SIZE:-800x600}
    ;;
*)
    exec /usr/bin/e16
    ;;
esac
Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!

45

Re: [Collection] Compilation of packages and ports (not in repositories)

Package pekwm

PKGBUILD

# Maintainer (Arch): Alexander F. Rødseth <xyproto@archlinux.org>
# Contributor (Arch): Kevin Piche <kevin@archlinux.org>
# Contributor (Arch): Eddie Lozon <almostlucky@attbi.com>
# Maintainer: Tobias Dausend <throgh@hyperbola.info>

pkgname=pekwm
pkgver=0.1.18
_debver=$pkgver
_debrel=1
pkgrel=1
pkgdesc="Tabbed X11 window manager"
arch=('i686' 'x86_64')
license=('GPL-2')
url='https://github.com/pekdon/pekwm'
depends=('libjpeg-turbo' 'libxft' 'libxinerama' 'libxpm' 'libxrandr')
makedepends=('quilt')
optdepends=('lxappearance: feature-rich GTK+ theme switcher'
            'nitrogen: background browser and setter'
            'tint2: basic, good-looking task manager')
backup=('etc/pekwm/autoproperties'
        'etc/pekwm/autoproperties_typerules'
        'etc/pekwm/config'
        'etc/pekwm/config_system'
        'etc/pekwm/keys'
        'etc/pekwm/menu'
        'etc/pekwm/mouse'
        'etc/pekwm/mouse_click'
        'etc/pekwm/mouse_sloppy'
        'etc/pekwm/mouse_system'
        'etc/pekwm/start'
        'etc/pekwm/vars')
source=("https://github.com/${pkgname}/${pkgname}/releases/download/release-${pkgver}/${pkgname}-${pkgver}.tar.gz"
        "https://deb.debian.org/debian/pool/main/p/pekwm/pekwm_${_debver}-${_debrel}.debian.tar.xz")
sha512sums=('7fe04c04089d3375d1f64d456a7a582e88fd1f442c1c710bdef71309c7fe5aab234026ba381eb9a49b3d459b759924b577ba9597156e46e60147a9d845c27e89'
            '7f8d285b2725ee24b5fcefc1bacbb9b9738f58c19b49bafe40645e72f71f9ca1498a55185184f22906cbdfa404c626b8e7abc33406549af0b85ba8d36f78c615')

prepare() {
  cd $pkgname-$pkgver
  if [[ ${pkgver%.*} = ${_debver%.*} ]]; then
    # Debian patches
    export QUILT_PATCHES=debian/patches
    export QUILT_REFRESH_ARGS='-p ab --no-timestamps --no-index'
    export QUILT_DIFF_ARGS='--no-timestamps'

    mv "$srcdir"/debian .

    quilt push -av
  fi
  ./autogen.sh
}

build() {
  cd $pkgname-$pkgver
  ./configure \
    --prefix=/usr \
    --sysconfdir=/etc
  make
}

package() {
  make -C $pkgname-$pkgver DESTDIR="$pkgdir" install
  install -Dm644 "$srcdir"/$pkgname-$pkgver/debian/$pkgname.desktop "$pkgdir"/usr/share/xsessions/$pkgname.desktop
  install -Dm644 "$srcdir"/$pkgname-$pkgver/LICENSE -t "${pkgdir}/usr/share/licenses/$pkgname"
}
Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!

46

Re: [Collection] Compilation of packages and ports (not in repositories)

Package pekwm-themes

PKGBUILD

# Maintainer (Arch): Alexander F Rødseth <xyproto@archlinux.org>
# Maintainer: Tobias Dausend <throgh@hyperbola.info>

pkgname=pekwm-themes
pkgver=1.0.5
_debver=$pkgver
_debrel=7
pkgrel=1
pkgdesc="PekWM theme collection"
arch=('any')
license=('GPL-2' 'GPL-3')
depends=('pekwm')
source=("${pkgname}-${pkgver}.tar.gz::https://deb.debian.org/debian/pool/main/p/pekwm-themes/pekwm-themes_${pkgver}.orig.tar.gz"
        "https://deb.debian.org/debian/pool/main/p/pekwm-themes/pekwm-themes_${_debver}-${_debrel}.debian.tar.xz")
sha512sums=('94ef6e1cb564fcc28601729e1a6e95c6f858ab7a31ea9bf3ad8478398931229ee0087ec3724c4df263b45191064503dae91bee7e8abeeeca10ca783601ad2fe3'
            '310df602fa223650cde9a7cbf6f8f46619d5ae4ef9ae241552ac629c9a619eb3b17b80e2109a6baf4c4638a65c7aa8e8916c5523e439f91f8d39aea1cbef0555')

package() {
  install -d "$pkgdir/usr/share/pekwm/themes"
  cp -R "$srcdir/$pkgname/"* "$pkgdir/usr/share/pekwm/themes/"
  install -Dm644 "$srcdir/debian/copyright" -t "$pkgdir/usr/share/licenses/$pkgname"
}
Human being in favor with clear principles and so also for freedom in soft- and hardware!

Certainly anyone who has the power to make you believe absurdities has the power to make you commit injustices: For a life of every being full with peace and kindness, including diversity and freedom. Capitalism is destroying our minds, the planet itself and the universe in the end!