mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-09 05:10:05 +02:00
glib: Drop all but the latest and then latest gcc2 version.
This commit is contained in:
@@ -1,104 +0,0 @@
|
||||
SUMMARY="A cross-platform software utility library"
|
||||
DESCRIPTION="GLib is a cross-platform software utility library that began as \
|
||||
part of the GTK+ project. However, before releasing version 2 of GTK+, the \
|
||||
project's developers decided to separate non-GUI-specific code from the GTK+ \
|
||||
platform, thus creating GLib as a separate product. GLib was released as a \
|
||||
separate library so other developers, those who did not make use of the \
|
||||
GUI-related portions of GTK+, could make use of the non-GUI portions of the \
|
||||
library without the overhead of depending on the entire GUI library.
|
||||
|
||||
Since GLib is a cross-platform library, applications using it to interface \
|
||||
with the operating system are usually portable across different operating \
|
||||
systems without major changes"
|
||||
HOMEPAGE="https://www.gtk.org/"
|
||||
COPYRIGHT="1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
|
||||
1991-2002 Free Software Foundation, Inc.
|
||||
1997-2002 University of Cambridge.
|
||||
1998-2001, 2003-2010 Red Hat, Inc.
|
||||
1995-2002 Several others"
|
||||
LICENSE="GNU LGPL v2"
|
||||
REVISION="5"
|
||||
SOURCE_URI="http://ftp.gnome.org/pub/gnome/sources/glib/1.2/glib-1.2.10.tar.gz"
|
||||
CHECKSUM_SHA256="6e1ce7eedae713b11db82f11434d455d8a1379f783a79812cd2e05fc024a8d9f"
|
||||
PATCHES="glib-1.2.10.patchset"
|
||||
|
||||
ARCHITECTURES="all"
|
||||
SECONDARY_ARCHITECTURES="x86_gcc2 x86"
|
||||
|
||||
PROVIDES="
|
||||
glib$secondaryArchSuffix = $portVersion compat >= 1
|
||||
lib:libglib$secondaryArchSuffix = $portVersion compat >= 1
|
||||
lib:libglib_1.2$secondaryArchSuffix = $portVersion compat >= 1
|
||||
lib:libgmodule$secondaryArchSuffix = $portVersion compat >= 1
|
||||
lib:libgmodule_1.2$secondaryArchSuffix = $portVersion compat >= 1
|
||||
lib:libgthread$secondaryArchSuffix = $portVersion compat >= 1
|
||||
lib:libgthread_1.2$secondaryArchSuffix = $portVersion compat >= 1
|
||||
"
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
"
|
||||
|
||||
PROVIDES_devel="
|
||||
glib${secondaryArchSuffix}_devel = $portVersion compat >= 0
|
||||
cmd:glib_config$secondaryArchSuffix = $portVersion
|
||||
devel:libglib$secondaryArchSuffix = $portVersion compat >= 1
|
||||
devel:libglib_1.2$secondaryArchSuffix = $portVersion compat >= 1
|
||||
devel:libgmodule$secondaryArchSuffix = $portVersion compat >= 1
|
||||
devel:libgmodule_1.2$secondaryArchSuffix = $portVersion compat >= 1
|
||||
devel:libgthread$secondaryArchSuffix = $portVersion compat >= 1
|
||||
devel:libgthread_1.2$secondaryArchSuffix = $portVersion compat >= 1
|
||||
"
|
||||
REQUIRES_devel="
|
||||
glib$secondaryArchSuffix == $portVersion base
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:aclocal
|
||||
cmd:autoconf
|
||||
cmd:automake
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:ld$secondaryArchSuffix
|
||||
cmd:libtool
|
||||
cmd:libtoolize$secondaryArchSuffix
|
||||
cmd:m4
|
||||
cmd:make
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
libtoolize --force --copy --install
|
||||
aclocal
|
||||
automake --add-missing
|
||||
autoconf
|
||||
|
||||
runConfigure ./configure \
|
||||
--enable-shared=yes
|
||||
|
||||
cp -f $portPackageLinksDir/cmd~libtool/bin/libtool .
|
||||
|
||||
make $jobArgs
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
make install
|
||||
|
||||
prepareInstalledDevelLibs libglib libglib-1.2 \
|
||||
libgmodule libgmodule-1.2 \
|
||||
libgthread libgthread-1.2
|
||||
|
||||
fixPkgconfig
|
||||
|
||||
fixDevelopLibDirReferences $binDir/glib-config
|
||||
|
||||
mv $libDir/glib/include/glibconfig.h $includeDir/glib-1.2
|
||||
rm -rf $libDir/glib
|
||||
|
||||
# devel package
|
||||
packageEntries devel \
|
||||
$developDir $binDir \
|
||||
$manDir $infoDir $dataDir
|
||||
}
|
||||
@@ -1,154 +0,0 @@
|
||||
SUMMARY="GLib is a cross-platform software utility library"
|
||||
DESCRIPTION="GLib is a cross-platform software utility library that began as \
|
||||
part of the GTK+ project. However, before releasing version 2 of GTK+, the \
|
||||
project's developers decided to separate non-GUI-specific code from the GTK+ \
|
||||
platform, thus creating GLib as a separate product. GLib was released as a \
|
||||
separate library so other developers, those who did not make use of the \
|
||||
GUI-related portions of GTK+, could make use of the non-GUI portions of the \
|
||||
library without the overhead of depending on the entire GUI library.
|
||||
Since GLib is a cross-platform library, applications using it to interface \
|
||||
with the operating system are usually portable across different operating \
|
||||
systems without major changes
|
||||
"
|
||||
HOMEPAGE="https://www.gtk.org/"
|
||||
SOURCE_URI="http://ftp.gnome.org/pub/gnome/sources/glib/2.38/glib-2.38.1.tar.xz"
|
||||
CHECKSUM_SHA256="01906c62ac666d2ab3183cc07261b2536fab7b211c6129ab66b119c2af56d159"
|
||||
LICENSE="GNU LGPL v2"
|
||||
COPYRIGHT="1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
|
||||
1991-2003 Free Software Foundation, Inc.
|
||||
1997-2006 University of Cambridge.
|
||||
1998-2001, 2003-2010 Red Hat, Inc.
|
||||
2007-2009 Nokia Corporation
|
||||
2008, 2010 Oracle and/or its affiliates, Inc. All rights
|
||||
2008-2010 Codethink Limited
|
||||
2008-2010 Collabora Ltd.
|
||||
1995-2010 Several others"
|
||||
|
||||
REVISION="8"
|
||||
|
||||
ARCHITECTURES="all"
|
||||
SECONDARY_ARCHITECTURES="x86_gcc2 x86"
|
||||
|
||||
PROVIDES="
|
||||
glib2$secondaryArchSuffix = $portVersion compat >= 2
|
||||
cmd:gdbus$secondaryArchSuffix
|
||||
cmd:gdbus_codegen$secondaryArchSuffix
|
||||
cmd:gio_querymodules$secondaryArchSuffix
|
||||
cmd:glib_compile_resources$secondaryArchSuffix
|
||||
cmd:glib_compile_schemas$secondaryArchSuffix
|
||||
cmd:glib_genmarshal$secondaryArchSuffix
|
||||
cmd:glib_gettextize$secondaryArchSuffix
|
||||
cmd:glib_mkenums$secondaryArchSuffix
|
||||
cmd:gobject_query$secondaryArchSuffix
|
||||
cmd:gresource$secondaryArchSuffix
|
||||
cmd:gsettings$secondaryArchSuffix
|
||||
cmd:gtester$secondaryArchSuffix
|
||||
cmd:gtester_report$secondaryArchSuffix
|
||||
lib:libgio_2.0$secondaryArchSuffix = 0.3800.1 compat >= 0
|
||||
lib:libglib_2.0$secondaryArchSuffix = 0.3800.1 compat >= 0
|
||||
lib:libgmodule_2.0$secondaryArchSuffix = 0.3800.1 compat >= 0
|
||||
lib:libgobject_2.0$secondaryArchSuffix = 0.3800.1 compat >= 0
|
||||
lib:libgthread_2.0$secondaryArchSuffix = 0.3800.1 compat >= 0
|
||||
"
|
||||
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
gettext$secondaryArchSuffix
|
||||
lib:libiconv$secondaryArchSuffix
|
||||
lib:libz$secondaryArchSuffix
|
||||
lib:libffi$secondaryArchSuffix
|
||||
lib:libintl$secondaryArchSuffix
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
devel:libiconv$secondaryArchSuffix
|
||||
devel:libz$secondaryArchSuffix
|
||||
devel:libffi$secondaryArchSuffix
|
||||
devel:libintl$secondaryArchSuffix
|
||||
"
|
||||
|
||||
BUILD_PREREQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:ld$secondaryArchSuffix
|
||||
cmd:libtoolize$secondaryArchSuffix
|
||||
cmd:aclocal
|
||||
cmd:autoconf
|
||||
cmd:make
|
||||
cmd:pkg_config$secondaryArchSuffix
|
||||
cmd:python
|
||||
"
|
||||
|
||||
PATCHES="glib2-2.38.1.patchset"
|
||||
|
||||
SOURCE_DIR="glib-2.38.1"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
libtoolize --force --copy --install
|
||||
aclocal
|
||||
autoconf
|
||||
runConfigure ./configure --disable-maintainer-mode CFLAGS=-D_BSD_SOURCE
|
||||
|
||||
# There seem to be a problem with libtool, and without this some libraries
|
||||
# would not be found during the build.
|
||||
mkdir -p gobject/.libs
|
||||
ln -sf ../../glib/.libs gobject/.libs/lib
|
||||
|
||||
make $jobArgs
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
make install
|
||||
|
||||
# remove libtool library files
|
||||
rm $libDir/lib*.la
|
||||
|
||||
prepareInstalledDevelLibs libgio-2.0 \
|
||||
libglib-2.0 \
|
||||
libgmodule-2.0 \
|
||||
libgobject-2.0 \
|
||||
libgthread-2.0
|
||||
fixPkgconfig
|
||||
|
||||
# The libtool files reference other libraries using the wrong paths, which
|
||||
# creates a lot of confusion. Fix them so correct paths are used.
|
||||
local develPackageName="${portName}_devel-$portFullVersion"
|
||||
local packageLinksDir=$(dirname $portPackageLinksDir)
|
||||
local ffiLinksDir="$packageLinksDir/${develPackageName}/devel~libffi$secondaryArchSuffix/$relativeDevelopLibDir"
|
||||
sed -i -e "s,^\(Libs.private.*\)-L.* \(-l.*\)$,\1-L$ffiLinksDir \2," \
|
||||
$developLibDir/pkgconfig/gobject-2.0.pc
|
||||
local zlibLinksDir="$packageLinksDir/${develPackageName}/devel~libz$secondaryArchSuffix/$relativeDevelopLibDir"
|
||||
sed -i -e "s,^\(Libs.private.*\)-L.* \(-l.*\)$,\1-L$zlibLinksDir \2," \
|
||||
$developLibDir/pkgconfig/gio-2.0.pc
|
||||
|
||||
|
||||
# move the glibconfig header into devel as well
|
||||
mv $libDir/glib-2.0 $developLibDir
|
||||
|
||||
fixPkgconfig
|
||||
|
||||
# devel package
|
||||
packageEntries devel \
|
||||
$developDir
|
||||
}
|
||||
|
||||
# ----- devel package -------------------------------------------------------
|
||||
|
||||
PROVIDES_devel="
|
||||
glib2${secondaryArchSuffix}_devel = $portVersion compat >= 0
|
||||
devel:libgio_2.0$secondaryArchSuffix = 0.3800.1 compat >= 0
|
||||
devel:libglib_2.0$secondaryArchSuffix = 0.3800.1 compat >= 0
|
||||
devel:libgmodule_2.0$secondaryArchSuffix = 0.3800.1 compat >= 0
|
||||
devel:libgobject_2.0$secondaryArchSuffix = 0.3800.1 compat >= 0
|
||||
devel:libgthread_2.0$secondaryArchSuffix = 0.3800.1 compat >= 0
|
||||
"
|
||||
|
||||
REQUIRES_devel="
|
||||
glib2$secondaryArchSuffix == $portVersion base
|
||||
devel:libffi$secondaryArchSuffix
|
||||
devel:libiconv$secondaryArchSuffix
|
||||
devel:libintl$secondaryArchSuffix
|
||||
devel:libz$secondaryArchSuffix
|
||||
"
|
||||
@@ -1,153 +0,0 @@
|
||||
SUMMARY="GLib is a cross-platform software utility library"
|
||||
DESCRIPTION="GLib is a cross-platform software utility library that began as \
|
||||
part of the GTK+ project. However, before releasing version 2 of GTK+, the \
|
||||
project's developers decided to separate non-GUI-specific code from the GTK+ \
|
||||
platform, thus creating GLib as a separate product. GLib was released as a \
|
||||
separate library so other developers, those who did not make use of the \
|
||||
GUI-related portions of GTK+, could make use of the non-GUI portions of the \
|
||||
library without the overhead of depending on the entire GUI library.
|
||||
Since GLib is a cross-platform library, applications using it to interface \
|
||||
with the operating system are usually portable across different operating \
|
||||
systems without major changes
|
||||
"
|
||||
HOMEPAGE="https://www.gtk.org/"
|
||||
SOURCE_URI="http://ftp.gnome.org/pub/gnome/sources/glib/2.46/glib-$portVersion.tar.xz"
|
||||
CHECKSUM_SHA256="5031722e37036719c1a09163cc6cf7c326e4c4f1f1e074b433c156862bd733db"
|
||||
LICENSE="GNU LGPL v2"
|
||||
COPYRIGHT="1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
|
||||
1991-2003 Free Software Foundation, Inc.
|
||||
1997-2006 University of Cambridge.
|
||||
1998-2001, 2003-2010 Red Hat, Inc.
|
||||
2007-2009 Nokia Corporation
|
||||
2008, 2010 Oracle and/or its affiliates, Inc. All rights
|
||||
2008-2010 Codethink Limited
|
||||
2008-2010 Collabora Ltd.
|
||||
1995-2010 Several others"
|
||||
|
||||
REVISION="3"
|
||||
|
||||
ARCHITECTURES="all"
|
||||
SECONDARY_ARCHITECTURES="x86_gcc2 x86"
|
||||
|
||||
PROVIDES="
|
||||
glib2$secondaryArchSuffix = $portVersion compat >= 2
|
||||
cmd:gapplication$secondaryArchSuffix
|
||||
cmd:gdbus$secondaryArchSuffix
|
||||
cmd:gdbus_codegen$secondaryArchSuffix
|
||||
cmd:gio_querymodules$secondaryArchSuffix
|
||||
cmd:glib_compile_resources$secondaryArchSuffix
|
||||
cmd:glib_compile_schemas$secondaryArchSuffix
|
||||
cmd:glib_genmarshal$secondaryArchSuffix
|
||||
cmd:glib_gettextize$secondaryArchSuffix
|
||||
cmd:glib_mkenums$secondaryArchSuffix
|
||||
cmd:gobject_query$secondaryArchSuffix
|
||||
cmd:gresource$secondaryArchSuffix
|
||||
cmd:gsettings$secondaryArchSuffix
|
||||
cmd:gtester$secondaryArchSuffix
|
||||
cmd:gtester_report$secondaryArchSuffix
|
||||
lib:libgio_2.0$secondaryArchSuffix = 0.4600.2 compat >= 0
|
||||
lib:libglib_2.0$secondaryArchSuffix = 0.4600.2 compat >= 0
|
||||
lib:libgmodule_2.0$secondaryArchSuffix = 0.4600.2 compat >= 0
|
||||
lib:libgobject_2.0$secondaryArchSuffix = 0.4600.2 compat >= 0
|
||||
lib:libgthread_2.0$secondaryArchSuffix = 0.4600.2 compat >= 0
|
||||
"
|
||||
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
gettext$secondaryArchSuffix
|
||||
lib:libiconv$secondaryArchSuffix
|
||||
lib:libz$secondaryArchSuffix
|
||||
lib:libffi$secondaryArchSuffix
|
||||
lib:libintl$secondaryArchSuffix
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
devel:libiconv$secondaryArchSuffix
|
||||
devel:libz$secondaryArchSuffix
|
||||
devel:libffi$secondaryArchSuffix
|
||||
devel:libintl$secondaryArchSuffix
|
||||
"
|
||||
|
||||
BUILD_PREREQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:ld$secondaryArchSuffix
|
||||
cmd:libtoolize$secondaryArchSuffix
|
||||
cmd:aclocal
|
||||
cmd:autoconf
|
||||
cmd:make
|
||||
cmd:pkg_config$secondaryArchSuffix
|
||||
cmd:python
|
||||
"
|
||||
|
||||
PATCHES="glib2-$portVersion.patchset"
|
||||
|
||||
SOURCE_DIR="glib-$portVersion"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
autoreconf -fi
|
||||
runConfigure ./configure CFLAGS=-D_BSD_SOURCE
|
||||
|
||||
# There seem to be a problem with libtool, and without this some libraries
|
||||
# would not be found during the build.
|
||||
mkdir -p gobject/.libs gio/.libs
|
||||
ln -sf ../../glib/.libs gobject/.libs/lib
|
||||
|
||||
make $jobArgs
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
make install
|
||||
|
||||
# remove libtool library files
|
||||
rm $libDir/lib*.la
|
||||
|
||||
prepareInstalledDevelLibs libgio-2.0 \
|
||||
libglib-2.0 \
|
||||
libgmodule-2.0 \
|
||||
libgobject-2.0 \
|
||||
libgthread-2.0
|
||||
fixPkgconfig
|
||||
|
||||
# The libtool files reference other libraries using the wrong paths, which
|
||||
# creates a lot of confusion. Fix them so correct paths are used.
|
||||
local develPackageName="${portName}_devel-$portFullVersion"
|
||||
local packageLinksDir=$(dirname $portPackageLinksDir)
|
||||
local ffiLinksDir="$packageLinksDir/${develPackageName}/devel~libffi$secondaryArchSuffix/$relativeDevelopLibDir"
|
||||
sed -i -e "s,^\(Libs.private.*\)-L.* \(-l.*\)$,\1-L$ffiLinksDir \2," \
|
||||
$developLibDir/pkgconfig/gobject-2.0.pc
|
||||
local zlibLinksDir="$packageLinksDir/${develPackageName}/devel~libz$secondaryArchSuffix/$relativeDevelopLibDir"
|
||||
sed -i -e "s,^\(Libs.private.*\)-L.* \(-l.*\)$,\1-L$zlibLinksDir \2," \
|
||||
$developLibDir/pkgconfig/gio-2.0.pc
|
||||
|
||||
|
||||
# move the glibconfig header into devel as well
|
||||
mv $libDir/glib-2.0 $developLibDir
|
||||
|
||||
fixPkgconfig
|
||||
|
||||
# devel package
|
||||
packageEntries devel \
|
||||
$developDir
|
||||
}
|
||||
|
||||
# ----- devel package -------------------------------------------------------
|
||||
|
||||
PROVIDES_devel="
|
||||
glib2${secondaryArchSuffix}_devel = $portVersion compat >= 0
|
||||
devel:libgio_2.0$secondaryArchSuffix = 0.4600.2 compat >= 0
|
||||
devel:libglib_2.0$secondaryArchSuffix = 0.4600.2 compat >= 0
|
||||
devel:libgmodule_2.0$secondaryArchSuffix = 0.4600.2 compat >= 0
|
||||
devel:libgobject_2.0$secondaryArchSuffix = 0.4600.2 compat >= 0
|
||||
devel:libgthread_2.0$secondaryArchSuffix = 0.4600.2 compat >= 0
|
||||
"
|
||||
|
||||
REQUIRES_devel="
|
||||
glib2$secondaryArchSuffix == $portVersion base
|
||||
devel:libffi$secondaryArchSuffix
|
||||
devel:libiconv$secondaryArchSuffix
|
||||
devel:libintl$secondaryArchSuffix
|
||||
devel:libz$secondaryArchSuffix
|
||||
"
|
||||
@@ -1,153 +0,0 @@
|
||||
SUMMARY="GLib is a cross-platform software utility library"
|
||||
DESCRIPTION="GLib is a cross-platform software utility library that began as \
|
||||
part of the GTK+ project. However, before releasing version 2 of GTK+, the \
|
||||
project's developers decided to separate non-GUI-specific code from the GTK+ \
|
||||
platform, thus creating GLib as a separate product. GLib was released as a \
|
||||
separate library so other developers, those who did not make use of the \
|
||||
GUI-related portions of GTK+, could make use of the non-GUI portions of the \
|
||||
library without the overhead of depending on the entire GUI library.
|
||||
Since GLib is a cross-platform library, applications using it to interface \
|
||||
with the operating system are usually portable across different operating \
|
||||
systems without major changes
|
||||
"
|
||||
HOMEPAGE="https://www.gtk.org/"
|
||||
SOURCE_URI="http://ftp.gnome.org/pub/gnome/sources/glib/2.47/glib-$portVersion.tar.xz"
|
||||
CHECKSUM_SHA256="4270129436fc2380e59f500b602d7c165cece208cda2872fdf1e8d1322cd1520"
|
||||
LICENSE="GNU LGPL v2"
|
||||
COPYRIGHT="1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
|
||||
1991-2003 Free Software Foundation, Inc.
|
||||
1997-2006 University of Cambridge.
|
||||
1998-2001, 2003-2010 Red Hat, Inc.
|
||||
2007-2009 Nokia Corporation
|
||||
2008, 2010 Oracle and/or its affiliates, Inc. All rights
|
||||
2008-2010 Codethink Limited
|
||||
2008-2010 Collabora Ltd.
|
||||
1995-2010 Several others"
|
||||
|
||||
REVISION="3"
|
||||
|
||||
ARCHITECTURES="?all"
|
||||
SECONDARY_ARCHITECTURES="?x86_gcc2 ?x86"
|
||||
|
||||
PROVIDES="
|
||||
glib2$secondaryArchSuffix = $portVersion compat >= 2
|
||||
cmd:gapplication$secondaryArchSuffix
|
||||
cmd:gdbus$secondaryArchSuffix
|
||||
cmd:gdbus_codegen$secondaryArchSuffix
|
||||
cmd:gio_querymodules$secondaryArchSuffix
|
||||
cmd:glib_compile_resources$secondaryArchSuffix
|
||||
cmd:glib_compile_schemas$secondaryArchSuffix
|
||||
cmd:glib_genmarshal$secondaryArchSuffix
|
||||
cmd:glib_gettextize$secondaryArchSuffix
|
||||
cmd:glib_mkenums$secondaryArchSuffix
|
||||
cmd:gobject_query$secondaryArchSuffix
|
||||
cmd:gresource$secondaryArchSuffix
|
||||
cmd:gsettings$secondaryArchSuffix
|
||||
cmd:gtester$secondaryArchSuffix
|
||||
cmd:gtester_report$secondaryArchSuffix
|
||||
lib:libgio_2.0$secondaryArchSuffix = 0.4703.0 compat >= 0
|
||||
lib:libglib_2.0$secondaryArchSuffix = 0.4703.0 compat >= 0
|
||||
lib:libgmodule_2.0$secondaryArchSuffix = 0.4703.0 compat >= 0
|
||||
lib:libgobject_2.0$secondaryArchSuffix = 0.4703.0 compat >= 0
|
||||
lib:libgthread_2.0$secondaryArchSuffix = 0.4703.0 compat >= 0
|
||||
"
|
||||
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
gettext$secondaryArchSuffix
|
||||
lib:libiconv$secondaryArchSuffix
|
||||
lib:libz$secondaryArchSuffix
|
||||
lib:libffi$secondaryArchSuffix
|
||||
lib:libintl$secondaryArchSuffix
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
devel:libiconv$secondaryArchSuffix
|
||||
devel:libz$secondaryArchSuffix
|
||||
devel:libffi$secondaryArchSuffix
|
||||
devel:libintl$secondaryArchSuffix
|
||||
"
|
||||
|
||||
BUILD_PREREQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:ld$secondaryArchSuffix
|
||||
cmd:libtoolize$secondaryArchSuffix
|
||||
cmd:aclocal
|
||||
cmd:autoconf
|
||||
cmd:make
|
||||
cmd:pkg_config$secondaryArchSuffix
|
||||
cmd:python
|
||||
"
|
||||
|
||||
PATCHES="glib2-$portVersion.patchset"
|
||||
|
||||
SOURCE_DIR="glib-$portVersion"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
autoreconf -fi
|
||||
runConfigure ./configure CFLAGS=-D_BSD_SOURCE
|
||||
|
||||
# There seem to be a problem with libtool, and without this some libraries
|
||||
# would not be found during the build.
|
||||
mkdir -p gobject/.libs gio/.libs
|
||||
ln -sf ../../glib/.libs gobject/.libs/lib
|
||||
|
||||
make $jobArgs
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
make install
|
||||
|
||||
# remove libtool library files
|
||||
rm $libDir/lib*.la
|
||||
|
||||
prepareInstalledDevelLibs libgio-2.0 \
|
||||
libglib-2.0 \
|
||||
libgmodule-2.0 \
|
||||
libgobject-2.0 \
|
||||
libgthread-2.0
|
||||
fixPkgconfig
|
||||
|
||||
# The libtool files reference other libraries using the wrong paths, which
|
||||
# creates a lot of confusion. Fix them so correct paths are used.
|
||||
local develPackageName="${portName}_devel-$portFullVersion"
|
||||
local packageLinksDir=$(dirname $portPackageLinksDir)
|
||||
local ffiLinksDir="$packageLinksDir/${develPackageName}/devel~libffi$secondaryArchSuffix/$relativeDevelopLibDir"
|
||||
sed -i -e "s,^\(Libs.private.*\)-L.* \(-l.*\)$,\1-L$ffiLinksDir \2," \
|
||||
$developLibDir/pkgconfig/gobject-2.0.pc
|
||||
local zlibLinksDir="$packageLinksDir/${develPackageName}/devel~libz$secondaryArchSuffix/$relativeDevelopLibDir"
|
||||
sed -i -e "s,^\(Libs.private.*\)-L.* \(-l.*\)$,\1-L$zlibLinksDir \2," \
|
||||
$developLibDir/pkgconfig/gio-2.0.pc
|
||||
|
||||
|
||||
# move the glibconfig header into devel as well
|
||||
mv $libDir/glib-2.0 $developLibDir
|
||||
|
||||
fixPkgconfig
|
||||
|
||||
# devel package
|
||||
packageEntries devel \
|
||||
$developDir
|
||||
}
|
||||
|
||||
# ----- devel package -------------------------------------------------------
|
||||
|
||||
PROVIDES_devel="
|
||||
glib2${secondaryArchSuffix}_devel = $portVersion compat >= 0
|
||||
devel:libgio_2.0$secondaryArchSuffix = 0.4703.0 compat >= 0
|
||||
devel:libglib_2.0$secondaryArchSuffix = 0.4703.0 compat >= 0
|
||||
devel:libgmodule_2.0$secondaryArchSuffix = 0.4703.0 compat >= 0
|
||||
devel:libgobject_2.0$secondaryArchSuffix = 0.4703.0 compat >= 0
|
||||
devel:libgthread_2.0$secondaryArchSuffix = 0.4703.0 compat >= 0
|
||||
"
|
||||
|
||||
REQUIRES_devel="
|
||||
glib2$secondaryArchSuffix == $portVersion base
|
||||
devel:libffi$secondaryArchSuffix
|
||||
devel:libiconv$secondaryArchSuffix
|
||||
devel:libintl$secondaryArchSuffix
|
||||
devel:libz$secondaryArchSuffix
|
||||
"
|
||||
@@ -1,150 +0,0 @@
|
||||
SUMMARY="GLib is a cross-platform software utility library"
|
||||
DESCRIPTION="GLib is a cross-platform software utility library that began as \
|
||||
part of the GTK+ project. However, before releasing version 2 of GTK+, the \
|
||||
project's developers decided to separate non-GUI-specific code from the GTK+ \
|
||||
platform, thus creating GLib as a separate product. GLib was released as a \
|
||||
separate library so other developers, those who did not make use of the \
|
||||
GUI-related portions of GTK+, could make use of the non-GUI portions of the \
|
||||
library without the overhead of depending on the entire GUI library.
|
||||
Since GLib is a cross-platform library, applications using it to interface \
|
||||
with the operating system are usually portable across different operating \
|
||||
systems without major changes
|
||||
"
|
||||
HOMEPAGE="https://www.gtk.org/"
|
||||
COPYRIGHT="1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
|
||||
1991-2003 Free Software Foundation, Inc.
|
||||
1997-2006 University of Cambridge.
|
||||
1998-2001, 2003-2010 Red Hat, Inc.
|
||||
2007-2009 Nokia Corporation
|
||||
2008, 2010 Oracle and/or its affiliates, Inc. All rights
|
||||
2008-2010 Codethink Limited
|
||||
2008-2010 Collabora Ltd.
|
||||
1995-2010 Several others"
|
||||
LICENSE="GNU LGPL v2"
|
||||
REVISION="3"
|
||||
SOURCE_URI="http://ftp.gnome.org/pub/gnome/sources/glib/${portVersion%.*}/glib-$portVersion.tar.xz"
|
||||
CHECKSUM_SHA256="f25e751589cb1a58826eac24fbd4186cda4518af772806b666a3f91f66e6d3f4"
|
||||
SOURCE_DIR="glib-$portVersion"
|
||||
PATCHES="glib2-$portVersion.patchset"
|
||||
|
||||
ARCHITECTURES="all"
|
||||
SECONDARY_ARCHITECTURES="?x86_gcc2 ?x86"
|
||||
|
||||
PROVIDES="
|
||||
glib2$secondaryArchSuffix = $portVersion compat >= 2
|
||||
cmd:gapplication$secondaryArchSuffix
|
||||
cmd:gdbus$secondaryArchSuffix
|
||||
cmd:gdbus_codegen$secondaryArchSuffix
|
||||
cmd:gio_querymodules$secondaryArchSuffix
|
||||
cmd:glib_compile_resources$secondaryArchSuffix
|
||||
cmd:glib_compile_schemas$secondaryArchSuffix
|
||||
cmd:glib_genmarshal$secondaryArchSuffix
|
||||
cmd:glib_gettextize$secondaryArchSuffix
|
||||
cmd:glib_mkenums$secondaryArchSuffix
|
||||
cmd:gobject_query$secondaryArchSuffix
|
||||
cmd:gresource$secondaryArchSuffix
|
||||
cmd:gsettings$secondaryArchSuffix
|
||||
cmd:gtester$secondaryArchSuffix
|
||||
cmd:gtester_report$secondaryArchSuffix
|
||||
lib:libgio_2.0$secondaryArchSuffix = 0.4800.2 compat >= 0
|
||||
lib:libglib_2.0$secondaryArchSuffix = 0.4800.2 compat >= 0
|
||||
lib:libgmodule_2.0$secondaryArchSuffix = 0.4800.2 compat >= 0
|
||||
lib:libgobject_2.0$secondaryArchSuffix = 0.4800.2 compat >= 0
|
||||
lib:libgthread_2.0$secondaryArchSuffix = 0.4800.2 compat >= 0
|
||||
"
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
gettext$secondaryArchSuffix
|
||||
lib:libffi$secondaryArchSuffix
|
||||
lib:libiconv$secondaryArchSuffix
|
||||
lib:libintl$secondaryArchSuffix
|
||||
lib:libpcre$secondaryArchSuffix >= 1
|
||||
lib:libz$secondaryArchSuffix
|
||||
"
|
||||
|
||||
PROVIDES_devel="
|
||||
glib2${secondaryArchSuffix}_devel = $portVersion compat >= 0
|
||||
devel:libgio_2.0$secondaryArchSuffix = 0.4800.2 compat >= 0
|
||||
devel:libglib_2.0$secondaryArchSuffix = 0.4800.2 compat >= 0
|
||||
devel:libgmodule_2.0$secondaryArchSuffix = 0.4800.2 compat >= 0
|
||||
devel:libgobject_2.0$secondaryArchSuffix = 0.4800.2 compat >= 0
|
||||
devel:libgthread_2.0$secondaryArchSuffix = 0.4800.2 compat >= 0
|
||||
"
|
||||
REQUIRES_devel="
|
||||
glib2$secondaryArchSuffix == $portVersion base
|
||||
devel:libffi$secondaryArchSuffix
|
||||
devel:libiconv$secondaryArchSuffix
|
||||
devel:libintl$secondaryArchSuffix
|
||||
devel:libpcre$secondaryArchSuffix
|
||||
devel:libz$secondaryArchSuffix
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
devel:libffi$secondaryArchSuffix
|
||||
devel:libiconv$secondaryArchSuffix
|
||||
devel:libintl$secondaryArchSuffix
|
||||
devel:libpcre$secondaryArchSuffix >= 1
|
||||
devel:libz$secondaryArchSuffix
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:aclocal
|
||||
cmd:autoconf
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:ld$secondaryArchSuffix
|
||||
cmd:libtoolize$secondaryArchSuffix
|
||||
cmd:make
|
||||
cmd:pkg_config$secondaryArchSuffix
|
||||
cmd:python
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
autoreconf -fi
|
||||
runConfigure ./configure CFLAGS=-D_BSD_SOURCE
|
||||
|
||||
# There seem to be a problem with libtool, and without this some libraries
|
||||
# would not be found during the build.
|
||||
mkdir -p gobject/.libs gio/.libs
|
||||
ln -sf ../../glib/.libs gobject/.libs/lib
|
||||
|
||||
make $jobArgs
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
make install
|
||||
|
||||
# remove libtool library files
|
||||
rm $libDir/lib*.la
|
||||
|
||||
prepareInstalledDevelLibs libgio-2.0 \
|
||||
libglib-2.0 \
|
||||
libgmodule-2.0 \
|
||||
libgobject-2.0 \
|
||||
libgthread-2.0
|
||||
fixPkgconfig
|
||||
|
||||
# The libtool files reference other libraries using the wrong paths, which
|
||||
# creates a lot of confusion. Fix them so correct paths are used.
|
||||
local develPackageName="${portName}_devel-$portFullVersion"
|
||||
local packageLinksDir=$(dirname $portPackageLinksDir)
|
||||
local ffiLinksDir="$packageLinksDir/${develPackageName}/devel~libffi$secondaryArchSuffix/$relativeDevelopLibDir"
|
||||
sed -i -e "s,^\(Libs.private.*\)-L.* \(-l.*\)$,\1-L$ffiLinksDir \2," \
|
||||
$developLibDir/pkgconfig/gobject-2.0.pc
|
||||
local zlibLinksDir="$packageLinksDir/${develPackageName}/devel~libz$secondaryArchSuffix/$relativeDevelopLibDir"
|
||||
sed -i -e "s,^\(Libs.private.*\)-L.* \(-l.*\)$,\1-L$zlibLinksDir \2," \
|
||||
$developLibDir/pkgconfig/gio-2.0.pc
|
||||
|
||||
|
||||
# move the glibconfig header into devel as well
|
||||
mv $libDir/glib-2.0 $developLibDir
|
||||
|
||||
fixPkgconfig
|
||||
|
||||
# devel package
|
||||
packageEntries devel \
|
||||
$developDir
|
||||
|
||||
rm $libDir/charset.alias
|
||||
}
|
||||
@@ -1,151 +0,0 @@
|
||||
SUMMARY="GLib is a cross-platform software utility library"
|
||||
DESCRIPTION="GLib is a cross-platform software utility library that began as \
|
||||
part of the GTK+ project. However, before releasing version 2 of GTK+, the \
|
||||
project's developers decided to separate non-GUI-specific code from the GTK+ \
|
||||
platform, thus creating GLib as a separate product. GLib was released as a \
|
||||
separate library so other developers, those who did not make use of the \
|
||||
GUI-related portions of GTK+, could make use of the non-GUI portions of the \
|
||||
library without the overhead of depending on the entire GUI library.
|
||||
Since GLib is a cross-platform library, applications using it to interface \
|
||||
with the operating system are usually portable across different operating \
|
||||
systems without major changes
|
||||
"
|
||||
HOMEPAGE="https://www.gtk.org/"
|
||||
COPYRIGHT="1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
|
||||
1991-2003 Free Software Foundation, Inc.
|
||||
1997-2006 University of Cambridge.
|
||||
1998-2001, 2003-2010 Red Hat, Inc.
|
||||
2007-2009 Nokia Corporation
|
||||
2008, 2010 Oracle and/or its affiliates, Inc. All rights
|
||||
2008-2010 Codethink Limited
|
||||
2008-2010 Collabora Ltd.
|
||||
1995-2010 Several others"
|
||||
LICENSE="GNU LGPL v2"
|
||||
REVISION="2"
|
||||
SOURCE_URI="http://ftp.gnome.org/pub/gnome/sources/glib/${portVersion%.*}/glib-$portVersion.tar.xz"
|
||||
CHECKSUM_SHA256="c8740f1d1a138086eede889b596a511fddda180646ab2f1d98aed4fdb6be7f72"
|
||||
SOURCE_DIR="glib-$portVersion"
|
||||
PATCHES="glib2-$portVersion.patchset"
|
||||
|
||||
ARCHITECTURES="all"
|
||||
SECONDARY_ARCHITECTURES="?x86_gcc2 ?x86"
|
||||
|
||||
PROVIDES="
|
||||
glib2$secondaryArchSuffix = $portVersion compat >= 2
|
||||
cmd:gapplication$secondaryArchSuffix
|
||||
cmd:gdbus$secondaryArchSuffix
|
||||
cmd:gdbus_codegen$secondaryArchSuffix
|
||||
cmd:gio$secondaryArchSuffix
|
||||
cmd:gio_querymodules$secondaryArchSuffix
|
||||
cmd:glib_compile_resources$secondaryArchSuffix
|
||||
cmd:glib_compile_schemas$secondaryArchSuffix
|
||||
cmd:glib_genmarshal$secondaryArchSuffix
|
||||
cmd:glib_gettextize$secondaryArchSuffix
|
||||
cmd:glib_mkenums$secondaryArchSuffix
|
||||
cmd:gobject_query$secondaryArchSuffix
|
||||
cmd:gresource$secondaryArchSuffix
|
||||
cmd:gsettings$secondaryArchSuffix
|
||||
cmd:gtester$secondaryArchSuffix
|
||||
cmd:gtester_report$secondaryArchSuffix
|
||||
lib:libgio_2.0$secondaryArchSuffix = 0.5301.0 compat >= 0
|
||||
lib:libglib_2.0$secondaryArchSuffix = 0.5301.0 compat >= 0
|
||||
lib:libgmodule_2.0$secondaryArchSuffix = 0.5301.0 compat >= 0
|
||||
lib:libgobject_2.0$secondaryArchSuffix = 0.5301.0 compat >= 0
|
||||
lib:libgthread_2.0$secondaryArchSuffix = 0.5301.0 compat >= 0
|
||||
"
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
gettext$secondaryArchSuffix
|
||||
lib:libffi$secondaryArchSuffix
|
||||
lib:libiconv$secondaryArchSuffix
|
||||
lib:libintl$secondaryArchSuffix
|
||||
lib:libpcre$secondaryArchSuffix >= 1
|
||||
lib:libz$secondaryArchSuffix
|
||||
"
|
||||
|
||||
PROVIDES_devel="
|
||||
glib2${secondaryArchSuffix}_devel = $portVersion compat >= 0
|
||||
devel:libgio_2.0$secondaryArchSuffix = 0.5301.0 compat >= 0
|
||||
devel:libglib_2.0$secondaryArchSuffix = 0.5301.0 compat >= 0
|
||||
devel:libgmodule_2.0$secondaryArchSuffix = 0.5301.0 compat >= 0
|
||||
devel:libgobject_2.0$secondaryArchSuffix = 0.5301.0 compat >= 0
|
||||
devel:libgthread_2.0$secondaryArchSuffix = 0.5301.0 compat >= 0
|
||||
"
|
||||
REQUIRES_devel="
|
||||
glib2$secondaryArchSuffix == $portVersion base
|
||||
devel:libffi$secondaryArchSuffix
|
||||
devel:libiconv$secondaryArchSuffix
|
||||
devel:libintl$secondaryArchSuffix
|
||||
devel:libpcre$secondaryArchSuffix
|
||||
devel:libz$secondaryArchSuffix
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
devel:libffi$secondaryArchSuffix
|
||||
devel:libiconv$secondaryArchSuffix
|
||||
devel:libintl$secondaryArchSuffix
|
||||
devel:libpcre$secondaryArchSuffix >= 1
|
||||
devel:libz$secondaryArchSuffix
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:aclocal
|
||||
cmd:autoconf
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:ld$secondaryArchSuffix
|
||||
cmd:libtoolize$secondaryArchSuffix
|
||||
cmd:make
|
||||
cmd:pkg_config$secondaryArchSuffix
|
||||
cmd:python
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
autoreconf -fi
|
||||
runConfigure ./configure CFLAGS=-D_BSD_SOURCE
|
||||
|
||||
# There seem to be a problem with libtool, and without this some libraries
|
||||
# would not be found during the build.
|
||||
mkdir -p gobject/.libs gio/.libs
|
||||
ln -sf ../../glib/.libs gobject/.libs/lib
|
||||
|
||||
make $jobArgs
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
make install
|
||||
|
||||
# remove libtool library files
|
||||
rm $libDir/lib*.la
|
||||
|
||||
prepareInstalledDevelLibs libgio-2.0 \
|
||||
libglib-2.0 \
|
||||
libgmodule-2.0 \
|
||||
libgobject-2.0 \
|
||||
libgthread-2.0
|
||||
fixPkgconfig
|
||||
|
||||
# The libtool files reference other libraries using the wrong paths, which
|
||||
# creates a lot of confusion. Fix them so correct paths are used.
|
||||
local develPackageName="${portName}_devel-$portFullVersion"
|
||||
local packageLinksDir=$(dirname $portPackageLinksDir)
|
||||
local ffiLinksDir="$packageLinksDir/${develPackageName}/devel~libffi$secondaryArchSuffix/$relativeDevelopLibDir"
|
||||
sed -i -e "s,^\(Libs.private.*\)-L.* \(-l.*\)$,\1-L$ffiLinksDir \2," \
|
||||
$developLibDir/pkgconfig/gobject-2.0.pc
|
||||
local zlibLinksDir="$packageLinksDir/${develPackageName}/devel~libz$secondaryArchSuffix/$relativeDevelopLibDir"
|
||||
sed -i -e "s,^\(Libs.private.*\)-L.* \(-l.*\)$,\1-L$zlibLinksDir \2," \
|
||||
$developLibDir/pkgconfig/gio-2.0.pc
|
||||
|
||||
|
||||
# move the glibconfig header into devel as well
|
||||
mv $libDir/glib-2.0 $developLibDir
|
||||
|
||||
fixPkgconfig
|
||||
|
||||
# devel package
|
||||
packageEntries devel \
|
||||
$developDir
|
||||
|
||||
rm $libDir/charset.alias
|
||||
}
|
||||
@@ -1,163 +0,0 @@
|
||||
SUMMARY="GLib is a cross-platform software utility library"
|
||||
DESCRIPTION="GLib is a cross-platform software utility library that began as \
|
||||
part of the GTK+ project. However, before releasing version 2 of GTK+, the \
|
||||
project's developers decided to separate non-GUI-specific code from the GTK+ \
|
||||
platform, thus creating GLib as a separate product. GLib was released as a \
|
||||
separate library so other developers, those who did not make use of the \
|
||||
GUI-related portions of GTK+, could make use of the non-GUI portions of the \
|
||||
library without the overhead of depending on the entire GUI library.
|
||||
Since GLib is a cross-platform library, applications using it to interface \
|
||||
with the operating system are usually portable across different operating \
|
||||
systems without major changes
|
||||
"
|
||||
HOMEPAGE="https://www.gtk.org/"
|
||||
COPYRIGHT="1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
|
||||
1991-2003 Free Software Foundation, Inc.
|
||||
1997-2006 University of Cambridge.
|
||||
1998-2001, 2003-2010 Red Hat, Inc.
|
||||
2007-2009 Nokia Corporation
|
||||
2008, 2010 Oracle and/or its affiliates, Inc. All rights
|
||||
2008-2010 Codethink Limited
|
||||
2008-2010 Collabora Ltd.
|
||||
1995-2010 Several others"
|
||||
LICENSE="GNU LGPL v2"
|
||||
REVISION="5"
|
||||
SOURCE_URI="https://gitlab.gnome.org/GNOME/glib/-/archive/$portVersion/glib-$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="e2aa0eb516f5e001c5346b18e5722a6d43635a520f2bebeebb7aa2ecebcd76b2"
|
||||
SOURCE_DIR="glib-$portVersion"
|
||||
PATCHES="glib2-$portVersion.patchset"
|
||||
|
||||
ARCHITECTURES="all"
|
||||
SECONDARY_ARCHITECTURES="?x86_gcc2 x86"
|
||||
|
||||
PROVIDES="
|
||||
glib2$secondaryArchSuffix = $portVersion compat >= 2
|
||||
cmd:gapplication$secondaryArchSuffix
|
||||
cmd:gdbus$secondaryArchSuffix
|
||||
cmd:gdbus_codegen$secondaryArchSuffix
|
||||
cmd:gio$secondaryArchSuffix
|
||||
cmd:gio_querymodules$secondaryArchSuffix
|
||||
cmd:glib_compile_resources$secondaryArchSuffix
|
||||
cmd:glib_compile_schemas$secondaryArchSuffix
|
||||
cmd:gresource$secondaryArchSuffix
|
||||
cmd:gsettings$secondaryArchSuffix
|
||||
lib:libgio_2.0$secondaryArchSuffix = 0.5305.0 compat >= 0
|
||||
lib:libglib_2.0$secondaryArchSuffix = 0.5305.0 compat >= 0
|
||||
lib:libgmodule_2.0$secondaryArchSuffix = 0.5305.0 compat >= 0
|
||||
lib:libgobject_2.0$secondaryArchSuffix = 0.5305.0 compat >= 0
|
||||
lib:libgthread_2.0$secondaryArchSuffix = 0.5305.0 compat >= 0
|
||||
"
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
gettext$secondaryArchSuffix
|
||||
lib:libffi$secondaryArchSuffix
|
||||
lib:libiconv$secondaryArchSuffix
|
||||
lib:libintl$secondaryArchSuffix
|
||||
lib:libpcre$secondaryArchSuffix >= 1
|
||||
lib:libz$secondaryArchSuffix
|
||||
"
|
||||
|
||||
PROVIDES_devel="
|
||||
glib2${secondaryArchSuffix}_devel = $portVersion compat >= 0
|
||||
cmd:glib_genmarshal$secondaryArchSuffix
|
||||
cmd:glib_gettextize$secondaryArchSuffix
|
||||
cmd:glib_mkenums$secondaryArchSuffix
|
||||
cmd:gobject_query$secondaryArchSuffix
|
||||
cmd:gtester$secondaryArchSuffix
|
||||
cmd:gtester_report$secondaryArchSuffix
|
||||
devel:libgio_2.0$secondaryArchSuffix = 0.5305.0 compat >= 0
|
||||
devel:libglib_2.0$secondaryArchSuffix = 0.5305.0 compat >= 0
|
||||
devel:libgmodule_2.0$secondaryArchSuffix = 0.5305.0 compat >= 0
|
||||
devel:libgobject_2.0$secondaryArchSuffix = 0.5305.0 compat >= 0
|
||||
devel:libgthread_2.0$secondaryArchSuffix = 0.5305.0 compat >= 0
|
||||
"
|
||||
REQUIRES_devel="
|
||||
glib2$secondaryArchSuffix == $portVersion base
|
||||
haiku$secondaryArchSuffix
|
||||
cmd:perl
|
||||
devel:libffi$secondaryArchSuffix
|
||||
devel:libiconv$secondaryArchSuffix
|
||||
devel:libintl$secondaryArchSuffix
|
||||
devel:libpcre$secondaryArchSuffix
|
||||
devel:libz$secondaryArchSuffix
|
||||
lib:libffi$secondaryArchSuffix
|
||||
lib:libiconv$secondaryArchSuffix
|
||||
lib:libintl$secondaryArchSuffix
|
||||
lib:libpcre$secondaryArchSuffix
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
devel:libffi$secondaryArchSuffix
|
||||
devel:libiconv$secondaryArchSuffix
|
||||
devel:libintl$secondaryArchSuffix
|
||||
devel:libpcre$secondaryArchSuffix >= 1
|
||||
devel:libz$secondaryArchSuffix
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:aclocal
|
||||
cmd:autoconf
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:ld$secondaryArchSuffix
|
||||
cmd:libtoolize$secondaryArchSuffix
|
||||
cmd:make
|
||||
cmd:pkg_config$secondaryArchSuffix
|
||||
cmd:python
|
||||
cmd:which
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
runConfigure ./autogen.sh CFLAGS=-D_BSD_SOURCE
|
||||
|
||||
# There seem to be a problem with libtool, and without this some libraries
|
||||
# would not be found during the build.
|
||||
mkdir -p gobject/.libs gio/.libs
|
||||
ln -sf ../../glib/.libs gobject/.libs/lib
|
||||
|
||||
make $jobArgs
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
make install
|
||||
|
||||
# remove libtool library files
|
||||
rm $libDir/lib*.la
|
||||
|
||||
prepareInstalledDevelLibs libgio-2.0 \
|
||||
libglib-2.0 \
|
||||
libgmodule-2.0 \
|
||||
libgobject-2.0 \
|
||||
libgthread-2.0
|
||||
fixPkgconfig
|
||||
|
||||
# The libtool files reference other libraries using the wrong paths, which
|
||||
# creates a lot of confusion. Fix them so correct paths are used.
|
||||
local develPackageName="${portName}_devel-$portFullVersion"
|
||||
local packageLinksDir=$(dirname $portPackageLinksDir)
|
||||
local ffiLinksDir="$packageLinksDir/${develPackageName}/devel~libffi$secondaryArchSuffix/$relativeDevelopLibDir"
|
||||
sed -i -e "s,^\(Libs.private.*\)-L.* \(-l.*\)$,\1-L$ffiLinksDir \2," \
|
||||
$developLibDir/pkgconfig/gobject-2.0.pc
|
||||
local zlibLinksDir="$packageLinksDir/${develPackageName}/devel~libz$secondaryArchSuffix/$relativeDevelopLibDir"
|
||||
sed -i -e "s,^\(Libs.private.*\)-L.* \(-l.*\)$,\1-L$zlibLinksDir \2," \
|
||||
$developLibDir/pkgconfig/gio-2.0.pc
|
||||
|
||||
|
||||
# move the glibconfig header into devel as well
|
||||
mv $libDir/glib-2.0 $developLibDir
|
||||
|
||||
fixPkgconfig
|
||||
|
||||
# devel package
|
||||
packageEntries devel \
|
||||
$developDir \
|
||||
$binDir/glib-genmarshal \
|
||||
$binDir/glib-gettextize \
|
||||
$binDir/glib-mkenums \
|
||||
$binDir/gobject-query \
|
||||
$binDir/gtester \
|
||||
$binDir/gtester-report
|
||||
|
||||
rm $libDir/charset.alias
|
||||
}
|
||||
@@ -1,185 +0,0 @@
|
||||
SUMMARY="GLib is a cross-platform software utility library"
|
||||
DESCRIPTION="GLib is a cross-platform software utility library that began as \
|
||||
part of the GTK+ project. However, before releasing version 2 of GTK+, the \
|
||||
project's developers decided to separate non-GUI-specific code from the GTK+ \
|
||||
platform, thus creating GLib as a separate product. GLib was released as a \
|
||||
separate library so other developers, those who did not make use of the \
|
||||
GUI-related portions of GTK+, could make use of the non-GUI portions of the \
|
||||
library without the overhead of depending on the entire GUI library.
|
||||
Since GLib is a cross-platform library, applications using it to interface \
|
||||
with the operating system are usually portable across different operating \
|
||||
systems without major changes."
|
||||
HOMEPAGE="https://www.gtk.org/"
|
||||
COPYRIGHT="1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
|
||||
1991-2003 Free Software Foundation, Inc.
|
||||
1997-2006 University of Cambridge.
|
||||
1998-2001, 2003-2010 Red Hat, Inc.
|
||||
2007-2009 Nokia Corporation
|
||||
2008, 2010 Oracle and/or its affiliates, Inc. All rights
|
||||
2008-2010 Codethink Limited
|
||||
2008-2010 Collabora Ltd.
|
||||
1995-2010 Several others"
|
||||
LICENSE="GNU LGPL v2"
|
||||
REVISION="1"
|
||||
SOURCE_URI="https://gitlab.gnome.org/GNOME/glib/-/archive/$portVersion/glib-$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="7c012389e76ad96671b22fd0f95fd8f5308d6e543fe843a1ce05edfce6335b10"
|
||||
SOURCE_DIR="glib-$portVersion"
|
||||
PATCHES="glib2-$portVersion.patchset"
|
||||
|
||||
ARCHITECTURES="all ?x86_gcc2 ?x86"
|
||||
SECONDARY_ARCHITECTURES="?x86"
|
||||
|
||||
libVersion="0.5400.3"
|
||||
libVersionCompat="$libVersion compat >= ${libVersion%%.*}"
|
||||
|
||||
PROVIDES="
|
||||
glib2$secondaryArchSuffix = $portVersion
|
||||
cmd:gapplication$secondaryArchSuffix
|
||||
cmd:gdbus$secondaryArchSuffix
|
||||
cmd:gdbus_codegen$secondaryArchSuffix
|
||||
cmd:gio$secondaryArchSuffix
|
||||
cmd:gio_querymodules$secondaryArchSuffix
|
||||
cmd:glib_compile_resources$secondaryArchSuffix
|
||||
cmd:glib_compile_schemas$secondaryArchSuffix
|
||||
cmd:gresource$secondaryArchSuffix
|
||||
cmd:gsettings$secondaryArchSuffix
|
||||
lib:libgio_2.0$secondaryArchSuffix = $libVersionCompat
|
||||
lib:libglib_2.0$secondaryArchSuffix = $libVersionCompat
|
||||
lib:libgmodule_2.0$secondaryArchSuffix = $libVersionCompat
|
||||
lib:libgobject_2.0$secondaryArchSuffix = $libVersionCompat
|
||||
lib:libgthread_2.0$secondaryArchSuffix = $libVersionCompat
|
||||
"
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
gettext$secondaryArchSuffix
|
||||
lib:libffi$secondaryArchSuffix
|
||||
lib:libiconv$secondaryArchSuffix
|
||||
lib:libintl$secondaryArchSuffix
|
||||
lib:libpcre$secondaryArchSuffix >= 1
|
||||
lib:libz$secondaryArchSuffix
|
||||
"
|
||||
|
||||
PROVIDES_devel="
|
||||
glib2${secondaryArchSuffix}_devel = $portVersion compat >= 0
|
||||
cmd:glib_genmarshal$secondaryArchSuffix
|
||||
cmd:glib_gettextize$secondaryArchSuffix
|
||||
cmd:glib_mkenums$secondaryArchSuffix
|
||||
cmd:gobject_query$secondaryArchSuffix
|
||||
cmd:gtester$secondaryArchSuffix
|
||||
cmd:gtester_report$secondaryArchSuffix
|
||||
devel:libgio_2.0$secondaryArchSuffix = $libVersionCompat
|
||||
devel:libglib_2.0$secondaryArchSuffix = $libVersionCompat
|
||||
devel:libgmodule_2.0$secondaryArchSuffix = $libVersionCompat
|
||||
devel:libgobject_2.0$secondaryArchSuffix = $libVersionCompat
|
||||
devel:libgthread_2.0$secondaryArchSuffix = $libVersionCompat
|
||||
"
|
||||
REQUIRES_devel="
|
||||
glib2$secondaryArchSuffix == $portVersion base
|
||||
haiku$secondaryArchSuffix
|
||||
cmd:perl
|
||||
devel:libffi$secondaryArchSuffix
|
||||
devel:libiconv$secondaryArchSuffix
|
||||
devel:libintl$secondaryArchSuffix
|
||||
devel:libpcre$secondaryArchSuffix
|
||||
devel:libz$secondaryArchSuffix
|
||||
lib:libffi$secondaryArchSuffix
|
||||
lib:libiconv$secondaryArchSuffix
|
||||
lib:libintl$secondaryArchSuffix
|
||||
lib:libpcre$secondaryArchSuffix
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
devel:libffi$secondaryArchSuffix
|
||||
devel:libiconv$secondaryArchSuffix
|
||||
devel:libintl$secondaryArchSuffix
|
||||
devel:libpcre$secondaryArchSuffix >= 1
|
||||
devel:libz$secondaryArchSuffix
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:aclocal
|
||||
cmd:autoconf
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:ld$secondaryArchSuffix
|
||||
cmd:libtoolize$secondaryArchSuffix
|
||||
cmd:make
|
||||
cmd:pkg_config$secondaryArchSuffix
|
||||
cmd:python
|
||||
cmd:which
|
||||
"
|
||||
|
||||
defineDebugInfoPackage glib2$secondaryArchSuffix \
|
||||
$binDir/gapplication \
|
||||
$binDir/gdbus \
|
||||
$binDir/gio \
|
||||
$binDir/gio-querymodules \
|
||||
$binDir/glib-compile-resources \
|
||||
$binDir/glib-compile-schemas \
|
||||
$binDir/gresource \
|
||||
$binDir/gsettings \
|
||||
$libDir/libgio-2.0.so.$libVersion \
|
||||
$libDir/libglib-2.0.so.$libVersion \
|
||||
$libDir/libgmodule-2.0.so.$libVersion \
|
||||
$libDir/libgobject-2.0.so.$libVersion \
|
||||
$libDir/libgthread-2.0.so.$libVersion
|
||||
|
||||
BUILD()
|
||||
{
|
||||
runConfigure ./autogen.sh CFLAGS=-D_BSD_SOURCE
|
||||
|
||||
# There seem to be a problem with libtool, and without this some libraries
|
||||
# would not be found during the build.
|
||||
mkdir -p gobject/.libs gio/.libs
|
||||
ln -sf ../../glib/.libs gobject/.libs/lib
|
||||
|
||||
make $jobArgs
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
make install
|
||||
|
||||
# remove libtool library files
|
||||
rm $libDir/lib*.la
|
||||
|
||||
prepareInstalledDevelLibs libgio-2.0 \
|
||||
libglib-2.0 \
|
||||
libgmodule-2.0 \
|
||||
libgobject-2.0 \
|
||||
libgthread-2.0
|
||||
fixPkgconfig
|
||||
|
||||
# The libtool files reference other libraries using the wrong paths, which
|
||||
# creates a lot of confusion. Fix them so correct paths are used.
|
||||
local develPackageName="${portName}_devel-$portFullVersion"
|
||||
local packageLinksDir=$(dirname $portPackageLinksDir)
|
||||
local ffiLinksDir="$packageLinksDir/${develPackageName}/devel~libffi$secondaryArchSuffix/$relativeDevelopLibDir"
|
||||
sed -i -e "s,^\(Libs.private.*\)-L.* \(-l.*\)$,\1-L$ffiLinksDir \2," \
|
||||
$developLibDir/pkgconfig/gobject-2.0.pc
|
||||
local zlibLinksDir="$packageLinksDir/${develPackageName}/devel~libz$secondaryArchSuffix/$relativeDevelopLibDir"
|
||||
sed -i -e "s,^\(Libs.private.*\)-L.* \(-l.*\)$,\1-L$zlibLinksDir \2," \
|
||||
$developLibDir/pkgconfig/gio-2.0.pc
|
||||
|
||||
|
||||
# move the glibconfig header into devel as well
|
||||
mv $libDir/glib-2.0 $developLibDir
|
||||
|
||||
fixPkgconfig
|
||||
|
||||
# devel package
|
||||
packageEntries devel \
|
||||
$developDir \
|
||||
$binDir/glib-genmarshal \
|
||||
$binDir/glib-gettextize \
|
||||
$binDir/glib-mkenums \
|
||||
$binDir/gobject-query \
|
||||
$binDir/gtester \
|
||||
$binDir/gtester-report
|
||||
|
||||
rm $libDir/charset.alias
|
||||
}
|
||||
|
||||
TEST()
|
||||
{
|
||||
make check
|
||||
}
|
||||
@@ -1,169 +0,0 @@
|
||||
SUMMARY="GLib is a cross-platform software utility library"
|
||||
DESCRIPTION="GLib is a cross-platform software utility library that began as \
|
||||
part of the GTK+ project. However, before releasing version 2 of GTK+, the \
|
||||
project's developers decided to separate non-GUI-specific code from the GTK+ \
|
||||
platform, thus creating GLib as a separate product. GLib was released as a \
|
||||
separate library so other developers, those who did not make use of the \
|
||||
GUI-related portions of GTK+, could make use of the non-GUI portions of the \
|
||||
library without the overhead of depending on the entire GUI library.
|
||||
Since GLib is a cross-platform library, applications using it to interface \
|
||||
with the operating system are usually portable across different operating \
|
||||
systems without major changes."
|
||||
HOMEPAGE="https://www.gtk.org/"
|
||||
COPYRIGHT="1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
|
||||
1991-2003 Free Software Foundation, Inc.
|
||||
1997-2006 University of Cambridge.
|
||||
1998-2001, 2003-2010 Red Hat, Inc.
|
||||
2007-2009 Nokia Corporation
|
||||
2008, 2010 Oracle and/or its affiliates, Inc. All rights
|
||||
2008-2010 Codethink Limited
|
||||
2008-2010 Collabora Ltd.
|
||||
1995-2010 Several others"
|
||||
LICENSE="GNU LGPL v2"
|
||||
REVISION="6"
|
||||
SOURCE_URI="https://gitlab.gnome.org/GNOME/glib/-/archive/$portVersion/glib-$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="226f44a6fe121d4367d5c2458a363054d6076a9e70cf2ec5b948b6c028a08688"
|
||||
SOURCE_DIR="glib-$portVersion"
|
||||
PATCHES="glib2-$portVersion.patchset"
|
||||
|
||||
ARCHITECTURES="all ?x86_gcc2 ?x86"
|
||||
SECONDARY_ARCHITECTURES="x86"
|
||||
|
||||
libVersion="0.6200.0"
|
||||
libVersionCompat="$libVersion compat >= ${libVersion%%.*}"
|
||||
|
||||
PROVIDES="
|
||||
glib2$secondaryArchSuffix = $portVersion
|
||||
cmd:gapplication$secondaryArchSuffix
|
||||
cmd:gdbus$secondaryArchSuffix
|
||||
cmd:gdbus_codegen$secondaryArchSuffix
|
||||
cmd:gio$secondaryArchSuffix
|
||||
cmd:gio_launch_desktop$secondaryArchSuffix
|
||||
cmd:gio_querymodules$secondaryArchSuffix
|
||||
cmd:glib_compile_resources$secondaryArchSuffix
|
||||
cmd:glib_compile_schemas$secondaryArchSuffix
|
||||
cmd:gresource$secondaryArchSuffix
|
||||
cmd:gsettings$secondaryArchSuffix
|
||||
lib:libgio_2.0$secondaryArchSuffix = $libVersionCompat
|
||||
lib:libglib_2.0$secondaryArchSuffix = $libVersionCompat
|
||||
lib:libgmodule_2.0$secondaryArchSuffix = $libVersionCompat
|
||||
lib:libgobject_2.0$secondaryArchSuffix = $libVersionCompat
|
||||
lib:libgthread_2.0$secondaryArchSuffix = $libVersionCompat
|
||||
"
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
gettext$secondaryArchSuffix
|
||||
lib:libffi$secondaryArchSuffix
|
||||
lib:libiconv$secondaryArchSuffix
|
||||
lib:libintl$secondaryArchSuffix
|
||||
lib:libpcre$secondaryArchSuffix >= 1
|
||||
lib:libz$secondaryArchSuffix
|
||||
"
|
||||
|
||||
PROVIDES_devel="
|
||||
glib2${secondaryArchSuffix}_devel = $portVersion compat >= 0
|
||||
cmd:glib_genmarshal$secondaryArchSuffix
|
||||
cmd:glib_gettextize$secondaryArchSuffix
|
||||
cmd:glib_mkenums$secondaryArchSuffix
|
||||
cmd:gobject_query$secondaryArchSuffix
|
||||
cmd:gtester$secondaryArchSuffix
|
||||
cmd:gtester_report$secondaryArchSuffix
|
||||
devel:libgio_2.0$secondaryArchSuffix = $libVersionCompat
|
||||
devel:libglib_2.0$secondaryArchSuffix = $libVersionCompat
|
||||
devel:libgmodule_2.0$secondaryArchSuffix = $libVersionCompat
|
||||
devel:libgobject_2.0$secondaryArchSuffix = $libVersionCompat
|
||||
devel:libgthread_2.0$secondaryArchSuffix = $libVersionCompat
|
||||
"
|
||||
REQUIRES_devel="
|
||||
glib2$secondaryArchSuffix == $portVersion base
|
||||
haiku$secondaryArchSuffix
|
||||
cmd:perl
|
||||
cmd:python3
|
||||
devel:libffi$secondaryArchSuffix
|
||||
devel:libiconv$secondaryArchSuffix
|
||||
devel:libintl$secondaryArchSuffix
|
||||
devel:libpcre$secondaryArchSuffix
|
||||
devel:libz$secondaryArchSuffix
|
||||
lib:libffi$secondaryArchSuffix
|
||||
lib:libiconv$secondaryArchSuffix
|
||||
lib:libintl$secondaryArchSuffix
|
||||
lib:libpcre$secondaryArchSuffix
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
# devel:libdbus_1$secondaryArchSuffix
|
||||
# devel:libelf$secondaryArchSuffix
|
||||
devel:libffi$secondaryArchSuffix
|
||||
devel:libiconv$secondaryArchSuffix
|
||||
devel:libintl$secondaryArchSuffix
|
||||
devel:libpcre$secondaryArchSuffix >= 1
|
||||
devel:libz$secondaryArchSuffix
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:ld$secondaryArchSuffix
|
||||
cmd:make
|
||||
cmd:meson
|
||||
cmd:python3
|
||||
cmd:pkg_config$secondaryArchSuffix
|
||||
"
|
||||
|
||||
defineDebugInfoPackage glib2$secondaryArchSuffix \
|
||||
$binDir/gapplication \
|
||||
$binDir/gdbus \
|
||||
$binDir/gio \
|
||||
$binDir/gio-querymodules \
|
||||
$binDir/glib-compile-resources \
|
||||
$binDir/glib-compile-schemas \
|
||||
$binDir/gresource \
|
||||
$binDir/gsettings \
|
||||
$libDir/libgio-2.0.so.$libVersion \
|
||||
$libDir/libglib-2.0.so.$libVersion \
|
||||
$libDir/libgmodule-2.0.so.$libVersion \
|
||||
$libDir/libgobject-2.0.so.$libVersion \
|
||||
$libDir/libgthread-2.0.so.$libVersion
|
||||
|
||||
BUILD()
|
||||
{
|
||||
CFLAGS="-D_BSD_SOURCE" \
|
||||
LDFLAGS="-lbsd -lgnu -lnetwork" meson build \
|
||||
-Diconv=external --prefix=$prefix --includedir=$includeDir \
|
||||
--libdir=$libDir --datadir=$dataDir --bindir=$binDir \
|
||||
--localedir=$dataDir/locale
|
||||
|
||||
ninja $jobArgs -C build
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
ninja -C build install
|
||||
|
||||
prepareInstalledDevelLibs libgio-2.0 \
|
||||
libglib-2.0 \
|
||||
libgmodule-2.0 \
|
||||
libgobject-2.0 \
|
||||
libgthread-2.0
|
||||
|
||||
# move the glibconfig header into devel as well
|
||||
mv $libDir/glib-2.0 $developLibDir
|
||||
|
||||
fixPkgconfig
|
||||
|
||||
# devel package
|
||||
packageEntries devel \
|
||||
$developDir \
|
||||
$binDir/glib-genmarshal \
|
||||
$binDir/glib-gettextize \
|
||||
$binDir/glib-mkenums \
|
||||
$binDir/gobject-query \
|
||||
$binDir/gtester \
|
||||
$binDir/gtester-report
|
||||
|
||||
rm -rf $prefix/libexec
|
||||
}
|
||||
|
||||
TEST()
|
||||
{
|
||||
meson test -C build
|
||||
}
|
||||
@@ -1,207 +0,0 @@
|
||||
From 7f42c71278a86fc337169f469746dd0ebe2d22d3 Mon Sep 17 00:00:00 2001
|
||||
From: Chris Roberts <cpr420@gmail.com>
|
||||
Date: Mon, 9 Dec 2013 16:58:10 -0700
|
||||
Subject: [PATCH 1/2] Attempt to bring glib-1 into the modern age
|
||||
|
||||
---
|
||||
Makefile.am | 2 +-
|
||||
acinclude.m4 | 12 ++++++++++++
|
||||
configure.in | 12 ++++++------
|
||||
gmodule/Makefile.am | 2 +-
|
||||
gstrfuncs.c | 15 +++++----------
|
||||
5 files changed, 25 insertions(+), 18 deletions(-)
|
||||
|
||||
diff --git a/Makefile.am b/Makefile.am
|
||||
index 3a6e201..f059565 100644
|
||||
--- a/Makefile.am
|
||||
+++ b/Makefile.am
|
||||
@@ -70,7 +70,7 @@ configinclude_DATA = \
|
||||
|
||||
CONFIGURE_DEPENDENCIES = acglib.m4
|
||||
|
||||
-BUILT_SOURCES = stamp-gc-h #note: not glibconfig.h
|
||||
+BUILT_SOURCES += stamp-gc-h #note: not glibconfig.h
|
||||
glibconfig.h: stamp-gc-h
|
||||
@:
|
||||
stamp-gc-h: config.status
|
||||
diff --git a/acinclude.m4 b/acinclude.m4
|
||||
index 47abe43..43ed3f1 100644
|
||||
--- a/acinclude.m4
|
||||
+++ b/acinclude.m4
|
||||
@@ -21,6 +21,18 @@
|
||||
## configuration script generated by Autoconf, you may include it under
|
||||
## the same distribution terms that you use for the rest of that program.
|
||||
|
||||
+# GLIB_AC_DIVERT_BEFORE_HELP(STUFF)
|
||||
+# ---------------------------------
|
||||
+# Put STUFF early enough so that they are available for $ac_help expansion.
|
||||
+# Handle both classic (<= v2.13) and modern autoconf
|
||||
+AC_DEFUN([GLIB_AC_DIVERT_BEFORE_HELP],
|
||||
+[ifdef([m4_divert_text], [m4_divert_text([NOTICE],[$1])],
|
||||
+ [ifdef([AC_DIVERT], [AC_DIVERT([NOTICE],[$1])],
|
||||
+ [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)dnl
|
||||
+$1
|
||||
+AC_DIVERT_POP()])])])
|
||||
+
|
||||
+
|
||||
# serial 40 AC_PROG_LIBTOOL
|
||||
AC_DEFUN(AC_PROG_LIBTOOL,
|
||||
[AC_REQUIRE([AC_LIBTOOL_SETUP])dnl
|
||||
diff --git a/configure.in b/configure.in
|
||||
index 8ee9339..cad722f 100644
|
||||
--- a/configure.in
|
||||
+++ b/configure.in
|
||||
@@ -17,7 +17,7 @@ rm -f glibconfig-sysdefs.h
|
||||
|
||||
dnl we need to AC_DIVERT_PUSH/AC_DIVERT_POP these variable definitions so they
|
||||
dnl are available for $ac_help expansion (don't we all *love* autoconf?)
|
||||
-AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)dnl
|
||||
+GLIB_AC_DIVERT_BEFORE_HELP([
|
||||
#
|
||||
# The following version number definitions apply to GLib, GModule and GThread
|
||||
# as a whole, so if changes occoured in any of them, they are all
|
||||
@@ -38,7 +38,7 @@ GLIB_INTERFACE_AGE=10
|
||||
GLIB_BINARY_AGE=10
|
||||
GLIB_VERSION=$GLIB_MAJOR_VERSION.$GLIB_MINOR_VERSION.$GLIB_MICRO_VERSION
|
||||
dnl
|
||||
-AC_DIVERT_POP()dnl
|
||||
+])
|
||||
|
||||
AC_SUBST(GLIB_MAJOR_VERSION)
|
||||
AC_SUBST(GLIB_MINOR_VERSION)
|
||||
@@ -63,7 +63,7 @@ PACKAGE=glib
|
||||
AM_INIT_AUTOMAKE($PACKAGE, $VERSION, no-define)
|
||||
|
||||
# Specify a configuration file
|
||||
-AM_CONFIG_HEADER(config.h)
|
||||
+AC_CONFIG_HEADERS(config.h)
|
||||
|
||||
AC_DEFINE_UNQUOTED(GLIB_MAJOR_VERSION, $GLIB_MAJOR_VERSION)
|
||||
AC_DEFINE_UNQUOTED(GLIB_MINOR_VERSION, $GLIB_MINOR_VERSION)
|
||||
@@ -71,6 +71,7 @@ AC_DEFINE_UNQUOTED(GLIB_MICRO_VERSION, $GLIB_MICRO_VERSION)
|
||||
AC_DEFINE_UNQUOTED(GLIB_INTERFACE_AGE, $GLIB_INTERFACE_AGE)
|
||||
AC_DEFINE_UNQUOTED(GLIB_BINARY_AGE, $GLIB_BINARY_AGE)
|
||||
|
||||
+AC_CANONICAL_SYSTEM
|
||||
dnl Initialize libtool
|
||||
AM_PROG_LIBTOOL
|
||||
|
||||
@@ -81,13 +82,13 @@ AC_CANONICAL_HOST
|
||||
|
||||
dnl figure debugging default, prior to $ac_help setup
|
||||
dnl
|
||||
-AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)dnl
|
||||
+GLIB_AC_DIVERT_BEFORE_HELP([
|
||||
if test `expr $GLIB_MINOR_VERSION \% 2` = 1 ; then
|
||||
debug_default=yes
|
||||
else
|
||||
debug_default=minimum
|
||||
fi
|
||||
-AC_DIVERT_POP()dnl
|
||||
+])
|
||||
|
||||
dnl declare --enable-* args and collect ac_help strings
|
||||
AC_ARG_ENABLE(debug, [ --enable-debug=[no/minimum/yes] turn on debugging [default=$debug_default]],,enable_debug=$debug_default)
|
||||
@@ -154,7 +155,6 @@ AC_DEFINE_UNQUOTED(G_COMPILED_WITH_DEBUGGING, "${enable_debug}")
|
||||
|
||||
# Checks for programs.
|
||||
AC_PROG_CC
|
||||
-AM_PROG_CC_STDC
|
||||
AC_PROG_INSTALL
|
||||
|
||||
changequote(,)dnl
|
||||
diff --git a/gmodule/Makefile.am b/gmodule/Makefile.am
|
||||
index ff4410a..5f0ce56 100644
|
||||
--- a/gmodule/Makefile.am
|
||||
+++ b/gmodule/Makefile.am
|
||||
@@ -42,7 +42,7 @@ libgplugin_b_la_LDFLAGS = @G_MODULE_LDFLAGS@ -avoid-version -module
|
||||
libgplugin_b_la_LIBADD = @G_MODULE_LIBS@ # $(libglib)
|
||||
|
||||
noinst_PROGRAMS = testgmodule
|
||||
-testgmodule_LDFLAGS += @G_MODULE_LDFLAGS@
|
||||
+testgmodule_LDFLAGS = @G_MODULE_LDFLAGS@
|
||||
testgmodule_LDADD = libgmodule.la $(libglib) @G_MODULE_LIBS@
|
||||
|
||||
.PHONY: files release
|
||||
diff --git a/gstrfuncs.c b/gstrfuncs.c
|
||||
index feb4572..f3859b4 100644
|
||||
--- a/gstrfuncs.c
|
||||
+++ b/gstrfuncs.c
|
||||
@@ -702,7 +702,7 @@ g_strsignal (gint signum)
|
||||
char *msg;
|
||||
|
||||
#ifdef HAVE_STRSIGNAL
|
||||
- extern char *strsignal (int sig);
|
||||
+ extern const char *strsignal (int sig);
|
||||
return strsignal (signum);
|
||||
#elif NO_SYS_SIGLIST
|
||||
switch (signum)
|
||||
@@ -867,8 +867,7 @@ g_printf_string_upper_bound (const gchar* format,
|
||||
/* beware of positional parameters
|
||||
*/
|
||||
case '$':
|
||||
- g_warning (G_GNUC_PRETTY_FUNCTION
|
||||
- "(): unable to handle positional parameters (%%n$)");
|
||||
+ g_warning ("%s(): unable to handle positional parameters (%%n$)", G_GNUC_PRETTY_FUNCTION);
|
||||
len += 1024; /* try adding some safety padding */
|
||||
break;
|
||||
|
||||
@@ -1034,8 +1033,7 @@ g_printf_string_upper_bound (const gchar* format,
|
||||
/* n . dddddddddddddddddddddddd E +- eeee */
|
||||
conv_len += 1 + 1 + MAX (24, spec.precision) + 1 + 1 + 4;
|
||||
if (spec.mod_extra_long)
|
||||
- g_warning (G_GNUC_PRETTY_FUNCTION
|
||||
- "(): unable to handle long double, collecting double only");
|
||||
+ g_warning ("%s(): unable to handle long double, collecting double only", G_GNUC_PRETTY_FUNCTION);
|
||||
#ifdef HAVE_LONG_DOUBLE
|
||||
#error need to implement special handling for long double
|
||||
#endif
|
||||
@@ -1077,8 +1075,7 @@ g_printf_string_upper_bound (const gchar* format,
|
||||
conv_done = TRUE;
|
||||
if (spec.mod_long)
|
||||
{
|
||||
- g_warning (G_GNUC_PRETTY_FUNCTION
|
||||
- "(): unable to handle wide char strings");
|
||||
+ g_warning ("%s(): unable to handle wide char strings", G_GNUC_PRETTY_FUNCTION);
|
||||
len += 1024; /* try adding some safety padding */
|
||||
}
|
||||
break;
|
||||
@@ -1108,9 +1105,7 @@ g_printf_string_upper_bound (const gchar* format,
|
||||
conv_len += format - spec_start;
|
||||
break;
|
||||
default:
|
||||
- g_warning (G_GNUC_PRETTY_FUNCTION
|
||||
- "(): unable to handle `%c' while parsing format",
|
||||
- c);
|
||||
+ g_warning ("%s(): unable to handle `%c' while parsing format", G_GNUC_PRETTY_FUNCTION, c);
|
||||
break;
|
||||
}
|
||||
conv_done |= conv_len > 0;
|
||||
--
|
||||
2.7.4
|
||||
|
||||
From cb3f993649d892e9015e7ff7e928f33a1faa531c Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Duval?= <jerome.duval@gmail.com>
|
||||
Date: Fri, 2 Dec 2016 22:38:49 +0100
|
||||
Subject: [PATCH 2/2] fix gcc5 build
|
||||
|
||||
---
|
||||
glib.h | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/glib.h b/glib.h
|
||||
index b83cf5d..12e0195 100644
|
||||
--- a/glib.h
|
||||
+++ b/glib.h
|
||||
@@ -204,7 +204,7 @@ extern "C" {
|
||||
#ifndef G_INLINE_FUNC
|
||||
# ifdef __GNUC__
|
||||
# ifdef __OPTIMIZE__
|
||||
-# define G_INLINE_FUNC extern inline
|
||||
+# define G_INLINE_FUNC static inline
|
||||
# else
|
||||
# undef G_CAN_INLINE
|
||||
# define G_INLINE_FUNC extern
|
||||
--
|
||||
2.7.4
|
||||
|
||||
@@ -1,476 +0,0 @@
|
||||
From 1e9681c8659dd586e0ade5f29334ceee195c88e3 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Tue, 17 Jun 2014 19:57:08 +0000
|
||||
Subject: applying patch glib2-2.38.1.patch
|
||||
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index f0840d5..f7df259 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -122,6 +122,10 @@ case $host in
|
||||
*-*-beos*)
|
||||
glib_native_beos="yes"
|
||||
;;
|
||||
+ *-*-haiku*)
|
||||
+ glib_native_beos="yes"
|
||||
+ LIBS="-lnetwork $LIBS"
|
||||
+ ;;
|
||||
*)
|
||||
glib_native_beos="no"
|
||||
;;
|
||||
@@ -2062,8 +2066,8 @@ AS_IF([ test x"$have_threads" = xposix], [
|
||||
# One of them does for most gcc versions and some other platforms/compilers
|
||||
# too and could be considered as the canonical way to go.
|
||||
case $host in
|
||||
- *-*-cygwin*|*-*-darwin*)
|
||||
- # skip cygwin and darwin -pthread or -pthreads test
|
||||
+ *-*-cygwin*|*-*-darwin*|*-*-haiku*)
|
||||
+ # skip cygwin, darwin and haiku -pthread or -pthreads test
|
||||
;;
|
||||
*-solaris*)
|
||||
# These compiler/linker flags work with both Sun Studio and gcc
|
||||
@@ -2232,8 +2236,8 @@ if test "x$G_THREAD_LIBS" = xerror; then
|
||||
fi
|
||||
|
||||
case $host in
|
||||
- *-*-beos*)
|
||||
- G_THREAD_LIBS="-lbe -lroot -lglib-2.0 "
|
||||
+ *-*-beos*|*-*-haiku*)
|
||||
+ G_THREAD_LIBS="-lbe -lroot"
|
||||
G_THREAD_LIBS_EXTRA="-L\$(top_builddir_full)/.libs"
|
||||
;;
|
||||
*)
|
||||
@@ -3574,6 +3578,9 @@ case $host in
|
||||
*-*-beos*)
|
||||
glib_os="#define G_OS_BEOS"
|
||||
;;
|
||||
+ *-*-haiku*)
|
||||
+ glib_os="#define G_OS_HAIKU"
|
||||
+ ;;
|
||||
*-*-cygwin*)
|
||||
glib_os="#define G_OS_UNIX
|
||||
#define G_PLATFORM_WIN32
|
||||
diff --git a/gio/data-to-c.pl b/gio/data-to-c.pl
|
||||
index 20ba2fb..539b7e0 100755
|
||||
--- a/gio/data-to-c.pl
|
||||
+++ b/gio/data-to-c.pl
|
||||
@@ -1,4 +1,4 @@
|
||||
-#!/usr/bin/perl
|
||||
+#!/usr/bin/env perl
|
||||
|
||||
# Copyright © 2011 Red Hat, Inc
|
||||
#
|
||||
diff --git a/gio/gapplicationcommandline.c b/gio/gapplicationcommandline.c
|
||||
index 9a0840f..896a889 100644
|
||||
--- a/gio/gapplicationcommandline.c
|
||||
+++ b/gio/gapplicationcommandline.c
|
||||
@@ -29,7 +29,7 @@
|
||||
#include <string.h>
|
||||
#include <stdio.h>
|
||||
|
||||
-#ifdef G_OS_UNIX
|
||||
+#if defined(G_OS_UNIX) || defined(G_OS_HAIKU)
|
||||
#include "gunixinputstream.h"
|
||||
#endif
|
||||
|
||||
@@ -201,7 +201,7 @@ g_application_command_line_real_printerr_literal (GApplicationCommandLine *cmdli
|
||||
static GInputStream *
|
||||
g_application_command_line_real_get_stdin (GApplicationCommandLine *cmdline)
|
||||
{
|
||||
-#ifdef G_OS_UNIX
|
||||
+#if defined(G_OS_UNIX) || defined(G_OS_HAIKU)
|
||||
return g_unix_input_stream_new (0, FALSE);
|
||||
#else
|
||||
return g_win32_input_stream_new (GetStdHandle (STD_INPUT_HANDLE), FALSE);
|
||||
diff --git a/gio/gdbusauthmechanismsha1.c b/gio/gdbusauthmechanismsha1.c
|
||||
index e4f75eb..2c70803 100644
|
||||
--- a/gio/gdbusauthmechanismsha1.c
|
||||
+++ b/gio/gdbusauthmechanismsha1.c
|
||||
@@ -252,7 +252,7 @@ ensure_keyring_directory (GError **error)
|
||||
{
|
||||
if (g_getenv ("G_DBUS_COOKIE_SHA1_KEYRING_DIR_IGNORE_PERMISSION") == NULL)
|
||||
{
|
||||
-#ifdef G_OS_UNIX
|
||||
+#if defined(G_OS_UNIX) || defined(G_OS_HAIKU)
|
||||
struct stat statbuf;
|
||||
if (stat (path, &statbuf) != 0)
|
||||
{
|
||||
@@ -947,7 +947,7 @@ mechanism_server_initiate (GDBusAuthMechanism *mechanism,
|
||||
|
||||
if (initial_response != NULL && strlen (initial_response) > 0)
|
||||
{
|
||||
-#ifdef G_OS_UNIX
|
||||
+#if defined(G_OS_UNIX) || defined(G_OS_HAIKU)
|
||||
gint64 uid;
|
||||
gchar *endp;
|
||||
|
||||
@@ -1114,7 +1114,7 @@ mechanism_client_initiate (GDBusAuthMechanism *mechanism,
|
||||
|
||||
*out_initial_response_len = -1;
|
||||
|
||||
-#ifdef G_OS_UNIX
|
||||
+#if defined(G_OS_UNIX) || defined(G_OS_HAIKU)
|
||||
initial_response = g_strdup_printf ("%" G_GINT64_FORMAT, (gint64) getuid ());
|
||||
#elif defined (G_OS_WIN32)
|
||||
initial_response = _g_dbus_win32_get_user_sid ();
|
||||
diff --git a/gio/glocalfile.c b/gio/glocalfile.c
|
||||
index 345214d..11eae36 100644
|
||||
--- a/gio/glocalfile.c
|
||||
+++ b/gio/glocalfile.c
|
||||
@@ -27,7 +27,7 @@
|
||||
#include <string.h>
|
||||
#include <errno.h>
|
||||
#include <fcntl.h>
|
||||
-#if G_OS_UNIX
|
||||
+#if HAVE_DIRENT_H
|
||||
#include <dirent.h>
|
||||
#endif
|
||||
#ifdef HAVE_UNISTD_H
|
||||
@@ -67,7 +67,7 @@
|
||||
#include "gioerror.h"
|
||||
#include <glib/gstdio.h>
|
||||
#include "glibintl.h"
|
||||
-#ifdef G_OS_UNIX
|
||||
+#if defined(G_OS_UNIX) || defined(G_OS_HAIKU)
|
||||
#include "glib-unix.h"
|
||||
#endif
|
||||
#include "glib-private.h"
|
||||
@@ -1818,7 +1818,7 @@ _g_local_file_has_trash_dir (const char *dirname, dev_t dir_dev)
|
||||
return res;
|
||||
}
|
||||
|
||||
-#ifdef G_OS_UNIX
|
||||
+#if defined(G_OS_UNIX) || defined(G_OS_HAIKU)
|
||||
gboolean
|
||||
_g_local_file_is_lost_found_dir (const char *path, dev_t path_dev)
|
||||
{
|
||||
diff --git a/gio/glocalfileinfo.h b/gio/glocalfileinfo.h
|
||||
index 6d35be5..e286098 100644
|
||||
--- a/gio/glocalfileinfo.h
|
||||
+++ b/gio/glocalfileinfo.h
|
||||
@@ -58,7 +58,7 @@ typedef struct
|
||||
|
||||
gboolean _g_local_file_has_trash_dir (const char *dirname,
|
||||
dev_t dir_dev);
|
||||
-#ifdef G_OS_UNIX
|
||||
+#if defined(G_OS_UNIX) || defined(G_OS_HAIKU)
|
||||
gboolean _g_local_file_is_lost_found_dir (const char *path,
|
||||
dev_t path_dev);
|
||||
#endif
|
||||
diff --git a/gio/gsocket.c b/gio/gsocket.c
|
||||
index 18e6137..689d3c0 100644
|
||||
--- a/gio/gsocket.c
|
||||
+++ b/gio/gsocket.c
|
||||
@@ -29,7 +29,7 @@
|
||||
|
||||
#include "gsocket.h"
|
||||
|
||||
-#ifdef G_OS_UNIX
|
||||
+#if defined(G_OS_UNIX) || defined(G_OS_HAIKU)
|
||||
#include "glib-unix.h"
|
||||
#endif
|
||||
|
||||
diff --git a/gio/gthreadedresolver.c b/gio/gthreadedresolver.c
|
||||
index 1ffaf15..702cf00 100644
|
||||
--- a/gio/gthreadedresolver.c
|
||||
+++ b/gio/gthreadedresolver.c
|
||||
@@ -245,7 +245,7 @@ lookup_by_address_finish (GResolver *resolver,
|
||||
}
|
||||
|
||||
|
||||
-#if defined(G_OS_UNIX)
|
||||
+#if defined(G_OS_UNIX) || defined(G_OS_HAIKU)
|
||||
|
||||
#ifdef __BIONIC__
|
||||
/* Copy from bionic/libc/private/arpa_nameser_compat.h
|
||||
@@ -813,7 +813,7 @@ do_lookup_records (GTask *task,
|
||||
GList *records;
|
||||
GError *error = NULL;
|
||||
|
||||
-#if defined(G_OS_UNIX)
|
||||
+#if defined(G_OS_UNIX) || defined(G_OS_HAIKU)
|
||||
gint len = 512;
|
||||
gint herr;
|
||||
GByteArray *answer;
|
||||
diff --git a/gio/gunixmounts.c b/gio/gunixmounts.c
|
||||
index 03f1720..cb438a4 100644
|
||||
--- a/gio/gunixmounts.c
|
||||
+++ b/gio/gunixmounts.c
|
||||
@@ -72,7 +72,6 @@
|
||||
#include "glibintl.h"
|
||||
#include "gthemedicon.h"
|
||||
|
||||
-
|
||||
#ifdef HAVE_MNTENT_H
|
||||
static const char *_resolve_dev_root (void);
|
||||
#endif
|
||||
@@ -716,6 +715,18 @@ _g_get_unix_mounts (void)
|
||||
|
||||
return return_list;
|
||||
}
|
||||
+#elif defined(G_OS_HAIKU)
|
||||
+static char *
|
||||
+get_mtab_monitor_file (void)
|
||||
+{
|
||||
+ return NULL;
|
||||
+}
|
||||
+
|
||||
+static GList *
|
||||
+_g_get_unix_mounts (void)
|
||||
+{
|
||||
+ return NULL;
|
||||
+}
|
||||
#else
|
||||
#error No _g_get_unix_mounts() implementation for system
|
||||
#endif
|
||||
@@ -1106,7 +1117,7 @@ _g_get_unix_mount_points (void)
|
||||
|
||||
return g_list_reverse (return_list);
|
||||
}
|
||||
-#elif defined(__INTERIX)
|
||||
+#elif defined(__INTERIX) || defined(G_OS_HAIKU)
|
||||
static GList *
|
||||
_g_get_unix_mount_points (void)
|
||||
{
|
||||
diff --git a/glib/gbacktrace.c b/glib/gbacktrace.c
|
||||
index 4d19d6f..1c46778 100644
|
||||
--- a/glib/gbacktrace.c
|
||||
+++ b/glib/gbacktrace.c
|
||||
@@ -228,7 +228,7 @@ g_on_error_query (const gchar *prg_name)
|
||||
void
|
||||
g_on_error_stack_trace (const gchar *prg_name)
|
||||
{
|
||||
-#if defined(G_OS_UNIX) || defined(G_OS_BEOS)
|
||||
+#if defined(G_OS_UNIX) || defined(G_OS_BEOS) || defined(G_OS_HAIKU)
|
||||
pid_t pid;
|
||||
gchar buf[16];
|
||||
gchar *args[4] = { "gdb", NULL, NULL, NULL };
|
||||
diff --git a/glib/glib-unix.h b/glib/glib-unix.h
|
||||
index 66ccf74..a03a0cf 100644
|
||||
--- a/glib/glib-unix.h
|
||||
+++ b/glib/glib-unix.h
|
||||
@@ -34,7 +34,7 @@
|
||||
|
||||
#include <glib.h>
|
||||
|
||||
-#ifndef G_OS_UNIX
|
||||
+#if !defined(G_OS_UNIX) && !defined(G_OS_HAIKU)
|
||||
#error "This header may only be used on UNIX"
|
||||
#endif
|
||||
|
||||
diff --git a/glib/gmain.c b/glib/gmain.c
|
||||
index 738e69c..4f5dfab 100644
|
||||
--- a/glib/gmain.c
|
||||
+++ b/glib/gmain.c
|
||||
@@ -47,7 +47,7 @@
|
||||
#define G_MAIN_POLL_DEBUG
|
||||
#endif
|
||||
|
||||
-#ifdef G_OS_UNIX
|
||||
+#if defined(G_OS_UNIX) || defined(G_OS_HAIKU)
|
||||
#include "glib-unix.h"
|
||||
#include <pthread.h>
|
||||
#ifdef HAVE_EVENTFD
|
||||
@@ -73,10 +73,11 @@
|
||||
#include <windows.h>
|
||||
#endif /* G_OS_WIN32 */
|
||||
|
||||
-#ifdef G_OS_BEOS
|
||||
+#if defined G_OS_BEOS || defined G_OS_HAIKU
|
||||
#include <sys/socket.h>
|
||||
#include <sys/wait.h>
|
||||
-#endif /* G_OS_BEOS */
|
||||
+#include <fcntl.h>
|
||||
+#endif /* G_OS_BEOS || G_OS_HAIKU */
|
||||
|
||||
#include "gmain.h"
|
||||
|
||||
@@ -391,7 +392,7 @@ static gboolean g_child_watch_dispatch (GSource *source,
|
||||
GSourceFunc callback,
|
||||
gpointer user_data);
|
||||
static void g_child_watch_finalize (GSource *source);
|
||||
-#ifdef G_OS_UNIX
|
||||
+#if defined(G_OS_UNIX) || defined(G_OS_HAIKU)
|
||||
static void g_unix_signal_handler (int signum);
|
||||
static gboolean g_unix_signal_watch_prepare (GSource *source,
|
||||
gint *timeout);
|
||||
@@ -2259,7 +2260,7 @@ g_source_remove_by_funcs_user_data (GSourceFuncs *funcs,
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
-#ifdef G_OS_UNIX
|
||||
+#if defined(G_OS_UNIX) || defined(G_OS_HAIKU)
|
||||
/**
|
||||
* g_source_add_unix_fd:
|
||||
* @source: a #GSource
|
||||
@@ -2425,7 +2426,7 @@ g_source_query_unix_fd (GSource *source,
|
||||
|
||||
return poll_fd->revents;
|
||||
}
|
||||
-#endif /* G_OS_UNIX */
|
||||
+#endif /* G_OS_UNIX || G_OS_HAIKU */
|
||||
|
||||
/**
|
||||
* g_get_current_time:
|
||||
@@ -5471,7 +5472,7 @@ glib_worker_main (gpointer data)
|
||||
{
|
||||
g_main_context_iteration (glib_worker_context, TRUE);
|
||||
|
||||
-#ifdef G_OS_UNIX
|
||||
+#if defined(G_OS_UNIX) || defined(G_OS_HAIKU)
|
||||
if (any_unix_signal_pending)
|
||||
dispatch_unix_signals ();
|
||||
#endif
|
||||
@@ -5488,7 +5489,7 @@ g_get_worker_context (void)
|
||||
if (g_once_init_enter (&initialised))
|
||||
{
|
||||
/* mask all signals in the worker thread */
|
||||
-#ifdef G_OS_UNIX
|
||||
+#if defined(G_OS_UNIX) || defined(G_OS_HAIKU)
|
||||
sigset_t prev_mask;
|
||||
sigset_t all;
|
||||
|
||||
@@ -5497,7 +5498,7 @@ g_get_worker_context (void)
|
||||
#endif
|
||||
glib_worker_context = g_main_context_new ();
|
||||
g_thread_new ("gmain", glib_worker_main, NULL);
|
||||
-#ifdef G_OS_UNIX
|
||||
+#if defined(G_OS_UNIX) || defined(G_OS_HAIKU)
|
||||
pthread_sigmask (SIG_SETMASK, &prev_mask, NULL);
|
||||
#endif
|
||||
g_once_init_leave (&initialised, TRUE);
|
||||
diff --git a/glib/gmain.h b/glib/gmain.h
|
||||
index c455353..ad7b330 100644
|
||||
--- a/glib/gmain.h
|
||||
+++ b/glib/gmain.h
|
||||
@@ -471,7 +471,7 @@ void g_source_set_ready_time (GSource *source,
|
||||
GLIB_AVAILABLE_IN_2_36
|
||||
gint64 g_source_get_ready_time (GSource *source);
|
||||
|
||||
-#ifdef G_OS_UNIX
|
||||
+#if defined(G_OS_UNIX) || defined(G_OS_HAIKU)
|
||||
GLIB_AVAILABLE_IN_2_36
|
||||
gpointer g_source_add_unix_fd (GSource *source,
|
||||
gint fd,
|
||||
@@ -606,7 +606,7 @@ void g_main_context_invoke (GMainContext *context,
|
||||
GLIB_VAR GSourceFuncs g_timeout_funcs;
|
||||
GLIB_VAR GSourceFuncs g_child_watch_funcs;
|
||||
GLIB_VAR GSourceFuncs g_idle_funcs;
|
||||
-#ifdef G_OS_UNIX
|
||||
+#if defined(G_OS_UNIX) || defined(G_OS_HAIKU)
|
||||
GLIB_VAR GSourceFuncs g_unix_signal_funcs;
|
||||
GLIB_VAR GSourceFuncs g_unix_fd_source_funcs;
|
||||
#endif
|
||||
diff --git a/glib/gstdio.c b/glib/gstdio.c
|
||||
index cca4ff5..6f4ae9c 100644
|
||||
--- a/glib/gstdio.c
|
||||
+++ b/glib/gstdio.c
|
||||
@@ -46,7 +46,7 @@
|
||||
#include "gstdio.h"
|
||||
|
||||
|
||||
-#if !defined (G_OS_UNIX) && !defined (G_OS_WIN32) && !defined (G_OS_BEOS)
|
||||
+#if !defined (G_OS_UNIX) && !defined (G_OS_WIN32) && !defined (G_OS_BEOS) && !defined (G_OS_HAIKU)
|
||||
#error Please port this to your operating system
|
||||
#endif
|
||||
|
||||
diff --git a/glib/gutils.c b/glib/gutils.c
|
||||
index 2620cb6..34f1edd 100644
|
||||
--- a/glib/gutils.c
|
||||
+++ b/glib/gutils.c
|
||||
@@ -77,6 +77,11 @@
|
||||
#include "gwin32.h"
|
||||
#endif
|
||||
|
||||
+#if defined(G_OS_HAIKU)
|
||||
+#include <FindDirectory.h>
|
||||
+#include <fs_info.h>
|
||||
+#endif
|
||||
+
|
||||
|
||||
/**
|
||||
* SECTION:misc_utils
|
||||
@@ -421,7 +426,7 @@ g_find_program_in_path (const gchar *program)
|
||||
}
|
||||
|
||||
path = g_getenv ("PATH");
|
||||
-#if defined(G_OS_UNIX) || defined(G_OS_BEOS)
|
||||
+#if defined(G_OS_UNIX) || defined(G_OS_BEOS) || defined(G_OS_HAIKU)
|
||||
if (path == NULL)
|
||||
{
|
||||
/* There is no 'PATH' in the environment. The default
|
||||
@@ -1467,6 +1472,36 @@ load_user_special_dirs (void)
|
||||
|
||||
#endif /* HAVE_CARBON */
|
||||
|
||||
+#if defined(G_OS_HAIKU)
|
||||
+static void
|
||||
+load_user_special_dirs (void)
|
||||
+{
|
||||
+ char path[B_PATH_NAME_LENGTH + B_FILE_NAME_LENGTH];
|
||||
+
|
||||
+ dev_t volume = dev_for_path("/boot");
|
||||
+ if (find_directory(B_DESKTOP_DIRECTORY, volume, false, path, sizeof(path))
|
||||
+ == B_OK) {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DESKTOP] = g_strdup(path);
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOWNLOAD] = g_strdup(path);
|
||||
+ } else {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOCUMENTS] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DESKTOP] = NULL;
|
||||
+ }
|
||||
+
|
||||
+ if (find_directory(B_USER_DIRECTORY, volume, false, path, sizeof(path))
|
||||
+ == B_OK) {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOCUMENTS] = g_strdup(path);
|
||||
+ } else
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOWNLOAD] = NULL;
|
||||
+
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_MUSIC] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_PICTURES] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_PUBLIC_SHARE] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_TEMPLATES] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_VIDEOS] = NULL;
|
||||
+}
|
||||
+#endif /* G_OS_HAIKU */
|
||||
+
|
||||
#if defined(G_OS_WIN32)
|
||||
static void
|
||||
load_user_special_dirs (void)
|
||||
--
|
||||
1.8.3.4
|
||||
|
||||
|
||||
From 092577e9398f25dc86c5dff1b9baea92a13c78e4 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Thu, 21 Aug 2014 17:08:30 +0000
|
||||
Subject: strings.h for strcasecmp
|
||||
|
||||
|
||||
diff --git a/glib/glib-init.c b/glib/glib-init.c
|
||||
index 0032ee8..384257f 100644
|
||||
--- a/glib/glib-init.c
|
||||
+++ b/glib/glib-init.c
|
||||
@@ -27,6 +27,7 @@
|
||||
#include "gconstructor.h"
|
||||
|
||||
#include <string.h>
|
||||
+#include <strings.h>
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <ctype.h>
|
||||
diff --git a/glib/gstrfuncs.c b/glib/gstrfuncs.c
|
||||
index 4fcd91c..676c2df 100644
|
||||
--- a/glib/gstrfuncs.c
|
||||
+++ b/glib/gstrfuncs.c
|
||||
@@ -35,6 +35,7 @@
|
||||
#include <stdlib.h>
|
||||
#include <locale.h>
|
||||
#include <string.h>
|
||||
+#include <strings.h>
|
||||
#include <locale.h>
|
||||
#include <errno.h>
|
||||
#include <ctype.h> /* For tolower() */
|
||||
--
|
||||
1.8.3.4
|
||||
|
||||
@@ -1,211 +0,0 @@
|
||||
From 5aa9cb0c6bf9ce1deb8eca9eb171c5f66561f868 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Tue, 17 Jun 2014 19:57:08 +0000
|
||||
Subject: Haiku patch
|
||||
|
||||
based on patch from 2.38.1
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 51048f4..594e325 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -149,6 +149,10 @@ case "$host" in
|
||||
;;
|
||||
esac
|
||||
case $host in
|
||||
+ *-*-haiku*)
|
||||
+ glib_os_haiku=yes
|
||||
+ LIBS="-lnetwork $LIBS"
|
||||
+ ;;
|
||||
*-*-linux*)
|
||||
glib_os_linux=yes
|
||||
;;
|
||||
@@ -193,6 +197,7 @@ AM_CONDITIONAL(OS_WIN32, [test "$glib_native_win32" = "yes"])
|
||||
AM_CONDITIONAL(OS_WIN32_X64, [test "$LIB_EXE_MACHINE_FLAG" = "X64"])
|
||||
AM_CONDITIONAL(OS_UNIX, [test "$glib_native_win32" != "yes"])
|
||||
AM_CONDITIONAL(OS_LINUX, [test "$glib_os_linux" = "yes"])
|
||||
+AM_CONDITIONAL(OS_HAIKU, [test "$glib_os_haiku" = "yes"])
|
||||
AM_CONDITIONAL(OS_CARBON, [test "$glib_have_carbon" = "yes"])
|
||||
AM_CONDITIONAL(OS_COCOA, [test "$glib_have_cocoa" = "yes"])
|
||||
|
||||
@@ -1945,8 +1950,8 @@ AS_IF([ test x"$have_threads" = xposix], [
|
||||
# One of them does for most gcc versions and some other platforms/compilers
|
||||
# too and could be considered as the canonical way to go.
|
||||
case $host in
|
||||
- *-*-cygwin*|*-*-darwin*)
|
||||
- # skip cygwin and darwin -pthread or -pthreads test
|
||||
+ *-*-cygwin*|*-*-darwin*|*-*-haiku*)
|
||||
+ # skip cygwin, darwin and haiku -pthread or -pthreads test
|
||||
;;
|
||||
*-solaris*)
|
||||
# These compiler/linker flags work with both Sun Studio and gcc
|
||||
@@ -2111,6 +2116,15 @@ if test "x$G_THREAD_LIBS" = xerror; then
|
||||
AC_MSG_ERROR($LIBS_NOT_FOUND_1$have_threads$LIBS_NOT_FOUND_2)
|
||||
fi
|
||||
|
||||
+case $host in
|
||||
+ *-*-haiku*)
|
||||
+ G_THREAD_LIBS="-lbe -lroot"
|
||||
+ G_THREAD_LIBS_EXTRA="-L\$(top_builddir_full)/.libs"
|
||||
+ ;;
|
||||
+ *)
|
||||
+ ;;
|
||||
+esac
|
||||
+
|
||||
AC_MSG_CHECKING(thread related libraries)
|
||||
AC_MSG_RESULT($G_THREAD_LIBS)
|
||||
|
||||
diff --git a/gio/Makefile.am b/gio/Makefile.am
|
||||
index b7f91cc..80ee9ff 100644
|
||||
--- a/gio/Makefile.am
|
||||
+++ b/gio/Makefile.am
|
||||
@@ -726,7 +726,11 @@ gio_querymodules_LDADD = libgio-2.0.la \
|
||||
gconstructor_as_data.h: $(top_srcdir)/glib/gconstructor.h data-to-c.pl
|
||||
$(AM_V_GEN) $(srcdir)/data-to-c.pl $(top_srcdir)/glib/gconstructor.h gconstructor_code > $@.tmp && mv $@.tmp $@
|
||||
|
||||
-glib_compile_schemas_LDADD = $(top_builddir)/glib/libglib-2.0.la
|
||||
+glib_compile_schemas_LDADD = libgio-2.0.la \
|
||||
+ $(top_builddir)/gobject/libgobject-2.0.la \
|
||||
+ $(top_builddir)/gmodule/libgmodule-2.0.la \
|
||||
+ $(top_builddir)/glib/libglib-2.0.la \
|
||||
+ $(NULL)
|
||||
glib_compile_schemas_SOURCES = \
|
||||
gconstructor_as_data.h \
|
||||
gvdb/gvdb-format.h \
|
||||
diff --git a/gio/gdbusmessage.c b/gio/gdbusmessage.c
|
||||
index d9d8f37..c604606 100644
|
||||
--- a/gio/gdbusmessage.c
|
||||
+++ b/gio/gdbusmessage.c
|
||||
@@ -33,6 +33,9 @@
|
||||
#elif MAJOR_IN_SYSMACROS
|
||||
#include <sys/sysmacros.h>
|
||||
#endif
|
||||
+#ifdef __HAIKU__
|
||||
+#include <SupportDefs.h>
|
||||
+#endif
|
||||
|
||||
#include "gdbusutils.h"
|
||||
#include "gdbusmessage.h"
|
||||
@@ -3474,8 +3477,13 @@ g_dbus_message_print (GDBusMessage *message,
|
||||
fs = g_string_new (NULL);
|
||||
if (fstat (fds[n], &statbuf) == 0)
|
||||
{
|
||||
+#ifdef __HAIKU__
|
||||
+ g_string_append_printf (fs, "%s" "dev=%" B_PRIiDEV, fs->len > 0 ? "," : "",
|
||||
+ statbuf.st_dev);
|
||||
+#else
|
||||
g_string_append_printf (fs, "%s" "dev=%d:%d", fs->len > 0 ? "," : "",
|
||||
major (statbuf.st_dev), minor (statbuf.st_dev));
|
||||
+#endif
|
||||
g_string_append_printf (fs, "%s" "mode=0%o", fs->len > 0 ? "," : "",
|
||||
statbuf.st_mode);
|
||||
g_string_append_printf (fs, "%s" "ino=%" G_GUINT64_FORMAT, fs->len > 0 ? "," : "",
|
||||
@@ -3484,8 +3492,13 @@ g_dbus_message_print (GDBusMessage *message,
|
||||
(guint) statbuf.st_uid);
|
||||
g_string_append_printf (fs, "%s" "gid=%u", fs->len > 0 ? "," : "",
|
||||
(guint) statbuf.st_gid);
|
||||
+#ifdef __HAIKU__
|
||||
+ g_string_append_printf (fs, "%s" "rdev=%" B_PRIiDEV, fs->len > 0 ? "," : "",
|
||||
+ statbuf.st_rdev);
|
||||
+#else
|
||||
g_string_append_printf (fs, "%s" "rdev=%d:%d", fs->len > 0 ? "," : "",
|
||||
major (statbuf.st_rdev), minor (statbuf.st_rdev));
|
||||
+#endif
|
||||
g_string_append_printf (fs, "%s" "size=%" G_GUINT64_FORMAT, fs->len > 0 ? "," : "",
|
||||
(guint64) statbuf.st_size);
|
||||
g_string_append_printf (fs, "%s" "atime=%" G_GUINT64_FORMAT, fs->len > 0 ? "," : "",
|
||||
diff --git a/gio/gunixmounts.c b/gio/gunixmounts.c
|
||||
index 2e2ff5e..dddcadc 100644
|
||||
--- a/gio/gunixmounts.c
|
||||
+++ b/gio/gunixmounts.c
|
||||
@@ -712,7 +712,18 @@ _g_get_unix_mounts (void)
|
||||
|
||||
return return_list;
|
||||
}
|
||||
+#elif defined(__HAIKU__)
|
||||
+static char *
|
||||
+get_mtab_monitor_file (void)
|
||||
+{
|
||||
+ return NULL;
|
||||
+}
|
||||
|
||||
+static GList *
|
||||
+_g_get_unix_mounts (void)
|
||||
+{
|
||||
+ return NULL;
|
||||
+}
|
||||
/* Common code {{{2 */
|
||||
#else
|
||||
#error No _g_get_unix_mounts() implementation for system
|
||||
@@ -1111,7 +1122,7 @@ _g_get_unix_mount_points (void)
|
||||
return g_list_reverse (return_list);
|
||||
}
|
||||
/* Interix {{{2 */
|
||||
-#elif defined(__INTERIX)
|
||||
+#elif defined(__INTERIX) || defined(__HAIKU__)
|
||||
static GList *
|
||||
_g_get_unix_mount_points (void)
|
||||
{
|
||||
diff --git a/glib/gutils.c b/glib/gutils.c
|
||||
index 360a4d5..4cbd53b 100644
|
||||
--- a/glib/gutils.c
|
||||
+++ b/glib/gutils.c
|
||||
@@ -74,6 +74,11 @@
|
||||
#include "gwin32.h"
|
||||
#endif
|
||||
|
||||
+#if defined(__HAIKU__)
|
||||
+#include <FindDirectory.h>
|
||||
+#include <fs_info.h>
|
||||
+#endif
|
||||
+
|
||||
|
||||
/**
|
||||
* SECTION:misc_utils
|
||||
@@ -366,7 +371,7 @@ g_find_program_in_path (const gchar *program)
|
||||
}
|
||||
|
||||
path = g_getenv ("PATH");
|
||||
-#if defined(G_OS_UNIX)
|
||||
+#ifdef G_OS_UNIX
|
||||
if (path == NULL)
|
||||
{
|
||||
/* There is no 'PATH' in the environment. The default
|
||||
@@ -1404,6 +1409,34 @@ load_user_special_dirs (void)
|
||||
g_user_special_dirs[G_USER_DIRECTORY_VIDEOS] = find_folder (kMovieDocumentsFolderType);
|
||||
}
|
||||
|
||||
+#elif defined(__HAIKU__)
|
||||
+static void
|
||||
+load_user_special_dirs (void)
|
||||
+{
|
||||
+ char path[B_PATH_NAME_LENGTH + B_FILE_NAME_LENGTH];
|
||||
+
|
||||
+ dev_t volume = dev_for_path("/boot");
|
||||
+ if (find_directory(B_DESKTOP_DIRECTORY, volume, false, path, sizeof(path))
|
||||
+ == B_OK) {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DESKTOP] = g_strdup(path);
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOWNLOAD] = g_strdup(path);
|
||||
+ } else {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOCUMENTS] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DESKTOP] = NULL;
|
||||
+ }
|
||||
+
|
||||
+ if (find_directory(B_USER_DIRECTORY, volume, false, path, sizeof(path))
|
||||
+ == B_OK) {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOCUMENTS] = g_strdup(path);
|
||||
+ } else
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOWNLOAD] = NULL;
|
||||
+
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_MUSIC] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_PICTURES] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_PUBLIC_SHARE] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_TEMPLATES] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_VIDEOS] = NULL;
|
||||
+}
|
||||
#elif defined(G_OS_WIN32)
|
||||
|
||||
static void
|
||||
--
|
||||
2.2.2
|
||||
|
||||
@@ -1,241 +0,0 @@
|
||||
From cf040d5469f1683a84a671dfbebaeded12bb60c1 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 19 Dec 2015 14:51:01 +0000
|
||||
Subject: glib_compile_schemas: links against gio, gobject and gmodule.
|
||||
|
||||
Otherwise build fails on Haiku.
|
||||
|
||||
diff --git a/gio/Makefile.am b/gio/Makefile.am
|
||||
index 5d5d741..d4caed9 100644
|
||||
--- a/gio/Makefile.am
|
||||
+++ b/gio/Makefile.am
|
||||
@@ -728,7 +728,11 @@ gio_querymodules_LDADD = libgio-2.0.la \
|
||||
gconstructor_as_data.h: $(top_srcdir)/glib/gconstructor.h data-to-c.pl
|
||||
$(AM_V_GEN) $(srcdir)/data-to-c.pl $(top_srcdir)/glib/gconstructor.h gconstructor_code > $@.tmp && mv $@.tmp $@
|
||||
|
||||
-glib_compile_schemas_LDADD = $(top_builddir)/glib/libglib-2.0.la
|
||||
+glib_compile_schemas_LDADD = libgio-2.0.la \
|
||||
+ $(top_builddir)/gobject/libgobject-2.0.la \
|
||||
+ $(top_builddir)/gmodule/libgmodule-2.0.la \
|
||||
+ $(top_builddir)/glib/libglib-2.0.la \
|
||||
+ $(NULL)
|
||||
glib_compile_schemas_SOURCES = \
|
||||
gconstructor_as_data.h \
|
||||
gvdb/gvdb-format.h \
|
||||
--
|
||||
2.2.2
|
||||
|
||||
|
||||
From 0095964aadf305fde0a5b58ea9b5ba03d9787d50 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 19 Dec 2015 14:59:42 +0000
|
||||
Subject: configure.ac: on Haiku
|
||||
|
||||
* don't use -pthread
|
||||
* use -lbe -lroot as thread related libs.
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 339defc..9d8bed2 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -152,6 +152,9 @@ case "$host" in
|
||||
;;
|
||||
esac
|
||||
case $host in
|
||||
+ *-*-haiku*)
|
||||
+ LIBS="-lnetwork $LIBS"
|
||||
+ ;;
|
||||
*-*-linux*)
|
||||
glib_os_linux=yes
|
||||
;;
|
||||
@@ -1876,8 +1879,8 @@ AS_IF([ test x"$have_threads" = xposix], [
|
||||
# One of them does for most gcc versions and some other platforms/compilers
|
||||
# too and could be considered as the canonical way to go.
|
||||
case $host in
|
||||
- *-*-cygwin*|*-*-darwin*)
|
||||
- # skip cygwin and darwin -pthread or -pthreads test
|
||||
+ *-*-cygwin*|*-*-darwin*|*-*-haiku*)
|
||||
+ # skip cygwin, darwin and haiku -pthread or -pthreads test
|
||||
;;
|
||||
*-solaris*)
|
||||
# These compiler/linker flags work with both Sun Studio and gcc
|
||||
@@ -2042,6 +2045,15 @@ if test "x$G_THREAD_LIBS" = xerror; then
|
||||
AC_MSG_ERROR($LIBS_NOT_FOUND_1$have_threads$LIBS_NOT_FOUND_2)
|
||||
fi
|
||||
|
||||
+case $host in
|
||||
+ *-*-haiku*)
|
||||
+ G_THREAD_LIBS="-lbe -lroot"
|
||||
+ G_THREAD_LIBS_EXTRA="-L\$(top_builddir_full)/.libs"
|
||||
+ ;;
|
||||
+ *)
|
||||
+ ;;
|
||||
+esac
|
||||
+
|
||||
AC_MSG_CHECKING(thread related libraries)
|
||||
AC_MSG_RESULT($G_THREAD_LIBS)
|
||||
|
||||
--
|
||||
2.2.2
|
||||
|
||||
|
||||
From 00208cb8f052a1e0acafdeb558d580d4cceb2855 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 19 Dec 2015 15:06:17 +0000
|
||||
Subject: g_dbus_message_print: use B_PRIiDEV on Haiku.
|
||||
|
||||
because Haiku doesn't define major() and minor().
|
||||
|
||||
diff --git a/gio/gdbusmessage.c b/gio/gdbusmessage.c
|
||||
index d9d8f37..eb5945c 100644
|
||||
--- a/gio/gdbusmessage.c
|
||||
+++ b/gio/gdbusmessage.c
|
||||
@@ -33,6 +33,9 @@
|
||||
#elif MAJOR_IN_SYSMACROS
|
||||
#include <sys/sysmacros.h>
|
||||
#endif
|
||||
+#ifdef __HAIKU__
|
||||
+#include <SupportDefs.h>
|
||||
+#endif
|
||||
|
||||
#include "gdbusutils.h"
|
||||
#include "gdbusmessage.h"
|
||||
@@ -3474,8 +3477,13 @@ g_dbus_message_print (GDBusMessage *message,
|
||||
fs = g_string_new (NULL);
|
||||
if (fstat (fds[n], &statbuf) == 0)
|
||||
{
|
||||
+#ifdef __HAIKU__
|
||||
+ g_string_append_printf (fs, "%s" "dev=%" B_PRIiDEV, fs->len > 0 ? "," : "",
|
||||
+ statbuf.st_dev);
|
||||
+#else
|
||||
g_string_append_printf (fs, "%s" "dev=%d:%d", fs->len > 0 ? "," : "",
|
||||
major (statbuf.st_dev), minor (statbuf.st_dev));
|
||||
+#endif
|
||||
g_string_append_printf (fs, "%s" "mode=0%o", fs->len > 0 ? "," : "",
|
||||
statbuf.st_mode);
|
||||
g_string_append_printf (fs, "%s" "ino=%" G_GUINT64_FORMAT, fs->len > 0 ? "," : "",
|
||||
@@ -3484,8 +3492,13 @@ g_dbus_message_print (GDBusMessage *message,
|
||||
(guint) statbuf.st_uid);
|
||||
g_string_append_printf (fs, "%s" "gid=%u", fs->len > 0 ? "," : "",
|
||||
(guint) statbuf.st_gid);
|
||||
+#ifdef __HAIKU__
|
||||
+ g_string_append_printf (fs, "%s" "rdev=%" B_PRIiDEV, fs->len > 0 ? "," : "",
|
||||
+ statbuf.st_rdev);
|
||||
+#else
|
||||
g_string_append_printf (fs, "%s" "rdev=%d:%d", fs->len > 0 ? "," : "",
|
||||
major (statbuf.st_rdev), minor (statbuf.st_rdev));
|
||||
+#endif
|
||||
g_string_append_printf (fs, "%s" "size=%" G_GUINT64_FORMAT, fs->len > 0 ? "," : "",
|
||||
(guint64) statbuf.st_size);
|
||||
g_string_append_printf (fs, "%s" "atime=%" G_GUINT64_FORMAT, fs->len > 0 ? "," : "",
|
||||
--
|
||||
2.2.2
|
||||
|
||||
|
||||
From 55022ad00cba573ec61795760b3cbf30f1efb284 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 19 Dec 2015 15:09:39 +0000
|
||||
Subject: gunixmounts.c: on Haiku
|
||||
|
||||
* define get_mtab_monitor_file() and _g_get_unix_mounts().
|
||||
* like Interix, _g_get_unix_mount_points() calls _g_get_unix_mounts().
|
||||
|
||||
diff --git a/gio/gunixmounts.c b/gio/gunixmounts.c
|
||||
index 2e2ff5e..8d5e752 100644
|
||||
--- a/gio/gunixmounts.c
|
||||
+++ b/gio/gunixmounts.c
|
||||
@@ -712,7 +712,18 @@ _g_get_unix_mounts (void)
|
||||
|
||||
return return_list;
|
||||
}
|
||||
+#elif defined(__HAIKU__)
|
||||
+static char *
|
||||
+get_mtab_monitor_file (void)
|
||||
+{
|
||||
+ return NULL;
|
||||
+}
|
||||
|
||||
+static GList *
|
||||
+_g_get_unix_mounts (void)
|
||||
+{
|
||||
+ return NULL;
|
||||
+}
|
||||
/* Common code {{{2 */
|
||||
#else
|
||||
#error No _g_get_unix_mounts() implementation for system
|
||||
@@ -1110,8 +1121,8 @@ _g_get_unix_mount_points (void)
|
||||
|
||||
return g_list_reverse (return_list);
|
||||
}
|
||||
-/* Interix {{{2 */
|
||||
-#elif defined(__INTERIX)
|
||||
+/* Interix, Haiku {{{2 */
|
||||
+#elif defined(__INTERIX) || defined(__HAIKU__)
|
||||
static GList *
|
||||
_g_get_unix_mount_points (void)
|
||||
{
|
||||
--
|
||||
2.2.2
|
||||
|
||||
|
||||
From 4bb1d1e5f4c0284cbc235b9747eb5d2deaa6f4c8 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 19 Dec 2015 15:12:40 +0000
|
||||
Subject: glib/gutils.c: on Haiku define load_user_special_dirs().
|
||||
|
||||
use find_directory() from SupportDefs.h.
|
||||
|
||||
diff --git a/glib/gutils.c b/glib/gutils.c
|
||||
index e82ce54..bb2b72a 100644
|
||||
--- a/glib/gutils.c
|
||||
+++ b/glib/gutils.c
|
||||
@@ -69,6 +69,11 @@
|
||||
#include "gwin32.h"
|
||||
#endif
|
||||
|
||||
+#if defined(__HAIKU__)
|
||||
+#include <FindDirectory.h>
|
||||
+#include <fs_info.h>
|
||||
+#endif
|
||||
+
|
||||
|
||||
/**
|
||||
* SECTION:misc_utils
|
||||
@@ -1421,6 +1426,34 @@ load_user_special_dirs (void)
|
||||
g_user_special_dirs[G_USER_DIRECTORY_VIDEOS] = find_folder (kMovieDocumentsFolderType);
|
||||
}
|
||||
|
||||
+#elif defined(__HAIKU__)
|
||||
+static void
|
||||
+load_user_special_dirs (void)
|
||||
+{
|
||||
+ char path[B_PATH_NAME_LENGTH + B_FILE_NAME_LENGTH];
|
||||
+
|
||||
+ dev_t volume = dev_for_path("/boot");
|
||||
+ if (find_directory(B_DESKTOP_DIRECTORY, volume, false, path, sizeof(path))
|
||||
+ == B_OK) {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DESKTOP] = g_strdup(path);
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOWNLOAD] = g_strdup(path);
|
||||
+ } else {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOCUMENTS] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DESKTOP] = NULL;
|
||||
+ }
|
||||
+
|
||||
+ if (find_directory(B_USER_DIRECTORY, volume, false, path, sizeof(path))
|
||||
+ == B_OK) {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOCUMENTS] = g_strdup(path);
|
||||
+ } else
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOWNLOAD] = NULL;
|
||||
+
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_MUSIC] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_PICTURES] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_PUBLIC_SHARE] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_TEMPLATES] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_VIDEOS] = NULL;
|
||||
+}
|
||||
#elif defined(G_OS_WIN32)
|
||||
|
||||
static void
|
||||
--
|
||||
2.2.2
|
||||
|
||||
@@ -1,241 +0,0 @@
|
||||
From cf040d5469f1683a84a671dfbebaeded12bb60c1 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 19 Dec 2015 14:51:01 +0000
|
||||
Subject: glib_compile_schemas: links against gio, gobject and gmodule.
|
||||
|
||||
Otherwise build fails on Haiku.
|
||||
|
||||
diff --git a/gio/Makefile.am b/gio/Makefile.am
|
||||
index 5d5d741..d4caed9 100644
|
||||
--- a/gio/Makefile.am
|
||||
+++ b/gio/Makefile.am
|
||||
@@ -728,7 +728,11 @@ gio_querymodules_LDADD = libgio-2.0.la \
|
||||
gconstructor_as_data.h: $(top_srcdir)/glib/gconstructor.h data-to-c.pl
|
||||
$(AM_V_GEN) $(srcdir)/data-to-c.pl $(top_srcdir)/glib/gconstructor.h gconstructor_code > $@.tmp && mv $@.tmp $@
|
||||
|
||||
-glib_compile_schemas_LDADD = $(top_builddir)/glib/libglib-2.0.la
|
||||
+glib_compile_schemas_LDADD = libgio-2.0.la \
|
||||
+ $(top_builddir)/gobject/libgobject-2.0.la \
|
||||
+ $(top_builddir)/gmodule/libgmodule-2.0.la \
|
||||
+ $(top_builddir)/glib/libglib-2.0.la \
|
||||
+ $(NULL)
|
||||
glib_compile_schemas_SOURCES = \
|
||||
gconstructor_as_data.h \
|
||||
gvdb/gvdb-format.h \
|
||||
--
|
||||
2.2.2
|
||||
|
||||
|
||||
From 0095964aadf305fde0a5b58ea9b5ba03d9787d50 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 19 Dec 2015 14:59:42 +0000
|
||||
Subject: configure.ac: on Haiku
|
||||
|
||||
* don't use -pthread
|
||||
* use -lbe -lroot as thread related libs.
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 339defc..9d8bed2 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -152,6 +152,9 @@ case "$host" in
|
||||
;;
|
||||
esac
|
||||
case $host in
|
||||
+ *-*-haiku*)
|
||||
+ LIBS="-lnetwork $LIBS"
|
||||
+ ;;
|
||||
*-*-linux*)
|
||||
glib_os_linux=yes
|
||||
;;
|
||||
@@ -1876,8 +1879,8 @@ AS_IF([ test x"$have_threads" = xposix], [
|
||||
# One of them does for most gcc versions and some other platforms/compilers
|
||||
# too and could be considered as the canonical way to go.
|
||||
case $host in
|
||||
- *-*-cygwin*|*-*-darwin*)
|
||||
- # skip cygwin and darwin -pthread or -pthreads test
|
||||
+ *-*-cygwin*|*-*-darwin*|*-*-haiku*)
|
||||
+ # skip cygwin, darwin and haiku -pthread or -pthreads test
|
||||
;;
|
||||
*-solaris*)
|
||||
# These compiler/linker flags work with both Sun Studio and gcc
|
||||
@@ -2042,6 +2045,15 @@ if test "x$G_THREAD_LIBS" = xerror; then
|
||||
AC_MSG_ERROR($LIBS_NOT_FOUND_1$have_threads$LIBS_NOT_FOUND_2)
|
||||
fi
|
||||
|
||||
+case $host in
|
||||
+ *-*-haiku*)
|
||||
+ G_THREAD_LIBS="-lbe -lroot"
|
||||
+ G_THREAD_LIBS_EXTRA="-L\$(top_builddir_full)/.libs"
|
||||
+ ;;
|
||||
+ *)
|
||||
+ ;;
|
||||
+esac
|
||||
+
|
||||
AC_MSG_CHECKING(thread related libraries)
|
||||
AC_MSG_RESULT($G_THREAD_LIBS)
|
||||
|
||||
--
|
||||
2.2.2
|
||||
|
||||
|
||||
From 00208cb8f052a1e0acafdeb558d580d4cceb2855 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 19 Dec 2015 15:06:17 +0000
|
||||
Subject: g_dbus_message_print: use B_PRIiDEV on Haiku.
|
||||
|
||||
because Haiku doesn't define major() and minor().
|
||||
|
||||
diff --git a/gio/gdbusmessage.c b/gio/gdbusmessage.c
|
||||
index d9d8f37..eb5945c 100644
|
||||
--- a/gio/gdbusmessage.c
|
||||
+++ b/gio/gdbusmessage.c
|
||||
@@ -33,6 +33,9 @@
|
||||
#elif MAJOR_IN_SYSMACROS
|
||||
#include <sys/sysmacros.h>
|
||||
#endif
|
||||
+#ifdef __HAIKU__
|
||||
+#include <SupportDefs.h>
|
||||
+#endif
|
||||
|
||||
#include "gdbusutils.h"
|
||||
#include "gdbusmessage.h"
|
||||
@@ -3474,8 +3477,13 @@ g_dbus_message_print (GDBusMessage *message,
|
||||
fs = g_string_new (NULL);
|
||||
if (fstat (fds[n], &statbuf) == 0)
|
||||
{
|
||||
+#ifdef __HAIKU__
|
||||
+ g_string_append_printf (fs, "%s" "dev=%" B_PRIiDEV, fs->len > 0 ? "," : "",
|
||||
+ statbuf.st_dev);
|
||||
+#else
|
||||
g_string_append_printf (fs, "%s" "dev=%d:%d", fs->len > 0 ? "," : "",
|
||||
major (statbuf.st_dev), minor (statbuf.st_dev));
|
||||
+#endif
|
||||
g_string_append_printf (fs, "%s" "mode=0%o", fs->len > 0 ? "," : "",
|
||||
statbuf.st_mode);
|
||||
g_string_append_printf (fs, "%s" "ino=%" G_GUINT64_FORMAT, fs->len > 0 ? "," : "",
|
||||
@@ -3484,8 +3492,13 @@ g_dbus_message_print (GDBusMessage *message,
|
||||
(guint) statbuf.st_uid);
|
||||
g_string_append_printf (fs, "%s" "gid=%u", fs->len > 0 ? "," : "",
|
||||
(guint) statbuf.st_gid);
|
||||
+#ifdef __HAIKU__
|
||||
+ g_string_append_printf (fs, "%s" "rdev=%" B_PRIiDEV, fs->len > 0 ? "," : "",
|
||||
+ statbuf.st_rdev);
|
||||
+#else
|
||||
g_string_append_printf (fs, "%s" "rdev=%d:%d", fs->len > 0 ? "," : "",
|
||||
major (statbuf.st_rdev), minor (statbuf.st_rdev));
|
||||
+#endif
|
||||
g_string_append_printf (fs, "%s" "size=%" G_GUINT64_FORMAT, fs->len > 0 ? "," : "",
|
||||
(guint64) statbuf.st_size);
|
||||
g_string_append_printf (fs, "%s" "atime=%" G_GUINT64_FORMAT, fs->len > 0 ? "," : "",
|
||||
--
|
||||
2.2.2
|
||||
|
||||
|
||||
From 55022ad00cba573ec61795760b3cbf30f1efb284 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 19 Dec 2015 15:09:39 +0000
|
||||
Subject: gunixmounts.c: on Haiku
|
||||
|
||||
* define get_mtab_monitor_file() and _g_get_unix_mounts().
|
||||
* like Interix, _g_get_unix_mount_points() calls _g_get_unix_mounts().
|
||||
|
||||
diff --git a/gio/gunixmounts.c b/gio/gunixmounts.c
|
||||
index 2e2ff5e..8d5e752 100644
|
||||
--- a/gio/gunixmounts.c
|
||||
+++ b/gio/gunixmounts.c
|
||||
@@ -712,7 +712,18 @@ _g_get_unix_mounts (void)
|
||||
|
||||
return return_list;
|
||||
}
|
||||
+#elif defined(__HAIKU__)
|
||||
+static char *
|
||||
+get_mtab_monitor_file (void)
|
||||
+{
|
||||
+ return NULL;
|
||||
+}
|
||||
|
||||
+static GList *
|
||||
+_g_get_unix_mounts (void)
|
||||
+{
|
||||
+ return NULL;
|
||||
+}
|
||||
/* Common code {{{2 */
|
||||
#else
|
||||
#error No _g_get_unix_mounts() implementation for system
|
||||
@@ -1110,8 +1121,8 @@ _g_get_unix_mount_points (void)
|
||||
|
||||
return g_list_reverse (return_list);
|
||||
}
|
||||
-/* Interix {{{2 */
|
||||
-#elif defined(__INTERIX)
|
||||
+/* Interix, Haiku {{{2 */
|
||||
+#elif defined(__INTERIX) || defined(__HAIKU__)
|
||||
static GList *
|
||||
_g_get_unix_mount_points (void)
|
||||
{
|
||||
--
|
||||
2.2.2
|
||||
|
||||
|
||||
From 4bb1d1e5f4c0284cbc235b9747eb5d2deaa6f4c8 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 19 Dec 2015 15:12:40 +0000
|
||||
Subject: glib/gutils.c: on Haiku define load_user_special_dirs().
|
||||
|
||||
use find_directory() from SupportDefs.h.
|
||||
|
||||
diff --git a/glib/gutils.c b/glib/gutils.c
|
||||
index e82ce54..bb2b72a 100644
|
||||
--- a/glib/gutils.c
|
||||
+++ b/glib/gutils.c
|
||||
@@ -69,6 +69,11 @@
|
||||
#include "gwin32.h"
|
||||
#endif
|
||||
|
||||
+#if defined(__HAIKU__)
|
||||
+#include <FindDirectory.h>
|
||||
+#include <fs_info.h>
|
||||
+#endif
|
||||
+
|
||||
|
||||
/**
|
||||
* SECTION:misc_utils
|
||||
@@ -1421,6 +1426,34 @@ load_user_special_dirs (void)
|
||||
g_user_special_dirs[G_USER_DIRECTORY_VIDEOS] = find_folder (kMovieDocumentsFolderType);
|
||||
}
|
||||
|
||||
+#elif defined(__HAIKU__)
|
||||
+static void
|
||||
+load_user_special_dirs (void)
|
||||
+{
|
||||
+ char path[B_PATH_NAME_LENGTH + B_FILE_NAME_LENGTH];
|
||||
+
|
||||
+ dev_t volume = dev_for_path("/boot");
|
||||
+ if (find_directory(B_DESKTOP_DIRECTORY, volume, false, path, sizeof(path))
|
||||
+ == B_OK) {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DESKTOP] = g_strdup(path);
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOWNLOAD] = g_strdup(path);
|
||||
+ } else {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOCUMENTS] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DESKTOP] = NULL;
|
||||
+ }
|
||||
+
|
||||
+ if (find_directory(B_USER_DIRECTORY, volume, false, path, sizeof(path))
|
||||
+ == B_OK) {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOCUMENTS] = g_strdup(path);
|
||||
+ } else
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOWNLOAD] = NULL;
|
||||
+
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_MUSIC] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_PICTURES] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_PUBLIC_SHARE] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_TEMPLATES] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_VIDEOS] = NULL;
|
||||
+}
|
||||
#elif defined(G_OS_WIN32)
|
||||
|
||||
static void
|
||||
--
|
||||
2.2.2
|
||||
|
||||
@@ -1,241 +0,0 @@
|
||||
From cf040d5469f1683a84a671dfbebaeded12bb60c1 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 19 Dec 2015 14:51:01 +0000
|
||||
Subject: glib_compile_schemas: links against gio, gobject and gmodule.
|
||||
|
||||
Otherwise build fails on Haiku.
|
||||
|
||||
diff --git a/gio/Makefile.am b/gio/Makefile.am
|
||||
index 5d5d741..d4caed9 100644
|
||||
--- a/gio/Makefile.am
|
||||
+++ b/gio/Makefile.am
|
||||
@@ -728,7 +728,11 @@ gio_querymodules_LDADD = libgio-2.0.la \
|
||||
gconstructor_as_data.h: $(top_srcdir)/glib/gconstructor.h data-to-c.pl
|
||||
$(AM_V_GEN) $(srcdir)/data-to-c.pl $(top_srcdir)/glib/gconstructor.h gconstructor_code > $@.tmp && mv $@.tmp $@
|
||||
|
||||
-glib_compile_schemas_LDADD = $(top_builddir)/glib/libglib-2.0.la
|
||||
+glib_compile_schemas_LDADD = libgio-2.0.la \
|
||||
+ $(top_builddir)/gobject/libgobject-2.0.la \
|
||||
+ $(top_builddir)/gmodule/libgmodule-2.0.la \
|
||||
+ $(top_builddir)/glib/libglib-2.0.la \
|
||||
+ $(NULL)
|
||||
glib_compile_schemas_SOURCES = \
|
||||
gconstructor_as_data.h \
|
||||
gvdb/gvdb-format.h \
|
||||
--
|
||||
2.2.2
|
||||
|
||||
|
||||
From 0095964aadf305fde0a5b58ea9b5ba03d9787d50 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 19 Dec 2015 14:59:42 +0000
|
||||
Subject: configure.ac: on Haiku
|
||||
|
||||
* don't use -pthread
|
||||
* use -lbe -lroot as thread related libs.
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 339defc..9d8bed2 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -152,6 +152,9 @@ case "$host" in
|
||||
;;
|
||||
esac
|
||||
case $host in
|
||||
+ *-*-haiku*)
|
||||
+ LIBS="-lnetwork $LIBS"
|
||||
+ ;;
|
||||
*-*-linux*)
|
||||
glib_os_linux=yes
|
||||
;;
|
||||
@@ -1876,8 +1879,8 @@ AS_IF([ test x"$have_threads" = xposix], [
|
||||
# One of them does for most gcc versions and some other platforms/compilers
|
||||
# too and could be considered as the canonical way to go.
|
||||
case $host in
|
||||
- *-*-cygwin*|*-*-darwin*)
|
||||
- # skip cygwin and darwin -pthread or -pthreads test
|
||||
+ *-*-cygwin*|*-*-darwin*|*-*-haiku*)
|
||||
+ # skip cygwin, darwin and haiku -pthread or -pthreads test
|
||||
;;
|
||||
*-solaris*)
|
||||
# These compiler/linker flags work with both Sun Studio and gcc
|
||||
@@ -2042,6 +2045,15 @@ if test "x$G_THREAD_LIBS" = xerror; then
|
||||
AC_MSG_ERROR($LIBS_NOT_FOUND_1$have_threads$LIBS_NOT_FOUND_2)
|
||||
fi
|
||||
|
||||
+case $host in
|
||||
+ *-*-haiku*)
|
||||
+ G_THREAD_LIBS="-lbe -lroot"
|
||||
+ G_THREAD_LIBS_EXTRA="-L\$(top_builddir_full)/.libs"
|
||||
+ ;;
|
||||
+ *)
|
||||
+ ;;
|
||||
+esac
|
||||
+
|
||||
AC_MSG_CHECKING(thread related libraries)
|
||||
AC_MSG_RESULT($G_THREAD_LIBS)
|
||||
|
||||
--
|
||||
2.2.2
|
||||
|
||||
|
||||
From 00208cb8f052a1e0acafdeb558d580d4cceb2855 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 19 Dec 2015 15:06:17 +0000
|
||||
Subject: g_dbus_message_print: use B_PRIiDEV on Haiku.
|
||||
|
||||
because Haiku doesn't define major() and minor().
|
||||
|
||||
diff --git a/gio/gdbusmessage.c b/gio/gdbusmessage.c
|
||||
index d9d8f37..eb5945c 100644
|
||||
--- a/gio/gdbusmessage.c
|
||||
+++ b/gio/gdbusmessage.c
|
||||
@@ -33,6 +33,9 @@
|
||||
#elif MAJOR_IN_SYSMACROS
|
||||
#include <sys/sysmacros.h>
|
||||
#endif
|
||||
+#ifdef __HAIKU__
|
||||
+#include <SupportDefs.h>
|
||||
+#endif
|
||||
|
||||
#include "gdbusutils.h"
|
||||
#include "gdbusmessage.h"
|
||||
@@ -3474,8 +3477,13 @@ g_dbus_message_print (GDBusMessage *message,
|
||||
fs = g_string_new (NULL);
|
||||
if (fstat (fds[n], &statbuf) == 0)
|
||||
{
|
||||
+#ifdef __HAIKU__
|
||||
+ g_string_append_printf (fs, "%s" "dev=%" B_PRIiDEV, fs->len > 0 ? "," : "",
|
||||
+ statbuf.st_dev);
|
||||
+#else
|
||||
g_string_append_printf (fs, "%s" "dev=%d:%d", fs->len > 0 ? "," : "",
|
||||
major (statbuf.st_dev), minor (statbuf.st_dev));
|
||||
+#endif
|
||||
g_string_append_printf (fs, "%s" "mode=0%o", fs->len > 0 ? "," : "",
|
||||
statbuf.st_mode);
|
||||
g_string_append_printf (fs, "%s" "ino=%" G_GUINT64_FORMAT, fs->len > 0 ? "," : "",
|
||||
@@ -3484,8 +3492,13 @@ g_dbus_message_print (GDBusMessage *message,
|
||||
(guint) statbuf.st_uid);
|
||||
g_string_append_printf (fs, "%s" "gid=%u", fs->len > 0 ? "," : "",
|
||||
(guint) statbuf.st_gid);
|
||||
+#ifdef __HAIKU__
|
||||
+ g_string_append_printf (fs, "%s" "rdev=%" B_PRIiDEV, fs->len > 0 ? "," : "",
|
||||
+ statbuf.st_rdev);
|
||||
+#else
|
||||
g_string_append_printf (fs, "%s" "rdev=%d:%d", fs->len > 0 ? "," : "",
|
||||
major (statbuf.st_rdev), minor (statbuf.st_rdev));
|
||||
+#endif
|
||||
g_string_append_printf (fs, "%s" "size=%" G_GUINT64_FORMAT, fs->len > 0 ? "," : "",
|
||||
(guint64) statbuf.st_size);
|
||||
g_string_append_printf (fs, "%s" "atime=%" G_GUINT64_FORMAT, fs->len > 0 ? "," : "",
|
||||
--
|
||||
2.2.2
|
||||
|
||||
|
||||
From 55022ad00cba573ec61795760b3cbf30f1efb284 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 19 Dec 2015 15:09:39 +0000
|
||||
Subject: gunixmounts.c: on Haiku
|
||||
|
||||
* define get_mtab_monitor_file() and _g_get_unix_mounts().
|
||||
* like Interix, _g_get_unix_mount_points() calls _g_get_unix_mounts().
|
||||
|
||||
diff --git a/gio/gunixmounts.c b/gio/gunixmounts.c
|
||||
index 2e2ff5e..8d5e752 100644
|
||||
--- a/gio/gunixmounts.c
|
||||
+++ b/gio/gunixmounts.c
|
||||
@@ -712,7 +712,18 @@ _g_get_unix_mounts (void)
|
||||
|
||||
return return_list;
|
||||
}
|
||||
+#elif defined(__HAIKU__)
|
||||
+static char *
|
||||
+get_mtab_monitor_file (void)
|
||||
+{
|
||||
+ return NULL;
|
||||
+}
|
||||
|
||||
+static GList *
|
||||
+_g_get_unix_mounts (void)
|
||||
+{
|
||||
+ return NULL;
|
||||
+}
|
||||
/* Common code {{{2 */
|
||||
#else
|
||||
#error No _g_get_unix_mounts() implementation for system
|
||||
@@ -1110,8 +1121,8 @@ _g_get_unix_mount_points (void)
|
||||
|
||||
return g_list_reverse (return_list);
|
||||
}
|
||||
-/* Interix {{{2 */
|
||||
-#elif defined(__INTERIX)
|
||||
+/* Interix, Haiku {{{2 */
|
||||
+#elif defined(__INTERIX) || defined(__HAIKU__)
|
||||
static GList *
|
||||
_g_get_unix_mount_points (void)
|
||||
{
|
||||
--
|
||||
2.2.2
|
||||
|
||||
|
||||
From 4bb1d1e5f4c0284cbc235b9747eb5d2deaa6f4c8 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 19 Dec 2015 15:12:40 +0000
|
||||
Subject: glib/gutils.c: on Haiku define load_user_special_dirs().
|
||||
|
||||
use find_directory() from SupportDefs.h.
|
||||
|
||||
diff --git a/glib/gutils.c b/glib/gutils.c
|
||||
index e82ce54..bb2b72a 100644
|
||||
--- a/glib/gutils.c
|
||||
+++ b/glib/gutils.c
|
||||
@@ -69,6 +69,11 @@
|
||||
#include "gwin32.h"
|
||||
#endif
|
||||
|
||||
+#if defined(__HAIKU__)
|
||||
+#include <FindDirectory.h>
|
||||
+#include <fs_info.h>
|
||||
+#endif
|
||||
+
|
||||
|
||||
/**
|
||||
* SECTION:misc_utils
|
||||
@@ -1421,6 +1426,34 @@ load_user_special_dirs (void)
|
||||
g_user_special_dirs[G_USER_DIRECTORY_VIDEOS] = find_folder (kMovieDocumentsFolderType);
|
||||
}
|
||||
|
||||
+#elif defined(__HAIKU__)
|
||||
+static void
|
||||
+load_user_special_dirs (void)
|
||||
+{
|
||||
+ char path[B_PATH_NAME_LENGTH + B_FILE_NAME_LENGTH];
|
||||
+
|
||||
+ dev_t volume = dev_for_path("/boot");
|
||||
+ if (find_directory(B_DESKTOP_DIRECTORY, volume, false, path, sizeof(path))
|
||||
+ == B_OK) {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DESKTOP] = g_strdup(path);
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOWNLOAD] = g_strdup(path);
|
||||
+ } else {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOCUMENTS] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DESKTOP] = NULL;
|
||||
+ }
|
||||
+
|
||||
+ if (find_directory(B_USER_DIRECTORY, volume, false, path, sizeof(path))
|
||||
+ == B_OK) {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOCUMENTS] = g_strdup(path);
|
||||
+ } else
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOWNLOAD] = NULL;
|
||||
+
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_MUSIC] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_PICTURES] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_PUBLIC_SHARE] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_TEMPLATES] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_VIDEOS] = NULL;
|
||||
+}
|
||||
#elif defined(G_OS_WIN32)
|
||||
|
||||
static void
|
||||
--
|
||||
2.2.2
|
||||
|
||||
@@ -1,271 +0,0 @@
|
||||
From 55a17051755769cfea9ea4fea50f80be8887734c Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 19 Dec 2015 14:51:01 +0000
|
||||
Subject: glib_compile_schemas: links against gio, gobject and gmodule.
|
||||
|
||||
Otherwise build fails on Haiku.
|
||||
|
||||
diff --git a/gio/Makefile.am b/gio/Makefile.am
|
||||
index b2db995..c82f05c 100644
|
||||
--- a/gio/Makefile.am
|
||||
+++ b/gio/Makefile.am
|
||||
@@ -817,7 +817,11 @@ gio_querymodules_LDADD = libgio-2.0.la \
|
||||
gconstructor_as_data.h: $(top_srcdir)/glib/gconstructor.h data-to-c.pl
|
||||
$(AM_V_GEN) $(srcdir)/data-to-c.pl $(top_srcdir)/glib/gconstructor.h gconstructor_code > $@.tmp && mv $@.tmp $@
|
||||
|
||||
-glib_compile_schemas_LDADD = $(top_builddir)/glib/libglib-2.0.la
|
||||
+glib_compile_schemas_LDADD = libgio-2.0.la \
|
||||
+ $(top_builddir)/gobject/libgobject-2.0.la \
|
||||
+ $(top_builddir)/gmodule/libgmodule-2.0.la \
|
||||
+ $(top_builddir)/glib/libglib-2.0.la \
|
||||
+ $(NULL)
|
||||
glib_compile_schemas_SOURCES = \
|
||||
gconstructor_as_data.h \
|
||||
gvdb/gvdb-format.h \
|
||||
--
|
||||
2.13.1
|
||||
|
||||
|
||||
From e8cd3bc56e49a31380e516a611b81ddb171c06de Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 19 Dec 2015 14:59:42 +0000
|
||||
Subject: configure.ac: on Haiku
|
||||
|
||||
* don't use -pthread
|
||||
* use -lbe -lroot as thread related libs.
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 09fa3b4..6f23523 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -154,6 +154,9 @@ case "$host" in
|
||||
;;
|
||||
esac
|
||||
case $host in
|
||||
+ *-*-haiku*)
|
||||
+ LIBS="-lnetwork $LIBS"
|
||||
+ ;;
|
||||
*-*-linux*)
|
||||
glib_os_linux=yes
|
||||
;;
|
||||
@@ -1922,8 +1925,8 @@ AS_IF([ test x"$have_threads" = xposix], [
|
||||
# One of them does for most gcc versions and some other platforms/compilers
|
||||
# too and could be considered as the canonical way to go.
|
||||
case $host in
|
||||
- *-*-cygwin*|*-*-darwin*)
|
||||
- # skip cygwin and darwin -pthread or -pthreads test
|
||||
+ *-*-cygwin*|*-*-darwin*|*-*-haiku*)
|
||||
+ # skip cygwin, darwin and haiku -pthread or -pthreads test
|
||||
;;
|
||||
*-solaris*)
|
||||
# These compiler/linker flags work with both Sun Studio and gcc
|
||||
@@ -2088,6 +2091,15 @@ if test "x$G_THREAD_LIBS" = xerror; then
|
||||
AC_MSG_ERROR($LIBS_NOT_FOUND_1$have_threads$LIBS_NOT_FOUND_2)
|
||||
fi
|
||||
|
||||
+case $host in
|
||||
+ *-*-haiku*)
|
||||
+ G_THREAD_LIBS="-lbe -lroot"
|
||||
+ G_THREAD_LIBS_EXTRA="-L\$(top_builddir_full)/.libs"
|
||||
+ ;;
|
||||
+ *)
|
||||
+ ;;
|
||||
+esac
|
||||
+
|
||||
AC_MSG_CHECKING(thread related libraries)
|
||||
AC_MSG_RESULT($G_THREAD_LIBS)
|
||||
|
||||
--
|
||||
2.13.1
|
||||
|
||||
|
||||
From ebdda5ed9978ae6272df99f6e8cadf42f3a50e27 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 29 Jul 2017 12:13:00 +0200
|
||||
Subject: g_dbus_message_print: use B_PRIiDEV on Haiku
|
||||
|
||||
because Haiku doesn't define major() and minor()
|
||||
|
||||
diff --git a/gio/gdbusmessage.c b/gio/gdbusmessage.c
|
||||
index e80794f..7c68f57 100644
|
||||
--- a/gio/gdbusmessage.c
|
||||
+++ b/gio/gdbusmessage.c
|
||||
@@ -33,8 +33,12 @@
|
||||
#elif MAJOR_IN_SYSMACROS
|
||||
#include <sys/sysmacros.h>
|
||||
#else
|
||||
+#ifdef __HAIKU__
|
||||
+#include <SupportDefs.h>
|
||||
+#else
|
||||
#define MAJOR_MINOR_NOT_FOUND 1
|
||||
#endif
|
||||
+#endif
|
||||
|
||||
#include "gdbusutils.h"
|
||||
#include "gdbusmessage.h"
|
||||
@@ -3478,9 +3482,14 @@ g_dbus_message_print (GDBusMessage *message,
|
||||
if (fstat (fds[n], &statbuf) == 0)
|
||||
{
|
||||
#ifndef MAJOR_MINOR_NOT_FOUND
|
||||
+#ifdef __HAIKU__
|
||||
+ g_string_append_printf (fs, "%s" "dev=%" B_PRIiDEV, fs->len > 0 ? "," : "",
|
||||
+ statbuf.st_dev);
|
||||
+#else
|
||||
g_string_append_printf (fs, "%s" "dev=%d:%d", fs->len > 0 ? "," : "",
|
||||
major (statbuf.st_dev), minor (statbuf.st_dev));
|
||||
#endif
|
||||
+#endif
|
||||
g_string_append_printf (fs, "%s" "mode=0%o", fs->len > 0 ? "," : "",
|
||||
statbuf.st_mode);
|
||||
g_string_append_printf (fs, "%s" "ino=%" G_GUINT64_FORMAT, fs->len > 0 ? "," : "",
|
||||
@@ -3490,9 +3499,14 @@ g_dbus_message_print (GDBusMessage *message,
|
||||
g_string_append_printf (fs, "%s" "gid=%u", fs->len > 0 ? "," : "",
|
||||
(guint) statbuf.st_gid);
|
||||
#ifndef MAJOR_MINOR_NOT_FOUND
|
||||
+#ifdef __HAIKU__
|
||||
+ g_string_append_printf (fs, "%s" "rdev=%" B_PRIiDEV, fs->len > 0 ? "," : "",
|
||||
+ statbuf.st_rdev);
|
||||
+#else
|
||||
g_string_append_printf (fs, "%s" "rdev=%d:%d", fs->len > 0 ? "," : "",
|
||||
major (statbuf.st_rdev), minor (statbuf.st_rdev));
|
||||
#endif
|
||||
+#endif
|
||||
g_string_append_printf (fs, "%s" "size=%" G_GUINT64_FORMAT, fs->len > 0 ? "," : "",
|
||||
(guint64) statbuf.st_size);
|
||||
g_string_append_printf (fs, "%s" "atime=%" G_GUINT64_FORMAT, fs->len > 0 ? "," : "",
|
||||
--
|
||||
2.13.1
|
||||
|
||||
|
||||
From bca36b1e71dc29ed71b628f1b87917498a375147 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 29 Jul 2017 12:19:31 +0200
|
||||
Subject: gunixmounts.c: on Haiku
|
||||
|
||||
* define get_mtab_minitor_file() and _g_get_unix_mounts()
|
||||
* like Inerix, _g_get_unix_mount_points() calls _g_get_unix_mounts().
|
||||
|
||||
diff --git a/gio/gunixmounts.c b/gio/gunixmounts.c
|
||||
index ce6a2fc..dac4c05 100644
|
||||
--- a/gio/gunixmounts.c
|
||||
+++ b/gio/gunixmounts.c
|
||||
@@ -837,7 +837,18 @@ _g_get_unix_mounts (void)
|
||||
|
||||
return return_list;
|
||||
}
|
||||
+#elif defined(__HAIKU__)
|
||||
+static char *
|
||||
+get_mtab_monitor_file (void)
|
||||
+{
|
||||
+ return NULL;
|
||||
+}
|
||||
|
||||
+static GList *
|
||||
+_g_get_unix_mounts (void)
|
||||
+{
|
||||
+ return NULL;
|
||||
+}
|
||||
/* Common code {{{2 */
|
||||
#else
|
||||
#error No _g_get_unix_mounts() implementation for system
|
||||
@@ -1348,8 +1359,8 @@ _g_get_unix_mount_points (void)
|
||||
|
||||
return g_list_reverse (return_list);
|
||||
}
|
||||
-/* Interix {{{2 */
|
||||
-#elif defined(__INTERIX)
|
||||
+/* Interix, Haiku {{{2 */
|
||||
+#elif defined(__INTERIX) || defined(__HAIKU__)
|
||||
static GList *
|
||||
_g_get_unix_mount_points (void)
|
||||
{
|
||||
--
|
||||
2.13.1
|
||||
|
||||
|
||||
From cc4f7378d24f874c0483360b356f0a88f673d5cc Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 29 Jul 2017 12:32:14 +0200
|
||||
Subject: glib/gutils.c: on Haiku define load_user_special_dirs()
|
||||
|
||||
use find_directory() from SupportDefs.h
|
||||
|
||||
diff --git a/glib/gutils.c b/glib/gutils.c
|
||||
index 099bba5..7fbee2d 100644
|
||||
--- a/glib/gutils.c
|
||||
+++ b/glib/gutils.c
|
||||
@@ -69,6 +69,10 @@
|
||||
#include "gwin32.h"
|
||||
#endif
|
||||
|
||||
+#if defined(__HAIKU__)
|
||||
+#include <FindDirectory.h>
|
||||
+#include <fs_info.h>
|
||||
+#endif
|
||||
|
||||
/**
|
||||
* SECTION:misc_utils
|
||||
@@ -1431,6 +1435,35 @@ load_user_special_dirs (void)
|
||||
g_user_special_dirs[G_USER_DIRECTORY_VIDEOS] = find_folder (kMovieDocumentsFolderType);
|
||||
}
|
||||
|
||||
+#elif defined(__HAIKU__)
|
||||
+static void
|
||||
+load_user_special_dirs (void)
|
||||
+{
|
||||
+ char path[B_PATH_NAME_LENGTH + B_FILE_NAME_LENGTH];
|
||||
+
|
||||
+ dev_t volume = dev_for_path("/boot");
|
||||
+ if (find_directory(B_DESKTOP_DIRECTORY, volume, false, path, sizeof(path))
|
||||
+ == B_OK) {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DESKTOP] = g_strdup(path);
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOWNLOAD] = g_strdup(path);
|
||||
+ } else {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOCUMENTS] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DESKTOP] = NULL;
|
||||
+ }
|
||||
+
|
||||
+ if (find_directory(B_USER_DIRECTORY, volume, false, path, sizeof(path))
|
||||
+ == B_OK) {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOCUMENTS] = g_strdup(path);
|
||||
+ } else
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOWNLOAD] = NULL;
|
||||
+
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_MUSIC] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_PICTURES] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_PUBLIC_SHARE] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_TEMPLATES] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_VIDEOS] = NULL;
|
||||
+}
|
||||
+
|
||||
#elif defined(G_OS_WIN32)
|
||||
|
||||
static void
|
||||
--
|
||||
2.13.1
|
||||
|
||||
|
||||
From 10bb92c8389573bf0a4b42b42339da4bd75413c5 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Wed, 20 Sep 2017 18:09:43 +0200
|
||||
Subject: configure.ac: define G_OS_HAIKU
|
||||
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 6f23523..a09db90 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -3231,6 +3231,10 @@ g_pid_format="\"$glib_pid_format\""
|
||||
g_pollfd_format="\"$glib_pollfd_format\""
|
||||
|
||||
case $host in
|
||||
+ *-*-haiku*)
|
||||
+ glib_os="#define G_OS_UNIX
|
||||
+#define G_OS_HAIKU"
|
||||
+ ;;
|
||||
*-*-cygwin*)
|
||||
glib_os="#define G_OS_UNIX
|
||||
#define G_PLATFORM_WIN32
|
||||
--
|
||||
2.13.1
|
||||
|
||||
@@ -1,271 +0,0 @@
|
||||
From 55a17051755769cfea9ea4fea50f80be8887734c Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 19 Dec 2015 14:51:01 +0000
|
||||
Subject: glib_compile_schemas: links against gio, gobject and gmodule.
|
||||
|
||||
Otherwise build fails on Haiku.
|
||||
|
||||
diff --git a/gio/Makefile.am b/gio/Makefile.am
|
||||
index b2db995..c82f05c 100644
|
||||
--- a/gio/Makefile.am
|
||||
+++ b/gio/Makefile.am
|
||||
@@ -817,7 +817,11 @@ gio_querymodules_LDADD = libgio-2.0.la \
|
||||
gconstructor_as_data.h: $(top_srcdir)/glib/gconstructor.h data-to-c.pl
|
||||
$(AM_V_GEN) $(srcdir)/data-to-c.pl $(top_srcdir)/glib/gconstructor.h gconstructor_code > $@.tmp && mv $@.tmp $@
|
||||
|
||||
-glib_compile_schemas_LDADD = $(top_builddir)/glib/libglib-2.0.la
|
||||
+glib_compile_schemas_LDADD = libgio-2.0.la \
|
||||
+ $(top_builddir)/gobject/libgobject-2.0.la \
|
||||
+ $(top_builddir)/gmodule/libgmodule-2.0.la \
|
||||
+ $(top_builddir)/glib/libglib-2.0.la \
|
||||
+ $(NULL)
|
||||
glib_compile_schemas_SOURCES = \
|
||||
gconstructor_as_data.h \
|
||||
gvdb/gvdb-format.h \
|
||||
--
|
||||
2.13.1
|
||||
|
||||
|
||||
From e8cd3bc56e49a31380e516a611b81ddb171c06de Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 19 Dec 2015 14:59:42 +0000
|
||||
Subject: configure.ac: on Haiku
|
||||
|
||||
* don't use -pthread
|
||||
* use -lbe -lroot as thread related libs.
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 09fa3b4..6f23523 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -154,6 +154,9 @@ case "$host" in
|
||||
;;
|
||||
esac
|
||||
case $host in
|
||||
+ *-*-haiku*)
|
||||
+ LIBS="-lnetwork $LIBS"
|
||||
+ ;;
|
||||
*-*-linux*)
|
||||
glib_os_linux=yes
|
||||
;;
|
||||
@@ -1922,8 +1925,8 @@ AS_IF([ test x"$have_threads" = xposix], [
|
||||
# One of them does for most gcc versions and some other platforms/compilers
|
||||
# too and could be considered as the canonical way to go.
|
||||
case $host in
|
||||
- *-*-cygwin*|*-*-darwin*)
|
||||
- # skip cygwin and darwin -pthread or -pthreads test
|
||||
+ *-*-cygwin*|*-*-darwin*|*-*-haiku*)
|
||||
+ # skip cygwin, darwin and haiku -pthread or -pthreads test
|
||||
;;
|
||||
*-solaris*)
|
||||
# These compiler/linker flags work with both Sun Studio and gcc
|
||||
@@ -2088,6 +2091,15 @@ if test "x$G_THREAD_LIBS" = xerror; then
|
||||
AC_MSG_ERROR($LIBS_NOT_FOUND_1$have_threads$LIBS_NOT_FOUND_2)
|
||||
fi
|
||||
|
||||
+case $host in
|
||||
+ *-*-haiku*)
|
||||
+ G_THREAD_LIBS="-lbe -lroot"
|
||||
+ G_THREAD_LIBS_EXTRA="-L\$(top_builddir_full)/.libs"
|
||||
+ ;;
|
||||
+ *)
|
||||
+ ;;
|
||||
+esac
|
||||
+
|
||||
AC_MSG_CHECKING(thread related libraries)
|
||||
AC_MSG_RESULT($G_THREAD_LIBS)
|
||||
|
||||
--
|
||||
2.13.1
|
||||
|
||||
|
||||
From ebdda5ed9978ae6272df99f6e8cadf42f3a50e27 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 29 Jul 2017 12:13:00 +0200
|
||||
Subject: g_dbus_message_print: use B_PRIiDEV on Haiku
|
||||
|
||||
because Haiku doesn't define major() and minor()
|
||||
|
||||
diff --git a/gio/gdbusmessage.c b/gio/gdbusmessage.c
|
||||
index e80794f..7c68f57 100644
|
||||
--- a/gio/gdbusmessage.c
|
||||
+++ b/gio/gdbusmessage.c
|
||||
@@ -33,8 +33,12 @@
|
||||
#elif MAJOR_IN_SYSMACROS
|
||||
#include <sys/sysmacros.h>
|
||||
#else
|
||||
+#ifdef __HAIKU__
|
||||
+#include <SupportDefs.h>
|
||||
+#else
|
||||
#define MAJOR_MINOR_NOT_FOUND 1
|
||||
#endif
|
||||
+#endif
|
||||
|
||||
#include "gdbusutils.h"
|
||||
#include "gdbusmessage.h"
|
||||
@@ -3478,9 +3482,14 @@ g_dbus_message_print (GDBusMessage *message,
|
||||
if (fstat (fds[n], &statbuf) == 0)
|
||||
{
|
||||
#ifndef MAJOR_MINOR_NOT_FOUND
|
||||
+#ifdef __HAIKU__
|
||||
+ g_string_append_printf (fs, "%s" "dev=%" B_PRIiDEV, fs->len > 0 ? "," : "",
|
||||
+ statbuf.st_dev);
|
||||
+#else
|
||||
g_string_append_printf (fs, "%s" "dev=%d:%d", fs->len > 0 ? "," : "",
|
||||
major (statbuf.st_dev), minor (statbuf.st_dev));
|
||||
#endif
|
||||
+#endif
|
||||
g_string_append_printf (fs, "%s" "mode=0%o", fs->len > 0 ? "," : "",
|
||||
statbuf.st_mode);
|
||||
g_string_append_printf (fs, "%s" "ino=%" G_GUINT64_FORMAT, fs->len > 0 ? "," : "",
|
||||
@@ -3490,9 +3499,14 @@ g_dbus_message_print (GDBusMessage *message,
|
||||
g_string_append_printf (fs, "%s" "gid=%u", fs->len > 0 ? "," : "",
|
||||
(guint) statbuf.st_gid);
|
||||
#ifndef MAJOR_MINOR_NOT_FOUND
|
||||
+#ifdef __HAIKU__
|
||||
+ g_string_append_printf (fs, "%s" "rdev=%" B_PRIiDEV, fs->len > 0 ? "," : "",
|
||||
+ statbuf.st_rdev);
|
||||
+#else
|
||||
g_string_append_printf (fs, "%s" "rdev=%d:%d", fs->len > 0 ? "," : "",
|
||||
major (statbuf.st_rdev), minor (statbuf.st_rdev));
|
||||
#endif
|
||||
+#endif
|
||||
g_string_append_printf (fs, "%s" "size=%" G_GUINT64_FORMAT, fs->len > 0 ? "," : "",
|
||||
(guint64) statbuf.st_size);
|
||||
g_string_append_printf (fs, "%s" "atime=%" G_GUINT64_FORMAT, fs->len > 0 ? "," : "",
|
||||
--
|
||||
2.13.1
|
||||
|
||||
|
||||
From bca36b1e71dc29ed71b628f1b87917498a375147 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 29 Jul 2017 12:19:31 +0200
|
||||
Subject: gunixmounts.c: on Haiku
|
||||
|
||||
* define get_mtab_minitor_file() and _g_get_unix_mounts()
|
||||
* like Inerix, _g_get_unix_mount_points() calls _g_get_unix_mounts().
|
||||
|
||||
diff --git a/gio/gunixmounts.c b/gio/gunixmounts.c
|
||||
index ce6a2fc..dac4c05 100644
|
||||
--- a/gio/gunixmounts.c
|
||||
+++ b/gio/gunixmounts.c
|
||||
@@ -837,7 +837,18 @@ _g_get_unix_mounts (void)
|
||||
|
||||
return return_list;
|
||||
}
|
||||
+#elif defined(__HAIKU__)
|
||||
+static char *
|
||||
+get_mtab_monitor_file (void)
|
||||
+{
|
||||
+ return NULL;
|
||||
+}
|
||||
|
||||
+static GList *
|
||||
+_g_get_unix_mounts (void)
|
||||
+{
|
||||
+ return NULL;
|
||||
+}
|
||||
/* Common code {{{2 */
|
||||
#else
|
||||
#error No _g_get_unix_mounts() implementation for system
|
||||
@@ -1348,8 +1359,8 @@ _g_get_unix_mount_points (void)
|
||||
|
||||
return g_list_reverse (return_list);
|
||||
}
|
||||
-/* Interix {{{2 */
|
||||
-#elif defined(__INTERIX)
|
||||
+/* Interix, Haiku {{{2 */
|
||||
+#elif defined(__INTERIX) || defined(__HAIKU__)
|
||||
static GList *
|
||||
_g_get_unix_mount_points (void)
|
||||
{
|
||||
--
|
||||
2.13.1
|
||||
|
||||
|
||||
From cc4f7378d24f874c0483360b356f0a88f673d5cc Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 29 Jul 2017 12:32:14 +0200
|
||||
Subject: glib/gutils.c: on Haiku define load_user_special_dirs()
|
||||
|
||||
use find_directory() from SupportDefs.h
|
||||
|
||||
diff --git a/glib/gutils.c b/glib/gutils.c
|
||||
index 099bba5..7fbee2d 100644
|
||||
--- a/glib/gutils.c
|
||||
+++ b/glib/gutils.c
|
||||
@@ -69,6 +69,10 @@
|
||||
#include "gwin32.h"
|
||||
#endif
|
||||
|
||||
+#if defined(__HAIKU__)
|
||||
+#include <FindDirectory.h>
|
||||
+#include <fs_info.h>
|
||||
+#endif
|
||||
|
||||
/**
|
||||
* SECTION:misc_utils
|
||||
@@ -1431,6 +1435,35 @@ load_user_special_dirs (void)
|
||||
g_user_special_dirs[G_USER_DIRECTORY_VIDEOS] = find_folder (kMovieDocumentsFolderType);
|
||||
}
|
||||
|
||||
+#elif defined(__HAIKU__)
|
||||
+static void
|
||||
+load_user_special_dirs (void)
|
||||
+{
|
||||
+ char path[B_PATH_NAME_LENGTH + B_FILE_NAME_LENGTH];
|
||||
+
|
||||
+ dev_t volume = dev_for_path("/boot");
|
||||
+ if (find_directory(B_DESKTOP_DIRECTORY, volume, false, path, sizeof(path))
|
||||
+ == B_OK) {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DESKTOP] = g_strdup(path);
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOWNLOAD] = g_strdup(path);
|
||||
+ } else {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOCUMENTS] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DESKTOP] = NULL;
|
||||
+ }
|
||||
+
|
||||
+ if (find_directory(B_USER_DIRECTORY, volume, false, path, sizeof(path))
|
||||
+ == B_OK) {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOCUMENTS] = g_strdup(path);
|
||||
+ } else
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOWNLOAD] = NULL;
|
||||
+
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_MUSIC] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_PICTURES] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_PUBLIC_SHARE] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_TEMPLATES] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_VIDEOS] = NULL;
|
||||
+}
|
||||
+
|
||||
#elif defined(G_OS_WIN32)
|
||||
|
||||
static void
|
||||
--
|
||||
2.13.1
|
||||
|
||||
|
||||
From 10bb92c8389573bf0a4b42b42339da4bd75413c5 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Wed, 20 Sep 2017 18:09:43 +0200
|
||||
Subject: configure.ac: define G_OS_HAIKU
|
||||
|
||||
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 6f23523..a09db90 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -3231,6 +3231,10 @@ g_pid_format="\"$glib_pid_format\""
|
||||
g_pollfd_format="\"$glib_pollfd_format\""
|
||||
|
||||
case $host in
|
||||
+ *-*-haiku*)
|
||||
+ glib_os="#define G_OS_UNIX
|
||||
+#define G_OS_HAIKU"
|
||||
+ ;;
|
||||
*-*-cygwin*)
|
||||
glib_os="#define G_OS_UNIX
|
||||
#define G_PLATFORM_WIN32
|
||||
--
|
||||
2.13.1
|
||||
|
||||
@@ -1,289 +0,0 @@
|
||||
From e1b248c02e0259f4f0b38c13596d24ce233fbdfb Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 29 Jul 2017 12:13:00 +0200
|
||||
Subject: g_dbus_message_print: use B_PRIiDEV on Haiku
|
||||
|
||||
because Haiku doesn't define major() and minor()
|
||||
|
||||
diff --git a/gio/gdbusmessage.c b/gio/gdbusmessage.c
|
||||
index 852a704..968d33f 100644
|
||||
--- a/gio/gdbusmessage.c
|
||||
+++ b/gio/gdbusmessage.c
|
||||
@@ -35,8 +35,12 @@
|
||||
#elif MAJOR_IN_TYPES
|
||||
#include <sys/types.h>
|
||||
#else
|
||||
+#ifdef __HAIKU__
|
||||
+#include <SupportDefs.h>
|
||||
+#else
|
||||
#define MAJOR_MINOR_NOT_FOUND 1
|
||||
#endif
|
||||
+#endif
|
||||
|
||||
#include "gdbusutils.h"
|
||||
#include "gdbusmessage.h"
|
||||
@@ -3514,8 +3518,14 @@ g_dbus_message_print (GDBusMessage *message,
|
||||
if (fstat (fds[n], &statbuf) == 0)
|
||||
{
|
||||
#ifndef MAJOR_MINOR_NOT_FOUND
|
||||
+#ifdef __HAIKU__
|
||||
+ g_string_append_printf (fs, "%s" "dev=%" B_PRIiDEV, fs->len > 0 ? "," : "",
|
||||
+ statbuf.st_dev);
|
||||
+#else
|
||||
+
|
||||
g_string_append_printf (fs, "%s" "dev=%d:%d", fs->len > 0 ? "," : "",
|
||||
(gint) major (statbuf.st_dev), (gint) minor (statbuf.st_dev));
|
||||
+#endif
|
||||
#endif
|
||||
g_string_append_printf (fs, "%s" "mode=0%o", fs->len > 0 ? "," : "",
|
||||
(guint) statbuf.st_mode);
|
||||
@@ -3526,9 +3536,14 @@ g_dbus_message_print (GDBusMessage *message,
|
||||
g_string_append_printf (fs, "%s" "gid=%u", fs->len > 0 ? "," : "",
|
||||
(guint) statbuf.st_gid);
|
||||
#ifndef MAJOR_MINOR_NOT_FOUND
|
||||
+#ifdef __HAIKU__
|
||||
+ g_string_append_printf (fs, "%s" "rdev=%" B_PRIiDEV, fs->len > 0 ? "," : "",
|
||||
+ statbuf.st_rdev);
|
||||
+#else
|
||||
g_string_append_printf (fs, "%s" "rdev=%d:%d", fs->len > 0 ? "," : "",
|
||||
(gint) major (statbuf.st_rdev), (gint) minor (statbuf.st_rdev));
|
||||
#endif
|
||||
+#endif
|
||||
g_string_append_printf (fs, "%s" "size=%" G_GUINT64_FORMAT, fs->len > 0 ? "," : "",
|
||||
(guint64) statbuf.st_size);
|
||||
g_string_append_printf (fs, "%s" "atime=%" G_GUINT64_FORMAT, fs->len > 0 ? "," : "",
|
||||
--
|
||||
2.30.2
|
||||
|
||||
|
||||
From 8407a5ee77a8b0c24e7876e799c5846785d63127 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 29 Jul 2017 12:19:31 +0200
|
||||
Subject: gunixmounts.c: on Haiku
|
||||
|
||||
* define get_mtab_minitor_file() and _g_get_unix_mounts()
|
||||
* like Inerix, _g_get_unix_mount_points() calls _g_get_unix_mounts().
|
||||
|
||||
diff --git a/gio/gunixmounts.c b/gio/gunixmounts.c
|
||||
index cf73fe5..88795f4 100644
|
||||
--- a/gio/gunixmounts.c
|
||||
+++ b/gio/gunixmounts.c
|
||||
@@ -948,7 +948,18 @@ _g_get_unix_mounts (void)
|
||||
|
||||
return return_list;
|
||||
}
|
||||
+#elif defined(__HAIKU__)
|
||||
+static char *
|
||||
+get_mtab_monitor_file (void)
|
||||
+{
|
||||
+ return NULL;
|
||||
+}
|
||||
|
||||
+static GList *
|
||||
+_g_get_unix_mounts (void)
|
||||
+{
|
||||
+ return NULL;
|
||||
+}
|
||||
/* Common code {{{2 */
|
||||
#else
|
||||
#error No _g_get_unix_mounts() implementation for system
|
||||
@@ -1464,8 +1475,8 @@ _g_get_unix_mount_points (void)
|
||||
|
||||
return g_list_reverse (return_list);
|
||||
}
|
||||
-/* Interix {{{2 */
|
||||
-#elif defined(__INTERIX)
|
||||
+/* Interix, Haiku {{{2 */
|
||||
+#elif defined(__INTERIX) || defined(__HAIKU__)
|
||||
static GList *
|
||||
_g_get_unix_mount_points (void)
|
||||
{
|
||||
--
|
||||
2.30.2
|
||||
|
||||
|
||||
From 3cb1e89ee25160bd94ea15ca2324dec90d03f1bd Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 29 Jul 2017 12:32:14 +0200
|
||||
Subject: glib/gutils.c: on Haiku define load_user_special_dirs()
|
||||
|
||||
use find_directory() from SupportDefs.h
|
||||
|
||||
diff --git a/glib/gutils.c b/glib/gutils.c
|
||||
index 988d0a5..7248ead 100644
|
||||
--- a/glib/gutils.c
|
||||
+++ b/glib/gutils.c
|
||||
@@ -74,6 +74,10 @@
|
||||
#include "gwin32.h"
|
||||
#endif
|
||||
|
||||
+#if defined(__HAIKU__)
|
||||
+#include <FindDirectory.h>
|
||||
+#include <fs_info.h>
|
||||
+#endif
|
||||
|
||||
/**
|
||||
* SECTION:misc_utils
|
||||
@@ -1513,6 +1517,35 @@ load_user_special_dirs (void)
|
||||
load_user_special_dirs_macos (g_user_special_dirs);
|
||||
}
|
||||
|
||||
+#elif defined(__HAIKU__)
|
||||
+static void
|
||||
+load_user_special_dirs (void)
|
||||
+{
|
||||
+ char path[B_PATH_NAME_LENGTH + B_FILE_NAME_LENGTH];
|
||||
+
|
||||
+ dev_t volume = dev_for_path("/boot");
|
||||
+ if (find_directory(B_DESKTOP_DIRECTORY, volume, false, path, sizeof(path))
|
||||
+ == B_OK) {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DESKTOP] = g_strdup(path);
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOWNLOAD] = g_strdup(path);
|
||||
+ } else {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOCUMENTS] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DESKTOP] = NULL;
|
||||
+ }
|
||||
+
|
||||
+ if (find_directory(B_USER_DIRECTORY, volume, false, path, sizeof(path))
|
||||
+ == B_OK) {
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOCUMENTS] = g_strdup(path);
|
||||
+ } else
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_DOWNLOAD] = NULL;
|
||||
+
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_MUSIC] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_PICTURES] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_PUBLIC_SHARE] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_TEMPLATES] = NULL;
|
||||
+ g_user_special_dirs[G_USER_DIRECTORY_VIDEOS] = NULL;
|
||||
+}
|
||||
+
|
||||
#elif defined(G_OS_WIN32)
|
||||
|
||||
static void
|
||||
--
|
||||
2.30.2
|
||||
|
||||
|
||||
From e7b90c2f26d9a6b472c60ba7639ffa0b62a1c229 Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 7 Sep 2019 15:24:28 +0200
|
||||
Subject: _SC_HOST_NAME_MAX is not defined on H1B1
|
||||
|
||||
|
||||
diff --git a/glib/gutils.c b/glib/gutils.c
|
||||
index 7248ead..a27c429 100644
|
||||
--- a/glib/gutils.c
|
||||
+++ b/glib/gutils.c
|
||||
@@ -996,7 +996,11 @@ g_get_host_name (void)
|
||||
const gsize size_large = (gsize) 256 * 256;
|
||||
gchar *tmp;
|
||||
|
||||
+#ifdef __HAIKU__
|
||||
+ max = 0;
|
||||
+#else
|
||||
max = sysconf (_SC_HOST_NAME_MAX);
|
||||
+#endif
|
||||
if (max > 0 && max <= G_MAXSIZE - 1)
|
||||
size = (gsize) max + 1;
|
||||
else
|
||||
--
|
||||
2.30.2
|
||||
|
||||
|
||||
From b84a08f536145a49ed19aba44a504f4526dd892c Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 23 Nov 2019 20:10:10 +0100
|
||||
Subject: Haiku patch for x86
|
||||
|
||||
|
||||
diff --git a/meson.build b/meson.build
|
||||
index 717d1bc..5b25886 100644
|
||||
--- a/meson.build
|
||||
+++ b/meson.build
|
||||
@@ -1324,14 +1324,14 @@ if sizet_size == short_size
|
||||
glibconfig_conf.set_quoted('gsize_format', 'hu')
|
||||
glibconfig_conf.set_quoted('gssize_format', 'hi')
|
||||
glibconfig_conf.set('glib_msize_type', 'SHRT')
|
||||
-elif sizet_size == int_size
|
||||
+elif sizet_size == int_size and host_system != 'haiku'
|
||||
glibconfig_conf.set('glib_size_type_define', 'int')
|
||||
glibconfig_conf.set_quoted('gsize_modifier', '')
|
||||
glibconfig_conf.set_quoted('gssize_modifier', '')
|
||||
glibconfig_conf.set_quoted('gsize_format', 'u')
|
||||
glibconfig_conf.set_quoted('gssize_format', 'i')
|
||||
glibconfig_conf.set('glib_msize_type', 'INT')
|
||||
-elif sizet_size == long_size
|
||||
+elif sizet_size == long_size or host_system == 'haiku'
|
||||
glibconfig_conf.set('glib_size_type_define', 'long')
|
||||
glibconfig_conf.set_quoted('gsize_modifier', 'l')
|
||||
glibconfig_conf.set_quoted('gssize_modifier', 'l')
|
||||
diff --git a/tests/mapping-test.c b/tests/mapping-test.c
|
||||
index ad776fa..49d2ea4 100644
|
||||
--- a/tests/mapping-test.c
|
||||
+++ b/tests/mapping-test.c
|
||||
@@ -182,6 +182,10 @@ test_private (void)
|
||||
g_message ("test_private: ok");
|
||||
}
|
||||
|
||||
+#ifdef __HAIKU__
|
||||
+#include <SupportDefs.h>
|
||||
+#endif
|
||||
+
|
||||
static void
|
||||
test_child_private (gchar *argv0)
|
||||
{
|
||||
@@ -208,7 +212,11 @@ test_child_private (gchar *argv0)
|
||||
signal (SIGUSR1, handle_usr1);
|
||||
#endif
|
||||
|
||||
+#ifdef __HAIKU__
|
||||
+ g_snprintf (pid, sizeof(pid), B_PRId32, getpid ());
|
||||
+#else
|
||||
g_snprintf (pid, sizeof(pid), "%d", getpid ());
|
||||
+#endif
|
||||
child_argv[0] = argv0;
|
||||
child_argv[1] = "mapchild";
|
||||
child_argv[2] = pid;
|
||||
--
|
||||
2.30.2
|
||||
|
||||
|
||||
From 485728e688a8a89e84b3b8cf68a7e4871804e39f Mon Sep 17 00:00:00 2001
|
||||
From: Gerasim Troeglazov <3dEyes@gmail.com>
|
||||
Date: Tue, 17 Aug 2021 08:29:48 +0000
|
||||
Subject: Fix network detection
|
||||
|
||||
|
||||
diff --git a/gio/meson.build b/gio/meson.build
|
||||
index 9a9e621..32d7d67 100644
|
||||
--- a/gio/meson.build
|
||||
+++ b/gio/meson.build
|
||||
@@ -26,6 +26,7 @@ elif not host_system.contains('android')
|
||||
int qclass = C_IN;''',
|
||||
name : 'C_IN in public headers (no arpa/nameser_compat.h needed)')
|
||||
if cc.compiles('''#include <sys/types.h>
|
||||
+ #include <stdint.h>
|
||||
#include <arpa/nameser.h>
|
||||
#include <arpa/nameser_compat.h>
|
||||
int qclass = C_IN;''',
|
||||
@@ -46,6 +47,7 @@ if host_system != 'windows'
|
||||
return res_query("test", 0, 0, (void *)0, 0);
|
||||
}'''
|
||||
res_query_test_full = '''#include <sys/types.h>
|
||||
+ #include <stdint.h>
|
||||
#include <netinet/in.h>
|
||||
#include <arpa/nameser.h>
|
||||
''' + res_query_test
|
||||
@@ -56,6 +58,9 @@ if host_system != 'windows'
|
||||
elif cc.links(res_query_test, args : '-lbind', name : 'res_query() in -lbind')
|
||||
network_libs += [ cc.find_library('bind') ]
|
||||
network_args += [ '-lbind' ]
|
||||
+ elif cc.links(res_query_test, args : '-lnetwork', name : 'res_query() in -lnetwork')
|
||||
+ network_libs += [ cc.find_library('network') ]
|
||||
+ network_args += [ '-lnetwork' ]
|
||||
else
|
||||
error('Could not find res_query()')
|
||||
endif
|
||||
--
|
||||
2.30.2
|
||||
|
||||
Reference in New Issue
Block a user