Files
BMLFS/build-scripts/gtk3.build
dslm4515 c37e3157e5 Upgraded GTK3 from 3.24.42 to 3.24.50
GTK+3 is now GTK3; Updated source URL
2025-08-29 16:51:59 -05:00

79 lines
2.7 KiB
Bash

#! /bin/bash
# GTK+ 3
# Source: https://download.gnome.org/sources/gtk/3.24/gtk-3.24.50.tar.xz
#
# $BUILD = Directory to temporarily install
# $PKGS = Directory to store built packages
#
# DEPS
# Required: at-spi2-core, FriBidi, gdk-pixbuf, libepoxy, and Pango
# Recommended: adwaita-icon-theme, hicolor-icon-theme, ISO Codes, libxkbcommon,
# Recommended: sassc, wayland, wayland-protocols, gobject-introspection
# Optional: Colord, CUPS, DocBook Utils, GTK-Doc, JSON-Glib, PyAtSpi, rest, PAPI
# if optimizing, use GCC:
export CFLAGS="-march=native -pipe "
export CFLAGS+="-O3 -Ofast -falign-functions=32 -ffat-lto-objects -flto=4 "
export CFLAGS+="-fno-semantic-interposition -mprefer-vector-width=256 "
export LDFLAGS="-flto=4 -Wl,-O2 -Wl,--as-needed "
export PVER="3.24.50"
# Autotools no longer used.
# Use meson:
# * If Xorg not installed, set x11_backend to false
meson setup --prefix=/usr \
-Dman=true \
-Dgtk_doc=false \
-Dbroadway_backend=true \
-Dx11_backend=true 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/share
sudo -S mv $BUILD/usr/share/man /BMAN/usr/share/
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------------------------------------------------------|
gtk3: GTK+ version 3 (multi-platform GUI toolkit)
gtk3:
gtk3: This is GTK+, a multi-platform toolkit for creating graphical user
gtk3: interfaces. Offering a complete set of widgets, GTK+ is suitable for
gtk3: projects ranging from small one-off projects to complete application
gtk3: suites.
gtk3:
gtk3:
gtk3:
gtk3:
gtk3:
EOF
sudo -S mv -v /tmp/slack-desc install/ &&
sudo -S makepkg -l y -c n $PKGS/gtk3-$PVER-$PSUFFIX &&
cd /BMAN
cat > /tmp/slack-desc << "EOF"
gtk3-doc: Manuals for GTK+ version 3 (multi-platform GUI toolkit)
gtk3-doc:
gtk3-doc: This is GTK+, a multi-platform toolkit for creating graphical user
gtk3-doc: interfaces. Offering a complete set of widgets, GTK+ is suitable for
gtk3-doc: projects ranging from small one-off projects to complete application
gtk3-doc: suites.
gtk3-doc:
EOF
sudo -S mv -v /tmp/slack-desc install/ &&
sudo -S makepkg -l y -c n $PKGS/gtk+3-$PVER--$NOPSUFFIX
sudo -S rm -rf /BMAN/*
sudo -S rm -rf ${BUILD}/*