commit:     3dd84b3207eb639db6408e37207740a0d19b12b8
Author:     Alfred Wingate <parona <AT> protonmail <DOT> com>
AuthorDate: Wed Oct 29 17:36:43 2025 +0000
Commit:     Bernard Cafarelli <voyageur <AT> gentoo <DOT> org>
CommitDate: Tue Nov 11 19:24:02 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3dd84b32

x11-wm/windowmaker: fixup

* Add subslot.
* Missing deps + automagic
* Address ingored cflags
* Simplify ebuild

Bug: https://bugs.gentoo.org/641740
Bug: https://bugs.gentoo.org/636922
Signed-off-by: Alfred Wingate <parona <AT> protonmail.com>
Part-of: https://github.com/gentoo/gentoo/pull/44437
Signed-off-by: Bernard Cafarelli <voyageur <AT> gentoo.org>

 x11-wm/windowmaker/windowmaker-0.96.0-r1.ebuild | 149 ++++++++++++++++++++++++
 1 file changed, 149 insertions(+)

diff --git a/x11-wm/windowmaker/windowmaker-0.96.0-r1.ebuild 
b/x11-wm/windowmaker/windowmaker-0.96.0-r1.ebuild
new file mode 100644
index 000000000000..7f3c12aaa29a
--- /dev/null
+++ b/x11-wm/windowmaker/windowmaker-0.96.0-r1.ebuild
@@ -0,0 +1,149 @@
+# Copyright 1999-2025 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit autotools desktop
+
+MY_P="WindowMaker-${PV}"
+
+DESCRIPTION="The fast and light GNUstep window manager"
+HOMEPAGE="https://www.windowmaker.org/";
+SRC_URI="
+       
https://github.com/window-maker/wmaker/releases/download/wmaker-${PV}/${MY_P}.tar.gz
+       
https://www.windowmaker.org/pub/source/release/WindowMaker-extra-0.1.tar.gz
+"
+S="${WORKDIR}/${MY_P}"
+
+# WRASTER_CURRENT-WRASTER_AGE.WINGS_CURRENT-WINGS_AGE.WUTIL_CURRENT-WUTIL_AGE 
from configure.ac
+LICENSE="GPL-2"
+SLOT="0/6.3.5"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~mips ~ppc ~ppc64 ~riscv ~sparc ~x86 
~amd64-linux ~x86-linux ~ppc-macos ~x64-solaris"
+
+IUSE="gif imagemagick jpeg modelock nls png tiff webp xinerama +xpm xrandr"
+
+DEPEND="
+       media-libs/fontconfig
+       media-libs/libexif
+       x11-libs/libX11
+       x11-libs/libXext
+       x11-libs/libXres
+       >=x11-libs/libXft-2.1.0
+       x11-libs/libXmu
+       x11-libs/libXpm
+       x11-libs/libXt
+       x11-libs/libXv
+       x11-libs/pango
+       gif? ( >=media-libs/giflib-4.1.0-r3:= )
+       imagemagick? ( >=media-gfx/imagemagick-7:0= )
+       jpeg? ( media-libs/libjpeg-turbo:= )
+       nls? ( virtual/libintl )
+       png? ( media-libs/libpng:= )
+       tiff? ( media-libs/tiff:= )
+       webp? ( media-libs/libwebp:= )
+       xinerama? ( x11-libs/libXinerama )
+       xrandr? ( x11-libs/libXrandr )
+"
+RDEPEND="${DEPEND}"
+BDEPEND="nls? ( >=sys-devel/gettext-0.10.39 )"
+
+DOCS=( AUTHORS BUGFORM BUGS ChangeLog INSTALL-WMAKER FAQ
+       NEWS README README.definable-cursor README.i18n TODO )
+
+src_prepare() {
+       # Fix some paths
+       for file in WindowMaker/*menu* util/wmgenmenu.c; do
+               if [[ -r $file ]] ; then
+                       sed -i -e 
"s|/usr/local/GNUstep/Applications/WPrefs.app|${EPREFIX}/usr/bin/|g;" "$file" 
|| die
+                       sed -i -e 
"s|/usr/local/share/WindowMaker|${EPREFIX}/usr/share/WindowMaker|g;" "$file" || 
die
+                       sed -i -e 
"s|/opt/share/WindowMaker|${EPREFIX}/usr/share/WindowMaker|g;" "$file" || die
+               fi
+       done
+
+       # Not relevant downstram
+       sed -e '/check-local/d' -i Makefile.am || die
+
+       default
+
+       # Fix issues with ignored cflags and mystery linkage to glib, freetype 
and harfbuzz
+       eautoreconf
+}
+
+src_configure() {
+       # sanity check subslot to kick would be drive by bumpers
+       local detected_abi
+       for lib in WRASTER WINGS WUTIL; do
+               # On Linux libtool will decide soname as CURRENT-AGE rather 
than just CURRENT
+               local current="$(sed -n -e "s/${lib}_CURRENT=\([0-9]*\)/\1/p" 
configure.ac)"
+               local age="$(sed -n -e "s/${lib}_AGE=\([0-9]*\)/\1/p" 
configure.ac)"
+               detected_abi+="$((current-age))."
+       done
+       detected_abi="${detected_abi%.}"
+       if [[ "${SLOT}" != "0/${detected_abi}" ]]; then
+               die "SLOT ${SLOT} doesn't match upstream specified ABI 
${detected_abi}."
+       fi
+
+       local -a myeconfargs=(
+               --localedir="${EPREFIX}"/usr/share/locale
+               --sysconfdir="${EPREFIX}"/etc/X11
+               --disable-static
+               --enable-usermenu
+               --with-incs-from=
+               --with-libs-from=
+               --with-pixmapdir="${EPREFIX}"/usr/share/pixmaps
+               --with-x
+
+               # image format types
+               $(use_enable gif)
+               $(use_enable imagemagick magick)
+               $(use_enable jpeg)
+               $(use_enable png)
+               $(use_enable tiff)
+               $(use_enable webp)
+               $(use_enable xpm)
+
+               # optional X capabilities
+               $(use_enable modelock)
+               $(use_enable xinerama)
+               $(use_enable xrandr randr)
+       )
+
+       # NLS depends on whether LINGUAS is empty
+       if use nls; then
+               myeconfargs+=( LINGUAS="${LINGUAS:-$(cd po; x=(*.po); echo 
${x[*]%.po})}" )
+       else
+               myeconfargs+=( LINGUAS= )
+       fi
+
+       econf "${myeconfargs[@]}"
+
+       pushd ../WindowMaker-extra-0.1 &>/dev/null || die
+       econf
+}
+
+src_compile() {
+       emake
+
+       # WindowMaker Extra Package (themes and icons)
+       emake -C ../WindowMaker-extra-0.1
+}
+
+src_install() {
+       default
+
+       # WindowMaker Extra
+       emake -C ../WindowMaker-extra-0.1 DESTDIR="${D}" install
+       newdoc ../WindowMaker-extra-0.1/README README.extra
+
+       # create wmaker session shell script
+       echo "#!/usr/bin/env bash" > wmaker
+       echo "${EPREFIX}/usr/bin/wmaker" >> wmaker
+       exeinto /etc/X11/Sessions/
+       doexe wmaker
+
+       insinto /usr/share/xsessions
+       doins "${FILESDIR}"/wmaker.desktop
+       make_desktop_entry /usr/bin/wmaker
+
+       find "${ED}" -type f -name '*.la' -delete || die
+}

Reply via email to