packages/utils/gpsd/patches/0003-no-sizeof_time_t-check.patch
Jeffery To a29905c42b gpsd: Update to 3.20, add/refresh patches
New patches (both for SConstruct):

* Do not import from distutils. Since Python support/modules are not
  built, there is no need to import from distutils. (Importing from
  distutils may prevent the package from being built on systems without
  a full distutils module, e.g. Debian with python3-minimal.)

  I have added back the import in places where it may be helpful to
  have, if scons is run manually.

  Fixes #10993.

* Do not check the size of time_t. The way this is done is to compile
  and run a test program; this fails when cross-compiling[1].

  This doesn't appear to affect any functionality (other than missing a
  compile-time warning that things will fail in 2038 if time_t is too
  small).

[1]: https://gitlab.com/gpsd/gpsd/issues/48

Signed-off-by: Jeffery To <jeffery.to@gmail.com>
2020-01-17 04:42:46 +08:00

15 lines
684 B
Diff

--- a/SConstruct
+++ b/SConstruct
@@ -1047,12 +1047,6 @@ else:
confdefs.append("/* #undef HAVE_%s_H */\n"
% hdr.replace("/", "_").upper())
- sizeof_time_t = config.CheckSizeOf("time_t")
- confdefs.append("#define SIZEOF_TIME_T %s\n" % sizeof_time_t)
- announce("sizeof(time_t) is %s" % sizeof_time_t)
- if 4 >= int(sizeof_time_t):
- announce("WARNING: time_t is too small. It will fail in 2038")
-
# check function after libraries, because some function require libraries
# for example clock_gettime() require librt on Linux glibc < 2.17
for f in ("cfmakeraw", "clock_gettime", "daemon", "fcntl", "fork",