From e29523ab5202db00dc66acd4f4d0aa1c07927323 Mon Sep 17 00:00:00 2001 From: Robin Gareus Date: Sun, 9 Nov 2025 20:29:02 +0100 Subject: [PATCH] Update YTK unistd.h checks --- libs/tk/ydk-pixbuf/config.h | 3 --- libs/tk/ydk-pixbuf/wscript | 1 + libs/tk/ydk/config.h | 3 --- libs/tk/ydk/wscript | 1 + libs/tk/ytk/config.h | 3 --- libs/tk/ytk/wscript | 1 + 6 files changed, 3 insertions(+), 9 deletions(-) diff --git a/libs/tk/ydk-pixbuf/config.h b/libs/tk/ydk-pixbuf/config.h index 6544fb2828..1752486c8d 100644 --- a/libs/tk/ydk-pixbuf/config.h +++ b/libs/tk/ydk-pixbuf/config.h @@ -23,9 +23,6 @@ /* Define to 1 if sys/systeminfo.h is available */ /* #undef HAVE_SYS_SYSTEMINFO_H */ -/* Define to 1 if you have the header file. */ -#define HAVE_UNISTD_H 1 - /* Define to the version of this package. */ #define PACKAGE_VERSION "2.31.1" diff --git a/libs/tk/ydk-pixbuf/wscript b/libs/tk/ydk-pixbuf/wscript index 5bac6e5a7d..9d480085c5 100644 --- a/libs/tk/ydk-pixbuf/wscript +++ b/libs/tk/ydk-pixbuf/wscript @@ -37,6 +37,7 @@ def configure(conf): autowaf.check_pkg(conf, 'gio-2.0', uselib_store='GIO', atleast_version='2.2', mandatory=True) autowaf.check_pkg(conf, 'gobject-2.0', uselib_store='GOBJECT', mandatory=True) autowaf.check_pkg(conf, 'libpng', uselib_store='LIBPNG', mandatory=True) + conf.check(header_name='unistd.h', define_name='HAVE_UNISTD_H',mandatory=False) def build(bld): obj = bld.shlib(features = 'c cshlib', source=libydkpixbuf_sources) diff --git a/libs/tk/ydk/config.h b/libs/tk/ydk/config.h index ba4b54730d..484758b87b 100644 --- a/libs/tk/ydk/config.h +++ b/libs/tk/ydk/config.h @@ -76,9 +76,6 @@ /* Define to 1 if sys/systeminfo.h is available */ /* #undef HAVE_SYS_SYSTEMINFO_H */ -/* Define to 1 if you have the header file. */ -#define HAVE_UNISTD_H 1 - /* Have wchar.h include file */ #define HAVE_WCHAR_H 1 diff --git a/libs/tk/ydk/wscript b/libs/tk/ydk/wscript index ecff3c21cf..04c2fe314a 100644 --- a/libs/tk/ydk/wscript +++ b/libs/tk/ydk/wscript @@ -164,6 +164,7 @@ def configure(conf): lib='Xinerama', uselib_store="XINERAMA", define_name='HAVE_XFREE_XINERAMA', execute = False, mandatory=False) autowaf.check_pkg(conf, 'xi', uselib_store='XINPUT2', mandatory=False, atleast_version='1.7.10') + conf.check(header_name='unistd.h', define_name='HAVE_UNISTD_H',mandatory=False) def build(bld): obj = bld.shlib(features = 'c cshlib') diff --git a/libs/tk/ytk/config.h b/libs/tk/ytk/config.h index d913bc1ee3..b28511f7b0 100644 --- a/libs/tk/ytk/config.h +++ b/libs/tk/ytk/config.h @@ -77,9 +77,6 @@ /* Define to 1 if sys/systeminfo.h is available */ /* #undef HAVE_SYS_SYSTEMINFO_H */ -/* Define to 1 if you have the header file. */ -#define HAVE_UNISTD_H 1 - /* Have wchar.h include file */ #define HAVE_WCHAR_H 1 diff --git a/libs/tk/ytk/wscript b/libs/tk/ytk/wscript index b9615a8b4b..b0b93ee855 100644 --- a/libs/tk/ytk/wscript +++ b/libs/tk/ytk/wscript @@ -266,6 +266,7 @@ def configure(conf): if conf.env['build_target'] != 'mingw' and conf.env['build_target'] != 'msvc' and sys.platform != 'darwin': # Linux autowaf.check_pkg(conf, 'x11', uselib_store='X11', system=True, mandatory=True) autowaf.check_pkg(conf, 'xext', uselib_store='XEXT', system=True, mandatory=True) + conf.check(header_name='unistd.h', define_name='HAVE_UNISTD_H',mandatory=False) def build(bld): obj = bld.shlib(features = 'c cshlib')