kivy / python-for-android

Turn your Python application into an Android APK
https://python-for-android.readthedocs.io
MIT License
8.29k stars 1.84k forks source link

greenlet recipe build fail #2806

Open RobertFlatt opened 1 year ago

RobertFlatt commented 1 year ago

Logs

In file included from ./slp_platformselect.h:47:
./platform/switch_aarch64_gcc.h:62:51: warning: value size does not match register size specified by the constraint and modifier [-Wasm-operand-widths]
           __asm__ volatile ("mov %0, #0" : "=r" (err));
                                                  ^
./platform/switch_aarch64_gcc.h:62:35: note: use constraint modifier "w"
           __asm__ volatile ("mov %0, #0" : "=r" (err));
                                  ^~
                                  %w0
greenlet.c:538:10: error: no member named 'use_tracing' in 'struct _ts'
        tstate->use_tracing = 0;
        ~~~~~~  ^
greenlet.c:541:10: error: no member named 'use_tracing' in 'struct _ts'
        tstate->use_tracing = (tstate->tracing <= 0 &&
        ~~~~~~  ^
greenlet.c:823:13: warning: 'PyEval_CallObjectWithKeywords' is deprecated [-Wdeprecated-declarations]
                        result = PyEval_CallObjectWithKeywords(
                                 ^
/home/bobf/ex/regression/.buildozer/android/platform/build-arm64-v8a/build/other_builds/python3/arm64-v8a__ndk_target_21/python3/Include/ceval.h:17:1: note: 'PyEval_CallObjectWithKeywords' has been explicitly marked deprecated here
Py_DEPRECATED(3.9) PyAPI_FUNC(PyObject *) PyEval_CallObjectWithKeywords(
^
/home/bobf/ex/regression/.buildozer/android/platform/build-arm64-v8a/build/other_builds/python3/arm64-v8a__ndk_target_21/python3/Include/pyport.h:513:54: note: expanded from macro 'Py_DEPRECATED'
#define Py_DEPRECATED(VERSION_UNUSED) __attribute__((__deprecated__))
                                                     ^
greenlet.c:1009:19: error: expression is not assignable
                Py_REFCNT(self) = 1;
                ~~~~~~~~~~~~~~~ ^
greenlet.c:1038:7: error: expression is not assignable
                if (--Py_REFCNT(self) != 0) {
                    ^ ~~~~~~~~~~~~~~~
greenlet.c:1042:20: error: expression is not assignable
                        Py_REFCNT(self) = refcnt;
                        ~~~~~~~~~~~~~~~ ^
greenlet.c:1046:4: error: use of undeclared identifier '_Py_DEC_REFTOTAL'
                        _Py_DEC_REFTOTAL;
                        ^
2 warnings and 6 errors generated.
pedrognsmartins commented 1 year ago

We have exactly the same issue. Can someone help ?

RobertFlatt commented 1 year ago

I didn't try to figure this one (I was only doing regression testing) but each of the two described here would be worth trying https://github.com/Android-for-Python/Android-for-Python-Users#error-expression-is-not-assignable

pedrognsmartins commented 1 year ago

Thanks for your feedback. I was able to solve the issue based on your input (update cython) plus declaring on requirements specifically version 2.0.2 for greenlet.