Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: python-sfml2: error: 'Back' is not a member of 'sf::Keyboard'  (Read 5710 times)

0 Members and 1 Guest are viewing this topic.

shackra

  • Jr. Member
  • **
  • Posts: 54
    • View Profile
    • http://swt.encyclomundi.org
D:

I was recompiling python*-sfml2 because some funky errors appeared when I did import sfml and I cough this error:

==> Retrieving sources...
  -> Found v1.2.zip
==> Validating source files with sha256sums...
    v1.2.zip ... Passed
==> Extracting sources...
  -> Extracting v1.2.zip with bsdtar
==> Starting build()...
running build
running build_py
creating build
creating build/lib.linux-x86_64-2.7
creating build/lib.linux-x86_64-2.7/sfml
copying src/sfml/__init__.py -> build/lib.linux-x86_64-2.7/sfml
copying src/sfml/show.py -> build/lib.linux-x86_64-2.7/sfml
running build_ext
building 'sfml.x11' extension
creating build/temp.linux-x86_64-2.7
creating build/temp.linux-x86_64-2.7/src
creating build/temp.linux-x86_64-2.7/src/sfml
gcc -pthread -DNDEBUG -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector --param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2 -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector --param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2 -fPIC -Iinclude -Isrc/sfml -I/usr/include/python2.7 -c src/sfml/x11.cpp -o build/temp.linux-x86_64-2.7/src/sfml/x11.o
src/sfml/x11.cpp: In function 'PyObject* __pyx_pf_4sfml_3x11_flush_screen(PyObject*, int)':
src/sfml/x11.cpp:536:35: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
   __pyx_v_myDisplay = ((Display *)__pyx_v_d);
                                   ^
g++ -pthread -shared -Wl,-O1,--sort-common,--as-needed,-z,relro -Wl,-O1,--sort-common,--as-needed,-z,relro,--hash-style=gnu -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector --param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2 build/temp.linux-x86_64-2.7/src/sfml/x11.o -L/usr/lib -lX11 -lpython2.7 -o build/lib.linux-x86_64-2.7/sfml/x11.so
building 'sfml.system' extension
gcc -pthread -DNDEBUG -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector --param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2 -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector --param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2 -fPIC -Iinclude -Isrc/sfml -I/usr/include/python2.7 -c src/sfml/system.cpp -o build/temp.linux-x86_64-2.7/src/sfml/system.o
gcc -pthread -DNDEBUG -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector --param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2 -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector --param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2 -fPIC -Iinclude -Isrc/sfml -I/usr/include/python2.7 -c src/sfml/error.cpp -o build/temp.linux-x86_64-2.7/src/sfml/error.o
g++ -pthread -shared -Wl,-O1,--sort-common,--as-needed,-z,relro -Wl,-O1,--sort-common,--as-needed,-z,relro,--hash-style=gnu -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector --param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2 build/temp.linux-x86_64-2.7/src/sfml/system.o build/temp.linux-x86_64-2.7/src/sfml/error.o -L/usr/lib -lsfml-system -lsfml-graphics -lpython2.7 -o build/lib.linux-x86_64-2.7/sfml/system.so
building 'sfml.window' extension
gcc -pthread -DNDEBUG -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector --param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2 -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector --param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2 -fPIC -Iinclude -Isrc/sfml -I/usr/include/python2.7 -c src/sfml/window.cpp -o build/temp.linux-x86_64-2.7/src/sfml/window.o
src/sfml/window.cpp: In function 'void initwindow()':
src/sfml/window.cpp:20239:30: error: 'Back' is not a member of 'sf::Keyboard'
   __pyx_t_2 = PyInt_FromLong(sf::Keyboard::Back); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 871; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
                              ^
error: command 'gcc' failed with exit status 1
==> ERROR: A failure occurred in build().
    Aborting...
==> ERROR: Build failed, check /mnt/building/root/build
==> ERROR: (libremakepkg): An unknown error has occurred. Exiting...
 


I was compiling using this source code https://github.com/Sonkun/python-sfml/archive/v1.2.zip I think that this comes from a update of the package sfml

jorge [/tmp/python2-sfml2] ~> LC_ALL=C pacman -Qi sfml
Name           : sfml
Version        : 2.0-1
Description    : A simple, fast, cross-platform, and object-oriented multimedia API
Architecture   : x86_64
URL            : http://www.sfml-dev.org/
Licenses       : zlib
Groups         : None
Provides       : None
Depends On     : libsndfile  libxrandr  libjpeg  openal  glew  freetype2
Optional Deps  : None
Required By    : python2-sfml2
Optional For   : None
Conflicts With : None
Replaces       : None
Installed Size : 7992.00 KiB
Packager       : Sven-Hendrik Haase <sh[at]lutzhaase[dot]com>
Build Date     : Fri Apr 12 01:48:59 2013
Install Date   : Mon Apr 15 16:49:22 2013
Install Reason : Installed as a dependency for another package
Install Script : Yes
Validated By   : Signature

jorge [/tmp/python2-sfml2] ~>
 

Looks like that package was updated recently (Install Date: Mon Apr 15 16:49:22 2013). any fix? :)

GNU User
Python programmer
Blog