mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-22 19:50:05 +02:00
libglvnd: Fixes and refinements to 1.6.0 based on upstream
This commit is contained in:
@@ -1,12 +1,13 @@
|
||||
SUMMARY="GL Vendor-Neutral Dispatch Library"
|
||||
DESCRIPTION="libglvnd translates Haiku's OpenGL kit to a modern EGL-based graphics rendering \
|
||||
pipeline."
|
||||
HOMEPAGE="http://github.com/NVIDIA/libglvnd"
|
||||
HOMEPAGE="http://gitlab.freedesktop.org/glvnd/libglvnd"
|
||||
COPYRIGHT="2013, NVIDIA CORPORATION"
|
||||
LICENSE="MIT"
|
||||
REVISION="1"
|
||||
SOURCE_URI="https://github.com/NVIDIA/libglvnd/archive/refs/tags/v$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="e31dd71441604cf7467397e740af8070caa84133b5ed71241d3d5ca84c950baf"
|
||||
REVISION="4"
|
||||
SOURCE_URI="https://gitlab.freedesktop.org/glvnd/libglvnd/-/archive/v$portVersion/libglvnd-v$portVersion.tar.gz"
|
||||
SOURCE_DIR="libglvnd-v$portVersion"
|
||||
CHECKSUM_SHA256="efc756ffd24b24059e1c53677a9d57b4b237b00a01c54a6f1611e1e51661d70c"
|
||||
PATCHES="libglvnd-$portVersion.patchset"
|
||||
|
||||
ARCHITECTURES="?all"
|
||||
@@ -15,7 +16,7 @@ SECONDARY_ARCHITECTURES="?x86_gcc2 ?x86"
|
||||
PROVIDES="
|
||||
libglvnd$secondaryArchSuffix = $portVersion
|
||||
lib:libGL$secondaryArchSuffix
|
||||
lib:libegl$secondaryArchSuffix
|
||||
lib:libEGL$secondaryArchSuffix
|
||||
lib:libglesv1_cm$secondaryArchSuffix
|
||||
lib:libglesv2$secondaryArchSuffix
|
||||
lib:libgldispatch$secondaryArchSuffix
|
||||
@@ -23,12 +24,16 @@ PROVIDES="
|
||||
"
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
lib:libEGL${secondaryArchSuffix}
|
||||
"
|
||||
|
||||
PROVIDES_devel="
|
||||
libglvnd${secondaryArchSuffix}_devel = $portVersion
|
||||
devel:libGL$secondaryArchSuffix
|
||||
devel:libEGL$secondaryArchSuffix
|
||||
devel:libglesv1_cm$secondaryArchSuffix
|
||||
devel:libglesv2$secondaryArchSuffix
|
||||
devel:libgldispatch$secondaryArchSuffix
|
||||
devel:libopengl$secondaryArchSuffix
|
||||
"
|
||||
REQUIRES_devel="
|
||||
libglvnd$secondaryArchSuffix == $portVersion base
|
||||
@@ -36,7 +41,6 @@ REQUIRES_devel="
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
devel:libEGL$secondaryArchSuffix
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:awk
|
||||
@@ -45,15 +49,16 @@ BUILD_PREREQUIRES="
|
||||
cmd:meson
|
||||
cmd:ninja
|
||||
cmd:sed
|
||||
cmd:python3
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
meson --buildtype=release \
|
||||
--prefix=$prefix --libdir=$libDir --datadir=$dataDir --bindir=$binDir\
|
||||
--includedir=$includeDir --sysconfdir=$settingsDir --sbindir=$binDir \
|
||||
--includedir=$includeDir/os/opengl --sysconfdir=$settingsDir --sbindir=$binDir \
|
||||
--libexecdir=$libDir --localedir=$dataDir/locale \
|
||||
-Dhgl=true ./build
|
||||
./build
|
||||
ninja -C build
|
||||
}
|
||||
|
||||
@@ -61,10 +66,34 @@ INSTALL()
|
||||
{
|
||||
ninja -C build install
|
||||
|
||||
prepareInstalledDevelLibs libGL
|
||||
# Fix a few misc header installation location
|
||||
mv $includeDir/os/opengl/OpenGLKit.h $includeDir/os/OpenGLKit.h
|
||||
mv $includeDir/os/opengl/opengl/GLView.h $includeDir/os/opengl/GLView.h
|
||||
rm -rf $includeDir/os/opengl/opengl
|
||||
|
||||
prepareInstalledDevelLibs libGL libEGL libOpenGL libGLESv1_CM libGLESv2 libGLdispatch
|
||||
fixPkgconfig
|
||||
|
||||
# Fix OpenGL kit location
|
||||
sed -i 's/develop\/headers$/develop\/headers\/os\/opengl/' $installDestDir$developLibDir/pkgconfig/opengl.pc
|
||||
sed -i 's/develop\/headers$/develop\/headers\/os\/opengl/' $installDestDir$developLibDir/pkgconfig/egl.pc
|
||||
sed -i 's/develop\/headers$/develop\/headers\/os\/opengl/' $installDestDir$developLibDir/pkgconfig/gl.pc
|
||||
sed -i 's/develop\/headers$/develop\/headers\/os\/opengl/' $installDestDir$developLibDir/pkgconfig/glesv1_cm.pc
|
||||
sed -i 's/develop\/headers$/develop\/headers\/os\/opengl/' $installDestDir$developLibDir/pkgconfig/glesv2.pc
|
||||
sed -i 's/develop\/headers$/develop\/headers\/os\/opengl/' $installDestDir$developLibDir/pkgconfig/libglvnd.pc
|
||||
|
||||
# Toss ports a few bones
|
||||
# XXX: Is this a good idea? it's more standard, but anything not using pkgconfig should be punished?
|
||||
#for i in KHR GLES GLES2 GLES3 EGL GL; do
|
||||
# ln -s $includeDir/os/opengl/$i $includeDir/$i
|
||||
#done
|
||||
|
||||
# devel package
|
||||
packageEntries devel \
|
||||
$developDir
|
||||
}
|
||||
|
||||
TEST()
|
||||
{
|
||||
ninja -C build test
|
||||
}
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user