mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-22 03:30:05 +02:00
libgnt: add recipe (#6026)
This commit is contained in:
79
dev-libs/libgnt/libgnt-2.14.1.recipe
Normal file
79
dev-libs/libgnt/libgnt-2.14.1.recipe
Normal file
@@ -0,0 +1,79 @@
|
||||
SUMMARY="Text-mode UI toolkit"
|
||||
DESCRIPTION="libgnt is a GLib-based ncurses toolkit for creating text-mode \
|
||||
graphical user interfaces quickly and easily."
|
||||
HOMEPAGE="https://pidgin.im/"
|
||||
COPYRIGHT="2006-2021 libgnt contributors"
|
||||
LICENSE="GNU GPL v2"
|
||||
REVISION=1
|
||||
SOURCE_URI="http://downloads.sourceforge.net/project/pidgin/libgnt/$portVersion/libgnt-$portVersion.tar.xz"
|
||||
CHECKSUM_SHA256="5ec3e68e18f956e9998d79088b299fa3bca689bcc95c86001bc5da17c1eb4bd8"
|
||||
PATCHES="libgnt-$portVersion.patchset"
|
||||
|
||||
ARCHITECTURES="!x86_gcc2 x86_64"
|
||||
SECONDARY_ARCHITECTURES="x86"
|
||||
|
||||
libVersion="0.14.1"
|
||||
libVersionCompat="$libVersion compat >= ${libVersion%%.*}"
|
||||
|
||||
PROVIDES="
|
||||
libgnt$secondaryArchSuffix = $portVersion
|
||||
lib:libgnt$secondaryArchSuffix = $libVersionCompat
|
||||
"
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
lib:libglib_2.0$secondaryArchSuffix
|
||||
lib:libgmodule_2.0$secondaryArchSuffix
|
||||
lib:libgobject_2.0$secondaryArchSuffix
|
||||
lib:libgthread_2.0$secondaryArchSuffix
|
||||
lib:libncursesw$secondaryArchSuffix
|
||||
lib:libpanelw$secondaryArchSuffix
|
||||
lib:libxml2$secondaryArchSuffix
|
||||
"
|
||||
PROVIDES_devel="
|
||||
libgnt${secondaryArchSuffix}_devel = $portVersion
|
||||
devel:libgnt$secondaryArchSuffix = $libVersionCompat
|
||||
"
|
||||
REQUIRES_devel="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
libgnt$secondaryArchSuffix == $portVersion base
|
||||
"
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
devel:libglib_2.0$secondaryArchSuffix
|
||||
devel:libgmodule_2.0$secondaryArchSuffix
|
||||
devel:libgobject_2.0$secondaryArchSuffix
|
||||
devel:libgthread_2.0$secondaryArchSuffix
|
||||
devel:libncurses$secondaryArchSuffix
|
||||
devel:libxml2$secondaryArchSuffix
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:gtkdoc_scan
|
||||
cmd:meson
|
||||
cmd:ninja
|
||||
cmd:pkg_config$secondaryArchSuffix
|
||||
"
|
||||
|
||||
defineDebugInfoPackage libgnt$secondaryArchSuffix \
|
||||
"$libDir"/libgnt.so.$libVersion
|
||||
|
||||
BUILD()
|
||||
{
|
||||
meson build --prefix=$prefix --libdir=$libDir --includedir=$includeDir
|
||||
ninja $jobargs -C build
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
ninja -C build install
|
||||
|
||||
mkdir -p $docDir
|
||||
mv $prefix/share/gtk-doc/html/libgnt/* $docDir
|
||||
rm -rf $prefix/share/
|
||||
|
||||
prepareInstalledDevelLib libgnt
|
||||
fixPkgconfig
|
||||
|
||||
packageEntries devel \
|
||||
$developDir
|
||||
}
|
||||
55
dev-libs/libgnt/patches/libgnt-2.14.1.patchset
Normal file
55
dev-libs/libgnt/patches/libgnt-2.14.1.patchset
Normal file
@@ -0,0 +1,55 @@
|
||||
From 6b1d5f1e026fd6f8cf488d117278a92e8e3ee50c Mon Sep 17 00:00:00 2001
|
||||
From: Jaidyn Ann <jadedctrl@teknik.io>
|
||||
Date: Mon, 28 Jun 2021 16:40:12 -0500
|
||||
Subject: Fix ncurses header
|
||||
|
||||
|
||||
diff --git a/meson.build b/meson.build
|
||||
index 1084c82..4e4c70a 100644
|
||||
--- a/meson.build
|
||||
+++ b/meson.build
|
||||
@@ -84,12 +84,17 @@ endif
|
||||
if host_machine.system() == 'windows'
|
||||
# FIXME: $host ?
|
||||
ncurses_sys_prefix = '/usr/$host/sys-root/mingw'
|
||||
+elif host_machine.system() == 'haiku'
|
||||
+ ncurses_sys_prefix = \
|
||||
+ run_command('finddir', 'B_SYSTEM_HEADERS_DIRECTORY').stdout().strip()
|
||||
else
|
||||
ncurses_sys_prefix = '/usr'
|
||||
endif
|
||||
|
||||
ncurses_sys_dirs = [ncurses_sys_prefix + '/include/ncursesw',
|
||||
- ncurses_sys_prefix + '/include']
|
||||
+ ncurses_sys_prefix + '/include',
|
||||
+ ncurses_sys_prefix + '/x86',
|
||||
+ ncurses_sys_prefix ]
|
||||
|
||||
if ncurses_available
|
||||
# Some distros put the headers in ncursesw/, some don't
|
||||
--
|
||||
2.30.2
|
||||
|
||||
|
||||
From acf694704e43b56dbf0984fd808c5ced950df723 Mon Sep 17 00:00:00 2001
|
||||
From: Jaidyn Ann <jadedctrl@teknik.io>
|
||||
Date: Tue, 29 Jun 2021 09:31:31 -0500
|
||||
Subject: cchat_t gntwm compat
|
||||
|
||||
|
||||
diff --git a/gntwm.c b/gntwm.c
|
||||
index ffb1f4a..affe57b 100644
|
||||
--- a/gntwm.c
|
||||
+++ b/gntwm.c
|
||||
@@ -32,7 +32,7 @@
|
||||
#define _GNU_SOURCE
|
||||
#endif
|
||||
|
||||
-#if !defined _XOPEN_SOURCE_EXTENDED && (defined(__APPLE__) || defined(__unix__))
|
||||
+#if !defined _XOPEN_SOURCE_EXTENDED && (defined(__APPLE__) || defined(__unix__) || defined(__HAIKU__))
|
||||
#define _XOPEN_SOURCE_EXTENDED
|
||||
#endif
|
||||
|
||||
--
|
||||
2.30.2
|
||||
|
||||
Reference in New Issue
Block a user