[New-bugs-announce] [issue34715] timemodule.c fails to compile on BSD

Pablo Galindo Salgado report at bugs.python.org
Mon Sep 17 15:32:14 EDT 2018


New submission from Pablo Galindo Salgado <pablogsal at gmail.com>:

Example:

https://buildbot.python.org/all/#/builders/87/builds/1434

./Modules/timemodule.c:573:24: warning: assigning to 'char *' from 'const char *' discards qualifiers [-Wincompatible-pointer-types-discards-qualifiers]
            p->tm_zone = PyUnicode_AsUTF8(item);
                       ^ ~~~~~~~~~~~~~~~~~~~~~~
./Modules/timemodule.c:1545:44: warning: incompatible pointer to integer conversion passing 'char *(int, int)' to parameter of type 'long' [-Wint-conversion]
    PyModule_AddIntConstant(m, "timezone", timezone);
                                           ^~~~~~~~
./Include/modsupport.h:118:71: note: passing argument to parameter here
PyAPI_FUNC(int) PyModule_AddIntConstant(PyObject *, const char *, long);
                                                                      ^
./Modules/timemodule.c:1568:44: error: use of undeclared identifier 'daylight'
    PyModule_AddIntConstant(m, "daylight", daylight);
                                           ^
2 warnings and 1 error generated.
*** [Modules/timemodule.o] Error code 1
make: stopped in /usr/home/buildbot/python/3.x.koobs-freebsd10/build
make: stopped in /usr/home/buildbot/python/3.x.koobs-freebsd10/build
1 error

----------
components: Build, FreeBSD
messages: 325566
nosy: koobs, pablogsal
priority: normal
severity: normal
status: open
title: timemodule.c fails to compile on BSD
type: compile error
versions: Python 3.8

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue34715>
_______________________________________


More information about the New-bugs-announce mailing list