[PyQt] trouble installing pyqt4 from source on fedora 13

2010-09-30 Thread Darren Dale
I just upgraded the OS on a computer at work to fedora 13, and I am
attempting to install sip and pyqt4 from source (since the versions
provided by the package manager are surprisingly out of date.) When I
run python configure.py, I get the following:

---
Determining the layout of your Qt installation...
Error: Qt has been built as static libraries so either the -g or -k argument
should be used.
---

I don't think this is accurate. I have installed the qt-devel package
(4.6.3-8fc13.x86_64), and my /usr/lib64 contains the libQt*.so files
for all the .so files I expected to see. Here are the contents of
qtdirs.out:

---
/usr/lib64/qt4
/usr/include
/usr/lib64
/usr/lib64/qt4/bin
/usr/lib64/qt4
/usr/lib64/qt4/plugins
263683
1048575
Open Source

PyQt_NoPrintRangeBug
---

Could anyone suggest what I've overlooked? According to
http://rpm.pbone.net/index.php3/stat/4/idpl/14306102/dir/fedora_13/com/qt-4.6.3-8.fc13.x86_64.rpm.html
, the packages I have installed should have provided the shared
libraries, but I must be missing something.

Thanks,
Darren
___
PyQt mailing listPyQt@riverbankcomputing.com
http://www.riverbankcomputing.com/mailman/listinfo/pyqt


Re: [PyQt] trouble installing pyqt4 from source on fedora 13

2010-09-30 Thread Darren Dale
On Thu, Sep 30, 2010 at 10:33 AM, Phil Thompson
p...@riverbankcomputing.com wrote:
 On Thu, 30 Sep 2010 10:16:27 -0400, Darren Dale dsdal...@gmail.com
 wrote:
 I just upgraded the OS on a computer at work to fedora 13, and I am
 attempting to install sip and pyqt4 from source (since the versions
 provided by the package manager are surprisingly out of date.) When I
 run python configure.py, I get the following:

 ---
 Determining the layout of your Qt installation...
 Error: Qt has been built as static libraries so either the -g or -k
 argument
 should be used.
 ---

 I don't think this is accurate. I have installed the qt-devel package
 (4.6.3-8fc13.x86_64), and my /usr/lib64 contains the libQt*.so files
 for all the .so files I expected to see. Here are the contents of
 qtdirs.out:

 ---
 /usr/lib64/qt4
 /usr/include
 /usr/lib64
 /usr/lib64/qt4/bin
 /usr/lib64/qt4
 /usr/lib64/qt4/plugins
 263683
 1048575
 Open Source

 PyQt_NoPrintRangeBug
 ---

 Could anyone suggest what I've overlooked? According to

 http://rpm.pbone.net/index.php3/stat/4/idpl/14306102/dir/fedora_13/com/qt-4.6.3-8.fc13.x86_64.rpm.html
 , the packages I have installed should have provided the shared
 libraries, but I must be missing something.

 configure.py is checking to see if QT_SHARED is defined (the blank line in
 the output implies it is not). The .pro it creates for qtdirs contains a
 workaround for certain broken distros to make sure it is set properly.
 Maybe the workaround no longer works.

I found some bug reports/discussion that might be relevant:

http://bugreports.qt.nokia.com/browse/QTBUG-2098
http://bugreports.qt.nokia.com/browse/QTBUG-9110?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel

from https://svn.zib.de/lenne3d/tools/cmake/2.4.5/Modules/FindQt4.cmake :
# warning currently only qconfig.pri on Windows potentially
contains static
# so QT_SHARED might not get defined properly on Mac/X11 (which
seems harmless right now)
# Trolltech said they'd consider exporting it for all platforms in
future releases.


I tried also to find how the fedora devs managed to patch and build
pyqt in the fedora environment, but I can't find anything. Aren't they
compelled by the terms of the GPL to make such patches available?

Darren
___
PyQt mailing listPyQt@riverbankcomputing.com
http://www.riverbankcomputing.com/mailman/listinfo/pyqt


Re: [PyQt] trouble installing pyqt4 from source on fedora 13

2010-09-30 Thread Baz Walter

On 30/09/10 16:24, Darren Dale wrote:

I tried also to find how the fedora devs managed to patch and build
pyqt in the fedora environment, but I can't find anything. Aren't they
compelled by the terms of the GPL to make such patches available?


any patches should be in fedora's src.rpm for pyqt, along with the .spec 
file for building the binary package.


nb: you can extract the files from an rpm with rpm2cpio (or a gui 
archiver like file-roller).

___
PyQt mailing listPyQt@riverbankcomputing.com
http://www.riverbankcomputing.com/mailman/listinfo/pyqt


Re: [PyQt] trouble installing pyqt4 from source on fedora 13

2010-09-30 Thread Darren Dale
On Thu, Sep 30, 2010 at 12:09 PM, Baz Walter baz...@ftml.net wrote:
 On 30/09/10 16:24, Darren Dale wrote:

 I tried also to find how the fedora devs managed to patch and build
 pyqt in the fedora environment, but I can't find anything. Aren't they
 compelled by the terms of the GPL to make such patches available?

 any patches should be in fedora's src.rpm for pyqt, along with the .spec
 file for building the binary package.

 nb: you can extract the files from an rpm with rpm2cpio (or a gui archiver
 like file-roller).

Thank you for that.

I was able to build after applying this change:

 out  QLibraryInfo::licensee()  '\\n';

-#if defined(QT_SHARED) || defined(QT_DLL)
+//#if defined(QT_SHARED) || defined(QT_DLL)
 out  shared\\n;
-#else
-out  \\n;
-#endif
+//#else
+//out  \\n;
+//#endif


Phil, it looks like QT_SHARED is somewhat fragile, or rather, it
doesn't seem that the qt devs intended to support it for this
particular use case. Is its use necessary in PyQt's configure.py?
Based on the change required to build on Fedora, it doesn't seem so,
but probably I'm overlooking its intended purpose.

Darren
___
PyQt mailing listPyQt@riverbankcomputing.com
http://www.riverbankcomputing.com/mailman/listinfo/pyqt


Re: [PyQt] trouble installing pyqt4 from source on fedora 13

2010-09-30 Thread Phil Thompson
On Thu, 30 Sep 2010 13:34:28 -0400, Darren Dale dsdal...@gmail.com
wrote:
 On Thu, Sep 30, 2010 at 12:09 PM, Baz Walter baz...@ftml.net wrote:
 On 30/09/10 16:24, Darren Dale wrote:

 I tried also to find how the fedora devs managed to patch and build
 pyqt in the fedora environment, but I can't find anything. Aren't they
 compelled by the terms of the GPL to make such patches available?

 any patches should be in fedora's src.rpm for pyqt, along with the
.spec
 file for building the binary package.

 nb: you can extract the files from an rpm with rpm2cpio (or a gui
 archiver
 like file-roller).
 
 Thank you for that.
 
 I was able to build after applying this change:
 
  out  QLibraryInfo::licensee()  '\\n';
 
 -#if defined(QT_SHARED) || defined(QT_DLL)
 +//#if defined(QT_SHARED) || defined(QT_DLL)
  out  shared\\n;
 -#else
 -out  \\n;
 -#endif
 +//#else
 +//out  \\n;
 +//#endif
 
 
 Phil, it looks like QT_SHARED is somewhat fragile, or rather, it
 doesn't seem that the qt devs intended to support it for this
 particular use case. Is its use necessary in PyQt's configure.py?

Yes it is necessary - but I could add a flag to configure.py to override
the value detected.

 Based on the change required to build on Fedora, it doesn't seem so,
 but probably I'm overlooking its intended purpose.

The reason it doesn't work on Fedora is that Fedora have messed with the
Qt build. It's fine with a build from the Nokia sources.

Phil
___
PyQt mailing listPyQt@riverbankcomputing.com
http://www.riverbankcomputing.com/mailman/listinfo/pyqt