mirror of
https://github.com/oasislinux/oasis.git
synced 2026-02-01 11:34:17 +01:00
curl: Probe for size of size_t, time_t and long
There are still several more SIZEOF_* constants in curl_config.h, but they seem to match for architectures we care about.
This commit is contained in:
Submodule pkg/awk/src updated: 1d9d86418a...ba9e08cf8e
@@ -295,12 +295,12 @@
|
||||
#define SEND_TYPE_RETV ssize_t
|
||||
#define SIZEOF_CURL_OFF_T 8
|
||||
#define SIZEOF_INT 4
|
||||
#define SIZEOF_LONG 8
|
||||
/* probe SIZEOF_LONG */
|
||||
/* #undef SIZEOF_LONG_LONG */
|
||||
#define SIZEOF_OFF_T 8
|
||||
#define SIZEOF_SHORT 2
|
||||
#define SIZEOF_SIZE_T 8
|
||||
#define SIZEOF_TIME_T 8
|
||||
/* probe SIZEOF_SIZE_T */
|
||||
/* probe SIZEOF_TIME_T */
|
||||
#define STDC_HEADERS 1
|
||||
#define STRERROR_R_TYPE_ARG3 size_t
|
||||
#define TIME_WITH_SYS_TIME 1
|
||||
|
||||
@@ -2,7 +2,7 @@ cflags{
|
||||
'-D HAVE_CONFIG_H',
|
||||
'-D BUILDING_LIBCURL',
|
||||
'-D CURL_STATICLIB',
|
||||
'-I $dir',
|
||||
'-I $outdir',
|
||||
'-I $outdir/include/curl',
|
||||
'-I $outdir/include',
|
||||
'-I $srcdir/lib',
|
||||
@@ -11,6 +11,13 @@ cflags{
|
||||
'-I $builddir/pkg/zlib/include',
|
||||
}
|
||||
|
||||
build('cat', '$outdir/curl_config.h', {
|
||||
'$dir/curl_config.h',
|
||||
'$builddir/probe/SIZEOF_LONG',
|
||||
'$builddir/probe/SIZEOF_SIZE_T',
|
||||
'$builddir/probe/SIZEOF_TIME_T',
|
||||
})
|
||||
|
||||
pkg.hdrs = copy('$outdir/include/curl', '$srcdir/include/curl', {
|
||||
'curl.h',
|
||||
'curlver.h',
|
||||
@@ -22,6 +29,7 @@ pkg.hdrs = copy('$outdir/include/curl', '$srcdir/include/curl', {
|
||||
'system.h',
|
||||
})
|
||||
pkg.deps = {
|
||||
'$outdir/curl_config.h',
|
||||
'$dir/headers',
|
||||
'pkg/libressl/headers',
|
||||
'pkg/zlib/headers',
|
||||
|
||||
Submodule pkg/e2fsprogs/src updated: 40e66e2e8b...e36c60bc01
Submodule pkg/iproute2/src updated: 31ad498a01...bfc5bd369c
Submodule pkg/pigz/src updated: fe822cb435...2519d53968
Submodule pkg/plan9port/src updated: 35d4392448...bcd53ab8bb
1
probe/SIZEOF_LONG
Normal file
1
probe/SIZEOF_LONG
Normal file
@@ -0,0 +1 @@
|
||||
_Static_assert(SIZEOF_LONG == sizeof(long), "incorrect size");
|
||||
2
probe/SIZEOF_SIZE_T
Normal file
2
probe/SIZEOF_SIZE_T
Normal file
@@ -0,0 +1,2 @@
|
||||
#include <stddef.h>
|
||||
_Static_assert(SIZEOF_SIZE_T == sizeof(size_t), "incorrect size");
|
||||
2
probe/SIZEOF_TIME_T
Normal file
2
probe/SIZEOF_TIME_T
Normal file
@@ -0,0 +1,2 @@
|
||||
#include <sys/types.h>
|
||||
_Static_assert(SIZEOF_TIME_T == sizeof(time_t), "incorrect size");
|
||||
@@ -1,6 +1,14 @@
|
||||
local function probe(var)
|
||||
build('probe', '$outdir/'..var, '$dir/'..var, {var=var})
|
||||
build('probe', '$outdir/'..var, {'$dir/'..var, '|', 'scripts/probe.sh'}, {var=var})
|
||||
end
|
||||
|
||||
probe('HAVE_IMMINTRIN_H')
|
||||
probe('HAVE__MM_MOVEMASK_EPI8')
|
||||
|
||||
local function probesize(var)
|
||||
build('probesize', '$outdir/'..var, {'$dir/'..var, '|', 'scripts/probe-size.sh'}, {var=var})
|
||||
end
|
||||
|
||||
probesize('SIZEOF_LONG')
|
||||
probesize('SIZEOF_SIZE_T')
|
||||
probesize('SIZEOF_TIME_T')
|
||||
|
||||
Reference in New Issue
Block a user