#!/bin/sh # Build script for xf86-video-illumosfb (autotools, Template A variant). # # Phase 2 Task 3 (M2). This port ships NO pre-generated `configure` - only # configure.ac/Makefile.am + its own autogen.sh (confirmed via `tar tf` on the # git-commit-archive tarball). Must run `NOCONFIGURE=1 ./autogen.sh` (which is # just `autoreconf -v --install` under the hood) before the usual # libtool/config.sub fix + configure, same shape as base/x11vnc (Task 7a). # # configure.ac requires xorg-macros (XORG_MACROS_VERSION/XORG_DEFAULT_OPTIONS) # at aclocal time. base/util-macros installs xorg-macros.m4 under # $PREFIX/share/aclocal (/usr/local/share/aclocal), which is NOT on aclocal's # default search path (/usr/share/aclocal) - export ACLOCAL_PATH so the # autoreconf inside autogen.sh finds it. # # Module install dir: configure.ac defaults --with-xorg-module-dir to # "$libdir/xorg/modules", but this XLibre build (base/xlibre-xserver-xorg) # uses a versioned moduledir, $libdir/xorg/modules/xlibre-25 (see that port's # xorg-server.pc: moduledir=${exec_prefix}/lib/xorg/modules/xlibre-25). The # driver's own Makefile.am appends "/drivers" to @moduledir@, so pass # --with-xorg-module-dir="$PREFIX/lib/xorg/modules/xlibre-25" here to land # illumosfb_drv.so where Xorg's video_drivers_dir actually points. # # ABI: illumosfb_driver.c's XF86ModuleVersionInfo uses the SDK's # ABI_VIDEODRV_VERSION macro directly (no hardcoded ABI number) - building # against xorg-server.pc's SDK headers means the ABI always matches the # server it's paired with. No ABI patch expected/needed. set -e cd "$SRCDIR" export AUTOCONF=/usr/bin/autoconf export AUTOHEADER=/usr/bin/autoheader export ACLOCAL=/usr/bin/aclocal export AUTOM4TE=/usr/bin/autom4te export ACLOCAL_PATH="$PREFIX/share/aclocal:$ACLOCAL_PATH" export PKG_CONFIG_PATH="$PREFIX/lib/pkgconfig:$PREFIX/share/pkgconfig:$PKG_CONFIG_PATH" export CFLAGS="${CFLAGS} -I$PREFIX/include -D__EXTENSIONS__ -D_POSIX_PTHREAD_SEMANTICS" export LDFLAGS="${LDFLAGS} -L$PREFIX/lib -R$PREFIX/lib" NOCONFIGURE=1 ./autogen.sh # GOTCHA (same as x11vnc, Task 7a): autoreconf --install generates its OWN # fresh config.sub/config.guess which do NOT carry the hammerhead patch. # Re-copy the patched versions post-autoreconf, before configure runs. cp -f /usr/share/autoconf/build-aux/config.sub config.sub 2>/dev/null || true cp -f /usr/share/autoconf/build-aux/config.guess config.guess 2>/dev/null || true # MANDATORY libtool fix (Template A) - piggyback hammerhead onto the # kopensolaris arm in the generated configure's dynamic-linker case block. if [ -f configure ]; then sed -i -E 's/(kopensolaris\*-gnu)([^)]*\))/\1 | hammerhead*\2/' configure fi ./configure \ --prefix="$PREFIX" \ --build="$BUILD_TRIPLE" \ --host="$BUILD_TRIPLE" \ --sysconfdir="$SYSCONFDIR" \ --disable-static \ --with-xorg-module-dir="$PREFIX/lib/xorg/modules/xlibre-25" gmake -j${JOBS:-1} gmake install DESTDIR="$PKGDIR" # xf86-video-illumosfb - illumos native framebuffer video driver for XLibre/Xorg # https://github.com/LuminousMonkey/xf86-video-illumosfb # # Phase 2 Task 3 (M2): the DDX driver that makes the XLibre Xorg server # (base/xlibre-xserver-xorg, M1) render on Hammerhead's console framebuffer. # Opens /dev/fb0, validates VIS_GETIDENTIFIER == "illumos_fb", FBIOGATTR + # mmap + KDSETMODE(KD_GRAPHICS) — the exact path M0's fbtest proved works. # # Pinned at git commit 8ad57812ca2e99be6281f5142101811482026c55 (upstream tag # v0.5, matches the version oi-userland ships). No release tarball exists # upstream, so the source is a GitHub commit-archive tarball. [package] name = "xf86-video-illumosfb" version = "0.5" release = 1 description = "illumos native framebuffer video driver for the XLibre/Xorg X server" url = "https://github.com/LuminousMonkey/xf86-video-illumosfb" license = "MIT" maintainer = "Chris Tusa " arch = "x86_64" [dependencies] runtime = ["xlibre-xserver-xorg"] build = ["xlibre-xserver-xorg", "pixman", "util-macros"] [[source]] file = "xf86-video-illumosfb-8ad57812ca2e99be6281f5142101811482026c55.tar.gz" urls = ["https://github.com/LuminousMonkey/xf86-video-illumosfb/archive/8ad57812ca2e99be6281f5142101811482026c55.tar.gz"] checksum = "f601e824c7a08189656d77515d9df0c302b669e79f990684527b5e75865c3355" extract = true [build] parallel = true