Hello,
I'm evaluating PySide for later productions using Visual Studio 8
(targeting x86 platform), Python 2.6.2 and Qt 4.7.
I successfully tested the latest PySide binaries with Python 2.6.2. Then
I tried to compile all the libraries and the tools (Qt, Pyside...) from
scratch because of various production constraints and several problems
appeared.
I found some workaround for compiling PySide but i'm getting stuck with
the simple libfoo sample.
Next I detail the various problems and workaround I used. Maybe you can
help me for building the libfoo binding.
I compiled Qt then I tried to compile PySide and the associated tools,
but PySide failed to compile :
[ 73%] Building CXX object
PySide/QtNetwork/CMakeFiles/QtNetwork.dir/PySide/QtNetwork/qsslconfiguration_wrapper.cpp.obj
qsslconfiguration_wrapper.cpp
c1xx : fatal error C1083: Cannot open source file:
'C:\Users\Sylvain\Desktop\PySide\Temp\pyside\build\PySide\QtNetwork\PySide\QtNetwork\qsslconfiguration_wrapper.cpp':
No such file or directory
NMAKE : fatal error U1077: 'C:\PROGRA~2\MICROS~2\VC\bin\cl.exe' : return
code '0x2'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual
Studio 8\VC\BIN\nmake.exe"' : return code '0x2'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual
Studio 8\VC\BIN\nmake.exe"' : return code '0x2'
Stop.
FAILED
I dodged the problem by commenting HAS_QT_MODULE(QT_QTNETWORK_FOUND
QtNetwork) in pyside\PySide\CMakeLists.txt.
The following tests FAILED:
109 - QtCore_qthread_signal_test (Timeout)
224 - QtNetwork_bug_446 (Failed)
225 - QtNetwork_basic_auth_test (Failed)
226 - QtNetwork_accessManager_test (Failed)
227 - QtNetwork_http_test (Failed)
228 - QtNetwork_tcpserver_test (Failed)
229 - QtNetwork_udpsocket_test (Failed)
230 - QtWebKit_bug_448 (Failed)
231 - QtWebKit_webpage_test (Failed)
232 - QtWebKit_webview_test (Failed)
257 - QtDeclarative_bug_451 (Failed)
258 - QtDeclarative_bug_456 (Failed)
259 - QtDeclarative_bug_557 (Failed)
260 - QtDeclarative_qdeclarativenetwork_test (Failed)
261 - QtDeclarative_qdeclarativeview_test (Failed)
262 - QtDeclarative_connect_python_qml (Failed)
263 - QtDeclarative_registertype (Failed)
Next I tryed to bind the libfoo example :
cmake -G "Visual Studio 8 2005"
-DGENERATOR=C:\Users\Sylvain\Desktop\PySide\Temp\PySideInstall\bin\generatorrunner.exe
-DShiboken_DIR=C:\Users\Sylvain\Desktop\PySide\Temp\PySideInstall\lib\cmake\Shiboken-1.0.0
-DPySide_DIR=C:\Users\Sylvain\Desktop\PySide\Temp\PySideInstall\lib\cmake\PySide-1.0.0
..
-- Using default python: python2.6
-- libshiboken built for Release
-- Avoiding protected hack!
CMake Warning (dev) at
C:/Users/Sylvain/Desktop/PySide/Temp/PySideInstall/lib/cm
ake/PySide-1.0.0/PySideConfig-python2.6.cmake:8 (SET):
Syntax error in cmake code at
C:/Users/Sylvain/Desktop/PySide/Temp/PySideInstall/lib/cmake/PySide-1.0.0/Py
SideConfig-python2.6.cmake:8
when parsing string
C:/Users/Sylvain/Desktop/PySide/Temp/PySideInstall\Lib\site-packages
Invalid escape sequence \L
Policy CMP0010 is not set: Bad variable reference syntax is an
error. Run
"cmake --help-policy CMP0010" for policy details. Use the cmake_policy
command to set the policy and suppress this warning.
Call Stack (most recent call first):
C:/Users/Sylvain/Desktop/PySide/Temp/PySideInstall/lib/cmake/PySide-1.0.0/PySi
deConfig.cmake:5 (include)
CMakeLists.txt:7 (find_package)
This warning is for project developers. Use -Wno-dev to suppress it.
-- Configuring done
CMake Warning (dev) at foo/CMakeLists.txt:27 (add_library):
Policy CMP0008 is not set: Libraries linked by full-path must have a
valid
library file name. Run "cmake --help-policy CMP0008" for policy details.
Use the cmake_policy command to set the policy and suppress this warning.
Target "foo" links to item
C:/Users/Sylvain/Desktop/PySide/foobinding-cmake/../libfoo/libfoo.so
which is a full-path but not a valid library file name.
This warning is for project developers. Use -Wno-dev to suppress it.
-- Generating done
-- Build files have been written to:
C:/Users/Sylvain/Desktop/PySide/foobinding-
cmake/build
I fixed lib\cmake\PySide-1.0.0\PySideConfig-python2.6.cmake by replacing
some slashes and foobinding-cmake\foo\CMakeLists.txt by using
${LIBFOO_DIR}/release/foo.dll instead of ${LIBFOO_DIR}/libfoo.so :
-- Using default python: python2.6
-- libshiboken built for Release
-- Avoiding protected hack!
-- Configuring done
-- Generating done
-- Build files have been written to:
C:/Users/Sylvain/Desktop/PySide/foobinding-cmake/build
After a try in Visual Studio :
2>------ Build started: Project: Foo, Configuration: Debug Win32 ------
2>Running generator for Foo...
2>Compiling...
2>math_wrapper.cpp
2>c1xx : fatal error C1083: Cannot open source file:
'.\foo\math_wrapper.cpp': No such file or directory
2>foo_module_wrapper.cpp
2>c1xx : fatal error C1083: Cannot open source file:
'.\foo\foo_module_wrapper.cpp': No such file or directory
2>Generating Code...
2>Build log was saved at
"file://c:\Users\Sylvain\Desktop\binding-tutorial\foobinding-cmake\build\foo\Foo.dir\Debug\BuildLog.htm"
2>Foo - 2 error(s), 0 warning(s)
I checked the result of generatorrunner using the command line from the
vcproj :
C:\Users\Sylvain\Desktop\PySide\Temp\PySideInstall\bin\generatorrunner.exe
--generatorSet=shiboken --enable-parent-ctor-heuristic
--enable-pyside-extensions --enable-return-value-heuristic
C:/Users/Sylvain/Desktop/PySide/foobinding-cmake/foo/global.h
--include-paths=C:/Qt/2010.05/qt/include:C:/Users/Sylvain/Desktop/PySide/foobinding-cmake/../libfoo
--typesystem-paths=C:/Users/Sylvain/Desktop/PySide/Temp/PySideInstall/share/PySide/typesystems
--output-directory=C:/Users/Sylvain/Desktop/PySide/foobinding-cmake/build/foo
C:/Users/Sylvain/Desktop/PySide/foobinding-cmake/foo/typesystem_foo.xml
And I got :
Generating class model... [OK]
Fixing class inheritance... [OK]
Detecting inconsistencies in class model... [OK]
Detecting inconsistencies in typesystem... [WARNING]
type 'QUrl' is specified in typesystem, but not defined. This could
potentially lead to compilation errors.
type 'QPoint' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QXmlStreamEntityDeclaration' is specified in typesystem, but
not defined. This could potentially lead to compilation errors.
type 'QAbstractItemModel' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QXmlStreamAttributes' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QRectF' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QBuffer' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QMetaProperty' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QFileInfo' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QModelIndex' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QLine' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QAbstractFileEngineHandler' is specified in typesystem, but
not defined. This could potentially lead to compilation errors.
type 'QTextBoundaryFinder' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QWaitCondition' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QXmlStreamEntityResolver' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QTextCodec::ConverterState' is specified in typesystem, but
not defined. This could potentially lead to compilation errors.
type 'QFileSystemWatcher' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QResource' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QChildEvent' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QLibraryInfo' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QSignalMapper' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QXmlStreamNamespaceDeclaration' is specified in typesystem,
but not defined. This could potentially lead to compilation errors.
type 'QIODevice' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QPluginLoader' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QParallelAnimationGroup' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QTemporaryFile' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QTextEncoder' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QTime' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QAbstractTransition' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QAbstractListModel' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QUuid' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QCryptographicHash' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QHistoryState' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QSignalTransition' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QReadWriteLock' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QRegExp' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QBitArray' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QMimeData' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QMutex' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QSequentialAnimationGroup' is specified in typesystem, but
not defined. This could potentially lead to compilation errors.
type 'QTextStreamManipulator' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QAnimationGroup' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QTranslator' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QStateMachine::WrappedEvent' is specified in typesystem, but
not defined. This could potentially lead to compilation errors.
type 'QDataStream' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QFile' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QObject' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QTimer' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QEasingCurve' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QEventLoop' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QDirIterator' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QAbstractTableModel' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QStateMachine' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QTextCodec' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QTextStream' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QFactoryInterface' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QState' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QMetaEnum' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'Math' is specified in typesystem, but not defined. This could
potentially lead to compilation errors.
type 'QProcess' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QAbstractFileEngine' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QPointF' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QStateMachine::SignalEvent' is specified in typesystem, but
not defined. This could potentially lead to compilation errors.
type 'QTimeLine' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QXmlStreamNotationDeclaration' is specified in typesystem,
but not defined. This could potentially lead to compilation errors.
type 'QSettings' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QSystemLocale' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QAbstractAnimation' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QFSFileEngine' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QDir' is specified in typesystem, but not defined. This could
potentially lead to compilation errors.
type 'QLineF' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QMetaMethod' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QSemaphore' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QDynamicPropertyChangeEvent' is specified in typesystem, but
not defined. This could potentially lead to compilation errors.
type 'QAbstractState' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QSysInfo' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QCoreApplication' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QThread' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QVariantAnimation' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QPauseAnimation' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QPropertyAnimation' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QXmlStreamAttribute' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QTextDecoder' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QByteArrayMatcher' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QBasicTimer' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QByteArray' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QMargins' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QMutexLocker' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QTimerEvent' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QSize' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QFinalState' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QAbstractFileEngineIterator' is specified in typesystem, but
not defined. This could potentially lead to compilation errors.
type 'QEventTransition' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QProcessEnvironment' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QXmlStreamWriter' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QSizeF' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QXmlStreamReader' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QSystemSemaphore' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QMetaClassInfo' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QLocale' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QRect' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QReadLocker' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QWriteLocker' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QRunnable' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QThreadPool' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QAbstractEventDispatcher' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
type 'QDate' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QDateTime' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QSocketNotifier' is specified in typesystem, but not defined.
This could potentially lead to compilation errors.
type 'QEvent' is specified in typesystem, but not defined. This
could potentially lead to compilation errors.
type 'QPersistentModelIndex' is specified in typesystem, but not
defined. This could potentially lead to compilation errors.
Done, 111 warnings (0 known issues)
generatorrunner doesn't provide the *_wrapper.cpp files and I can't find
a workaround for this last problem.
If you want some additional data or informations, please ask me.
Thanks for any advices
Sylvain Meunier
_______________________________________________
PySide mailing list
PySide@lists.openbossa.org
http://lists.openbossa.org/listinfo/pyside