diff options
author | Ismael Luceno | 2022-08-08 00:00:35 +0200 |
---|---|---|
committer | Ismael Luceno | 2022-08-08 02:01:27 +0200 |
commit | c2710f4c20f445f7ee7880d5c26470b1c1951b23 (patch) | |
tree | 4b9f5d7956057050d1723fdd1b601d973659bca6 /libs | |
parent | 27ffb4188b35269387c8953fc0f4370cb7b1a3c9 (diff) |
glib: Fix function inlining with newer GCC
Diffstat (limited to 'libs')
-rw-r--r-- | libs/glib/HISTORY | 4 | ||||
-rwxr-xr-x | libs/glib/PRE_BUILD | 1 | ||||
-rw-r--r-- | libs/glib/patches/0001-Fix-function-inlining-with-newer-GCC.patch | 38 |
3 files changed, 43 insertions, 0 deletions
diff --git a/libs/glib/HISTORY b/libs/glib/HISTORY index 82cc1cad53..ddabdeecee 100644 --- a/libs/glib/HISTORY +++ b/libs/glib/HISTORY @@ -1,3 +1,7 @@ +2022-08-08 Ismael Luceno <ismael@sourcemage.org> + * PRE_BUILD, patches/0001-Fix-function-inlining-with-newer-GCC.patch: + Fixed glib.h header for newer GCC + 2020-12-19 Ismael Luceno <ismael@sourcemage.org> * BUILD, PRE_BUILD: Moved patching to PRE_BUILD * PRE_BUILD: Added fix for poll.h include diff --git a/libs/glib/PRE_BUILD b/libs/glib/PRE_BUILD index cd6c9c392a..ac250417c1 100755 --- a/libs/glib/PRE_BUILD +++ b/libs/glib/PRE_BUILD @@ -1,5 +1,6 @@ default_pre_build && cd "$SOURCE_DIRECTORY" && +apply_patch_dir patches && patch -p0 < $SPELL_DIRECTORY/gcc.diff && patch -p0 < $SPELL_DIRECTORY/config.sub.patch && sedit '/^#include "glib\.h"/a#include <poll.h>' gmain.c diff --git a/libs/glib/patches/0001-Fix-function-inlining-with-newer-GCC.patch b/libs/glib/patches/0001-Fix-function-inlining-with-newer-GCC.patch new file mode 100644 index 0000000000..1ec62cfbdd --- /dev/null +++ b/libs/glib/patches/0001-Fix-function-inlining-with-newer-GCC.patch @@ -0,0 +1,38 @@ +From df1173155585281dc58d054c3d0905a6241a0531 Mon Sep 17 00:00:00 2001 +From: Ismael Luceno <ismael@iodev.co.uk> +Date: Sun, 7 Aug 2022 23:58:29 +0200 +Subject: [PATCH] Fix function inlining with newer GCC + +Signed-off-by: Ismael Luceno <ismael@iodev.co.uk> +--- + glib.h | 9 --------- + 1 file changed, 9 deletions(-) + +diff --git a/glib.h b/glib.h +index b83cf5db3504..f3c36b0cc13c 100644 +--- a/glib.h ++++ b/glib.h +@@ -202,20 +202,11 @@ extern "C" { + # endif + #endif + #ifndef G_INLINE_FUNC +-# ifdef __GNUC__ +-# ifdef __OPTIMIZE__ +-# define G_INLINE_FUNC extern inline +-# else +-# undef G_CAN_INLINE +-# define G_INLINE_FUNC extern +-# endif +-# else /* !__GNUC__ */ + # ifdef G_CAN_INLINE + # define G_INLINE_FUNC static inline + # else + # define G_INLINE_FUNC extern + # endif +-# endif /* !__GNUC__ */ + #endif /* !G_INLINE_FUNC */ + + +-- +2.37.1 + |