Bug 666297
Summary: | python3-cairo contains (buggy) embedded copy of waf | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Dave Malcolm <dmalcolm> | ||||||||
Component: | python3-cairo | Assignee: | John (J5) Palmieri <johnp> | ||||||||
Status: | CLOSED RAWHIDE | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||||||
Severity: | medium | Docs Contact: | |||||||||
Priority: | low | ||||||||||
Version: | rawhide | CC: | adrian, dmalcolm, jkeck, johnp, karsten | ||||||||
Target Milestone: | --- | ||||||||||
Target Release: | --- | ||||||||||
Hardware: | Unspecified | ||||||||||
OS: | Linux | ||||||||||
Whiteboard: | |||||||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||||||
Doc Text: | Story Points: | --- | |||||||||
Clone Of: | Environment: | ||||||||||
Last Closed: | 2011-02-10 21:34:08 UTC | Type: | --- | ||||||||
Regression: | --- | Mount Type: | --- | ||||||||
Documentation: | --- | CRM: | |||||||||
Verified Versions: | Category: | --- | |||||||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||||||
Cloudforms Team: | --- | Target Upstream Version: | |||||||||
Embargoed: | |||||||||||
Attachments: |
|
Description
Dave Malcolm
2010-12-30 02:05:54 UTC
We had this debate between shared version and packaged version. In the end package version was the only thing that worked. From my sketchy recollection, the system version did not support Python 3 or have all of the plugins needed. Btw, if the headers can not be found I would think this is an issue with /usr/bin/python3.2-config. In any case can you track down why the headers are not being found before we take any actions? If the system waf works, I would say it is fine to use that. waf tries to build a test-binary with linker flags -lpython3.2 -lpython3.2 and -lpython32 The latest python3 has renamed the libs to libpython3.2mu.so, so this will fail: [1/2] cc: build_directory/.conf_check_0/test.c -> build_directory/.conf_check_0/testbuild/default/test_1.o '/usr/bin/gcc', '../test.c', '-c', '-o', 'default/test_1.o'] [2/2] cc_link: build_directory/.conf_check_0/testbuild/default/test_1.o -> build_directory/.conf_check_0/testbuild/default/testprog /usr/bin/ld: cannot find -lpython3.2 collect2: ld returned 1 exit status ['/usr/bin/gcc', 'default/test_1.o', '-o', '/builddir/build/BUILD/pycairo-1.8.10/build_directory/.conf_check_0/testbuild/default/testprog', '-L/usr/lib64', '-Wl,-Bdynamic', '-lpython3.2', '-lm', '-lpthread', '-ldl', '-lutil'] command returned 'Build failed: -> task failed (err #1): \n\t{task: cc_link test_1.o -> testprog}'not found https://bugzilla.redhat.com/show_bug.cgi?id=670478 shows a similar problem and has a pointer to the reason for the name change, the proper fix is the same: use pkg-config or python3.2-config --libs instead of trying to figure out the paths on your own. > pkg-config --libs python3 -lpython3.2mu > python3.2-config --libs -lpthread -ldl -lutil -lm -lpython3.2mu The same problem will probably show up with the include directory, it got moved to /usr/include/python3.2mu: > pkg-config --cflags-only-I python3 -I/usr/include/python3.2mu > python3.2-config --include -I/usr/include/python3.2mu -I/usr/include/python3.2mu Created attachment 476051 [details]
use python-config to find name of python lib
something like this will work, but applying it to the embedded copy of waf will require to unpack that first
Ah, after updating to rawhide I now understand the issue. How would we go about applying this? e.g. what format is waf packed in? Can we just patch the system waf and use that? Upstream pycairo is pretty unresponsive these days. Created attachment 478104 [details]
Log of waf build from git
It seems that the git version of pycairo does find the correct directories but doesn't use them when compiling.
python3 waf configure --prefix /home/johnp/devel/gnome/install --libdir /home/johnp/devel/gnome/install/lib64
Created attachment 478110 [details]
Work in progress patch to specfile
Here's a possible approach for how to patch waf from the rpm build (assuming a patch to the unpacked waf sources)
I've combined my specfile patch from comment #6 and a version of Karsten's patch from comment #3 and it builds locally; I can instantiate objects from the cairo._cairo shared library. Committed & pushed as: http://pkgs.fedoraproject.org/gitweb/?p=python3-cairo.git;a=commit;h=c572cc4dd4bb5cca1aba48d7315079fa0f2694de Building python3-cairo-1.8.10-11.fc16 for dist-rawhide Task info: http://koji.fedoraproject.org/koji/taskinfo?taskID=2830881 built in rawhide and F15 updates-candidates |