i have (had, turned the error off in the IDE) with win 7 64, using pycharm. But my code still ran.
CL On Fri, Jul 25, 2014 at 2:32 AM, Bin Huang <[email protected]> wrote: > Hi Jeff, > > You are actually right. In fact, stackless is not enabled by default when > it is compiled for ARM architecture. I don't know why the definition for > "__arm__" or "__arm32__" is missing. > > Here is how ''STACKLESS" is defined in "Stackless/stackless.h" in > stackless-2.6.5: > > > ------------------------------------------------------------------------------ > #define STACKLESS > > #ifdef STACKLESS_OFF > #undef STACKLESS > /* an option to switch it off */ > #elif defined(MS_WIN32) && !defined(MS_WIN64) && defined(_M_IX86) > /* MS Visual Studio on X86 */ > #elif defined(_WIN64) && defined(_M_X64) > /* microsoft on 64 bit x64 thingies */ > #elif defined(__GNUC__) && defined(__i386__) > /* gcc on X86 */ > #elif defined(__GNUC__) && defined(__amd64__) > /* gcc on AMD64 */ > #elif defined(__GNUC__) && defined(__PPC__) && defined(__linux__) > /* gcc on PowerPC */ > #elif defined(__GNUC__) && defined(__ppc__) && defined(__APPLE__) > /* Apple MacOS X on PowerPC */ > #elif defined(__GNUC__) && defined(sparc) && defined(sun) > /* SunOs on sparc */ > #elif defined(__GNUC__) && defined(__s390__) && defined(__linux__) > /* Linux/S390 */ > #elif defined(__GNUC__) && defined(__s390x__) && defined(__linux__) > /* Linux/S390 zSeries */ > #elif defined(__GNUC__) && defined(__mips__) && defined(__linux__) > /* MIPS */ > #else > /* no supported platform */ > #undef STACKLESS > #endif > > ------------------------------------------------------------------------------ > > If you take a close look at it, there is no definition for "__arm__" or > "__arm32__". So I have to manually add that definition to the header file. > > Now the problem is solved. I want to thank everyone who helped! > > Bin > > > On Thu, Jul 24, 2014 at 7:37 PM, Jeff Senn <[email protected]> wrote: > >> >> On Jul 24, 2014, at 2:47 PM, Bin Huang <[email protected]> wrote: >> >> Hi Anselm, >> >> The reason I used Stackless 2.6.5 is because my project needs to support >> the execution of a subset of the Python 2.6 bytecodes. >> >> But I did try 2.7.8 as you suggested. Interestingly, I had the same >> problem with the Stackless 2.7.8 on my ARM platform. >> >> Specifically, here is the output I got: >> >> >> ----------------------------------------------------------------------------------------------------- >> root@192:/opt/stackless-278/bin# ./python >> Python 2.7.8 (default, Feb 18 1970, 19:12:51) >> >> ^^^^^^^^^^^^^ >> I think this is a clue. If your compile options were right for compiling >> with stackless enabled it would >> not say “default” here — it would say “Stackless…<something>…." >> >> [GCC 4.6.3] on linux2 >> Type "help", "copyright", "credits" or "license" for more information. >> >>> import stackless >> Traceback (most recent call last): >> File "<stdin>", line 1, in <module> >> File "/opt/stackless-278/lib/python2.7/stackless.py", line 8, in >> <module> >> import _stackless >> ImportError: No module named _stackless >> >> ----------------------------------------------------------------------------------------------------- >> >> Is there a method I can get verbose error message in Python? I googled it >> but did not get any useful tips. >> >> Any comments? >> >> Thanks. >> >> Bin >> >> >> On Thu, Jul 24, 2014 at 4:19 AM, Anselm Kruis < >> [email protected]> wrote: >> >>> Hi Bin, >>> >>> Why do you use such an old version? Did you already try 2.7.8? It >>> contains many fixes, not available in 2.6. >>> >>> > necessary bits to build some modules. When I tried to import the >>> 'stackless' >>> > module, the system reported an error, "no module named stackless", to >>> me. >>> Probably some internal error occurd during the initialisation of the >>> module. The import mechanism of Python reports such errors as ImportErrors. >>> >>> Cheers >>> Anselm >>> >>> >>> >>> -----Original message----- >>> From: Bin Huang <[email protected]> >>> Sent: Thu 24-07-2014 06:32 >>> Subject: [Stackless] Fail to import the 'stackless' module >>> To: The Stackless Python Mailing List <[email protected]>; >>> > Hi list, >>> > >>> > I have compiled stackless-2.6.5 for an ARM platform (ARMv7 >>> architecture). No >>> > error occurred during the compilation except that the system failed to >>> find the >>> > necessary bits to build some modules. When I tried to import the >>> 'stackless' >>> > module, the system reported an error, "no module named stackless", to >>> me. >>> > >>> > Specifically, the error message looks like this: >>> > >>> > >>> -------------------------------------------------------------------------------- >>> > ---------------------------- >>> > root@192:/opt/stackless-2.6.5/bin# ./python >>> > Python 2.6.5 (unknown, Feb 18 1970, 02:43:59) >>> > [GCC 4.6.3] on linux3 >>> > Type "help", "copyright", "credits" or "license" for more information. >>> > >>> import stackless >>> > Traceback (most recent call last): >>> > File "<stdin>", line 1, in <module> >>> > ImportError: No module named stackless >>> > >>> >>> > >>> -------------------------------------------------------------------------------- >>> > ---------------------------- >>> > >>> > Also, I took the same source files and compiled them (with the same >>> > configuration) for an X86 workstation. That worked well and I did not >>> have any >>> > problem with importing the 'stackless' module. >>> > >>> > I think Stackless-2.6.5 supports ARMv7 architecture. Otherwise, I >>> shouldn't be >>> > able to launch the interpreter. >>> > >>> > I really don't have any clue here. I wonder if someone can offer me >>> some >>> > insights. Thanks in advance. >>> > >>> > Bin >>> > >>> > >>> > _______________________________________________ >>> > >>> > Stackless mailing list >>> > >>> > [email protected] >>> > >>> > http://www.stackless.com/mailman/listinfo/stackless >>> > >>> > >>> -- >>> Vorstandsvorsitzender/Chairman of the board of management: >>> Gerd-Lothar Leonhart >>> Vorstand/Board of Management: >>> Dr. Bernd Finkbeiner, Michael Heinrichs, Dr. Arno Steitz >>> Vorsitzender des Aufsichtsrats/ >>> Chairman of the Supervisory Board: >>> Philippe Miltin >>> Sitz/Registered Office: Tuebingen >>> Registergericht/Registration Court: Stuttgart >>> Registernummer/Commercial Register No.: HRB 382196 >>> _______________________________________________ >>> Stackless mailing list >>> [email protected] >>> http://www.stackless.com/mailman/listinfo/stackless >> >> >> _______________________________________________ >> Stackless mailing list >> [email protected] >> http://www.stackless.com/mailman/listinfo/stackless >> >> >> >> _______________________________________________ >> Stackless mailing list >> [email protected] >> http://www.stackless.com/mailman/listinfo/stackless >> > > > _______________________________________________ > Stackless mailing list > [email protected] > http://www.stackless.com/mailman/listinfo/stackless > -- ==================================== Lars van Gemerden [email protected] +31 6 26 88 55 39 ====================================
_______________________________________________ Stackless mailing list [email protected] http://www.stackless.com/mailman/listinfo/stackless
