mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-02-28 21:22:11 +01:00
only define _XOPEN_SOURCE to 600 to get at posix_memalign() in case we
Tue Feb 14 17:00:43 2006 Tim Janik <timj@imendio.com> * glib/gslice.c: only define _XOPEN_SOURCE to 600 to get at posix_memalign() in case we actually are going to use it, because we detected a compliant implementation (#328997). * configure.in (enable_included_printf): don't include malloc.h when testing for posix_memalign() funcitonality, since this may break the test on some systems (#328997).
This commit is contained in:
parent
16d640b06c
commit
8a8f185feb
10
ChangeLog
10
ChangeLog
@ -1,3 +1,13 @@
|
|||||||
|
Tue Feb 14 17:00:43 2006 Tim Janik <timj@imendio.com>
|
||||||
|
|
||||||
|
* glib/gslice.c: only define _XOPEN_SOURCE to 600 to get at
|
||||||
|
posix_memalign() in case we actually are going to use it, because
|
||||||
|
we detected a compliant implementation (#328997).
|
||||||
|
|
||||||
|
* configure.in (enable_included_printf): don't include malloc.h when
|
||||||
|
testing for posix_memalign() funcitonality, since this may break the
|
||||||
|
test on some systems (#328997).
|
||||||
|
|
||||||
2006-02-14 Matthias Clasen <mclasen@redhat.com>
|
2006-02-14 Matthias Clasen <mclasen@redhat.com>
|
||||||
|
|
||||||
* glib/gstrfuncs.c: Improve docs.
|
* glib/gstrfuncs.c: Improve docs.
|
||||||
|
@ -1,3 +1,13 @@
|
|||||||
|
Tue Feb 14 17:00:43 2006 Tim Janik <timj@imendio.com>
|
||||||
|
|
||||||
|
* glib/gslice.c: only define _XOPEN_SOURCE to 600 to get at
|
||||||
|
posix_memalign() in case we actually are going to use it, because
|
||||||
|
we detected a compliant implementation (#328997).
|
||||||
|
|
||||||
|
* configure.in (enable_included_printf): don't include malloc.h when
|
||||||
|
testing for posix_memalign() funcitonality, since this may break the
|
||||||
|
test on some systems (#328997).
|
||||||
|
|
||||||
2006-02-14 Matthias Clasen <mclasen@redhat.com>
|
2006-02-14 Matthias Clasen <mclasen@redhat.com>
|
||||||
|
|
||||||
* glib/gstrfuncs.c: Improve docs.
|
* glib/gstrfuncs.c: Improve docs.
|
||||||
|
@ -1,3 +1,13 @@
|
|||||||
|
Tue Feb 14 17:00:43 2006 Tim Janik <timj@imendio.com>
|
||||||
|
|
||||||
|
* glib/gslice.c: only define _XOPEN_SOURCE to 600 to get at
|
||||||
|
posix_memalign() in case we actually are going to use it, because
|
||||||
|
we detected a compliant implementation (#328997).
|
||||||
|
|
||||||
|
* configure.in (enable_included_printf): don't include malloc.h when
|
||||||
|
testing for posix_memalign() funcitonality, since this may break the
|
||||||
|
test on some systems (#328997).
|
||||||
|
|
||||||
2006-02-14 Matthias Clasen <mclasen@redhat.com>
|
2006-02-14 Matthias Clasen <mclasen@redhat.com>
|
||||||
|
|
||||||
* glib/gstrfuncs.c: Improve docs.
|
* glib/gstrfuncs.c: Improve docs.
|
||||||
|
@ -1028,8 +1028,8 @@ AC_CACHE_VAL(glib_cv_compliant_posix_memalign,[
|
|||||||
if test "$ac_cv_func_posix_memalign" = "yes" ; then
|
if test "$ac_cv_func_posix_memalign" = "yes" ; then
|
||||||
AC_TRY_RUN([
|
AC_TRY_RUN([
|
||||||
#define _XOPEN_SOURCE 600
|
#define _XOPEN_SOURCE 600
|
||||||
#include <stdlib.h>
|
#include <stdlib.h> /* posix_memalign() should be defined here */
|
||||||
#include <malloc.h>
|
/* some systems break if #include <malloc.h> used */
|
||||||
static void test_memalign (size_t boundary, size_t size) {
|
static void test_memalign (size_t boundary, size_t size) {
|
||||||
void *mem = 0;
|
void *mem = 0;
|
||||||
if (posix_memalign (&mem, boundary, size) != 0 || !mem)
|
if (posix_memalign (&mem, boundary, size) != 0 || !mem)
|
||||||
|
@ -20,7 +20,11 @@
|
|||||||
|
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
|
|
||||||
#ifdef HAVE_POSIX_MEMALIGN
|
#if defined HAVE_POSIX_MEMALIGN && defined POSIX_MEMALIGN_WITH_COMPLIANT_ALLOCS
|
||||||
|
# define HAVE_COMPLIANT_POSIX_MEMALIGN 1
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef HAVE_COMPLIANT_POSIX_MEMALIGN
|
||||||
#define _XOPEN_SOURCE 600 /* posix_memalign() */
|
#define _XOPEN_SOURCE 600 /* posix_memalign() */
|
||||||
#endif
|
#endif
|
||||||
#include <stdlib.h> /* posix_memalign() */
|
#include <stdlib.h> /* posix_memalign() */
|
||||||
@ -38,10 +42,6 @@
|
|||||||
#include <process.h>
|
#include <process.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined HAVE_POSIX_MEMALIGN && defined POSIX_MEMALIGN_WITH_COMPLIANT_ALLOCS
|
|
||||||
# define HAVE_COMPLIANT_POSIX_MEMALIGN 1
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
/* the GSlice allocator is split up into 4 layers, roughly modelled after the slab
|
/* the GSlice allocator is split up into 4 layers, roughly modelled after the slab
|
||||||
* allocator and magazine extensions as outlined in:
|
* allocator and magazine extensions as outlined in:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user