Hi Han,
From: Jeong Han Lee [mailto:[email protected]]
>
> I'm trying to build the cothread-2-12 (gz and git) in my laptop,
> I've got the following error:
>
>
> @:~/cothread-2-12$ python setup.py build
> running build
> running build_py
> creating build
> creating build/lib.linux-x86_64-2.7
> creating build/lib.linux-x86_64-2.7/cothread
> copying cothread/catools.py -> build/lib.linux-x86_64-2.7/cothread
> copying cothread/poll_win32.py -> build/lib.linux-x86_64-2.7/cothread
> copying cothread/cothread.py -> build/lib.linux-x86_64-2.7/cothread
> copying cothread/load_ca.py -> build/lib.linux-x86_64-2.7/cothread
> copying cothread/cadef.py -> build/lib.linux-x86_64-2.7/cothread
> copying cothread/coserver.py -> build/lib.linux-x86_64-2.7/cothread
> copying cothread/input_hook.py -> build/lib.linux-x86_64-2.7/cothread
> copying cothread/cosocket.py -> build/lib.linux-x86_64-2.7/cothread
> copying cothread/pv.py -> build/lib.linux-x86_64-2.7/cothread
> copying cothread/__init__.py -> build/lib.linux-x86_64-2.7/cothread
> copying cothread/dbr.py -> build/lib.linux-x86_64-2.7/cothread
> copying cothread/coselect.py -> build/lib.linux-x86_64-2.7/cothread
> creating build/lib.linux-x86_64-2.7/cothread/tools
> copying cothread/tools/pvtree.py -> build/lib.linux-x86_64-
> 2.7/cothread/tools
> copying cothread/tools/__init__.py -> build/lib.linux-x86_64-
> 2.7/cothread/tools
> running build_ext
> building 'cothread._coroutine' extension
> creating build/temp.linux-x86_64-2.7
> creating build/temp.linux-x86_64-2.7/context
> gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall
> -Wstrict-prototypes -fPIC -I/usr/include/python2.7 -c
> context/_coroutine.c -o
> build/temp.linux-x86_64-2.7/context/_coroutine.o -Werror -Wall -Wextra
> -Wno-unused-parameter -Wno-missing-field-initializers -Wundef -Wshadow
> -Wcast-align -Wwrite-strings -Wredundant-decls -Wmissing-prototypes
> -Wmissing-declarations -Wstrict-prototypes
> gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall
> -Wstrict-prototypes -fPIC -I/usr/include/python2.7 -c context/cocore.c
> -o build/temp.linux-x86_64-2.7/context/cocore.o -Werror -Wall -Wextra
> -Wno-unused-parameter -Wno-missing-field-initializers -Wundef -Wshadow
> -Wcast-align -Wwrite-strings -Wredundant-decls -Wmissing-prototypes
> -Wmissing-declarations -Wstrict-prototypes
> context/cocore.c: In function ‘delete_stack’:
> context/cocore.c:326:5: error: variable ‘_qzz_res’ set but not used
> [-Werror=unused-but-set-variable]
> cc1: all warnings being treated as errors
> error: command 'gcc' failed with exit status 1
>
> Add the the extra compile arguments in setup.py with
> -Wno-unused-but-set-variable, then the building cothread process can
> be done.
>
> I am not sure this is the right approach, because of -Werror arg in
> setup.py. So please tell me it might be ok or not in order to use the
> cothread in my machine. I am using the Debian stable with the most
> up-to-date one and gcc is gcc (Debian 4.7.2-5) 4.7.2
Thank you for the report.
The workaround you have is just fine, and in fact you could instead get away with removing the -Werror from the list in setup.py. I've always tried to eliminate as many warnings as possible from my code, but maybe I should somehow remove the -Werror from the released version.
What's going on here is rather interesting: a while ago I added valgrind support to cothread, and this uses some rather evil looking code to generate special instructions that only valgrind takes any notice of. Unfortuately it looks as if your compiler, which is more recent than mine, doesn't like one of the valgrind tricks.
I don't know of a cleaner way to suppress this warning than the workaround you've found. Do let me know how you get on with cothread!
- Replies:
- Re: compiling issues during building cothread Benjamin Franksen
- References:
- compiling issues during building cothread Jeong Han Lee
- Navigate by Date:
- Prev:
compiling issues during building cothread Jeong Han Lee
- Next:
Re: Problems with Dynamic Array population Andrew Johnson
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
<2014>
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
- Navigate by Thread:
- Prev:
compiling issues during building cothread Jeong Han Lee
- Next:
Re: compiling issues during building cothread Benjamin Franksen
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
<2014>
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
|