View Issue Details

IDProjectCategoryView StatusLast Update
0009554ardourbugspublic2023-11-28 16:40
Reporterfweimer Assigned Tox42  
PrioritynormalSeveritytweakReproducibilityalways
Status resolvedResolutionfixed 
PlatformGNUOSLinuxOS Version(any)
Summary0009554: C compatibility issue in localtime_r probe
DescriptionThe localtime_r probe tries to return a pointer from main, which will be an error in future C compilers.

diff --git a/libs/pbd/wscript b/libs/pbd/wscript
index 06b285c79d..f9fc92dc0e 100644
--- a/libs/pbd/wscript
+++ b/libs/pbd/wscript
@@ -115,7 +115,7 @@ def configure(conf):
             define_name='HAVE_GETMNTENT', execute = False, mandatory=False)
     conf.check_cc(
             msg="Checking for function 'localtime_r' in time.h",
- fragment = "#include <time.h>\n int main(void) { return localtime_r(NULL, NULL); }\n",
+ fragment = "#include <time.h>\n int main(void) { return localtime_r(NULL, NULL) == 0; }\n",
             define_name='HAVE_LOCALTIME_R', execute = False, mandatory=False)
 
     # Boost headers
Steps To ReproduceEasiest with a instrumented compiler that logs such C compatibility issues.

Full build log is here: https://gitlab.com/fweimer-rh/fedora-modernc-logs/-/blob/b64924b4082182b521aee43b362e3c070c163c1f/logs/a/ardour6.log
TagsNo tags attached.

Activities

x42

2023-11-28 16:40

administrator   ~0028368

Thanks, fixed in Ardour 8.1-141-ga8c26dbfa4

Issue History

Date Modified Username Field Change
2023-11-28 15:28 fweimer New Issue
2023-11-28 16:40 x42 Assigned To => x42
2023-11-28 16:40 x42 Status new => resolved
2023-11-28 16:40 x42 Resolution open => fixed
2023-11-28 16:40 x42 Note Added: 0028368