Skip to content

Difficulty compiling; _testcapi.c #4

@hanetzer

Description

@hanetzer

Had a bit of trouble building this; I ran with CC=clang in order to maybe get some better debug output, got this:

clang -pthread -Wno-unused-result -Werror=declaration-after-statement -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes     -I. -IInclude -I./Include -I/usr/lib -static -fPIC  -I/usr/include   -DPy_BUILD_CORE  -c ./Modules/_testcapimodule.c -o Modules/_testcapimodule.o
./Modules/_testcapimodule.c:1750:9: error: use of undeclared identifier 'PyDateTimeAPI'
    if (PyDateTimeAPI) {
        ^
./Modules/_testcapimodule.c:1762:5: error: use of undeclared identifier 'PyDateTime_IMPORT'
    PyDateTime_IMPORT;
    ^
./Modules/_testcapimodule.c:1763:9: error: use of undeclared identifier 'PyDateTimeAPI'
    if (PyDateTimeAPI)
        ^
3 errors generated.

I was able to static compile using a hack I found here: http://bugs.python.org/issue19348
Seems to have worked; I was able to run the built python executable and use the python shell with a few tests, just a few print() and such.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions