This forum has been archived. All content is frozen. Please use KDE Discuss instead.

Unable to find QtScript Qt Bindings

Tags: None
(comma "," separated)
cquiros
Registered Member
Posts
5
Karma
0

Unable to find QtScript Qt Bindings

Mon Aug 17, 2009 11:55 am
Hi,

I'm trying to build Amarok 2.1.1 in KDE 4.3.0

The cmake scripts says that it cannot find the QtScript Qt Bindings.

I installed QtScript Qt Bindings plugins according to the README although I did not build the phonon and xmlpatterns plugins because it fails to build them.

I build them in /usr/local/qtscriptgenerator

However, the FindQtScriptQtBindings.cmake fails to locate QtScript Qt Bindings.

Does the error is linked to this:

To use the plugins in your application, add the plugins path to the library paths
(QCoreApplication::setLibraryPaths())


Thanks for any help
QLands
User avatar
Mamarok
Manager
Posts
6071
Karma
16
OS
Hm, why do you try to build a version where packages have been released since quite some time now? Also, a little more information about your system might be helpful, like what distribution you are using...

FWIW, you need to erase the build folder after adding the QtScriptBindings, as the old CMakeList.txt still has the old information.


Running Kubuntu 22.10 with Plasma 5.26.3, Frameworks 5.100.0, Qt 5.15.6, kernel 5.19.0-23 on Ryzen 5 4600H, AMD Renoir, X11
FWIW: it's always useful to state the exact Plasma version (+ distribution) when asking questions, makes it easier to help ...
cquiros
Registered Member
Posts
5
Karma
0
Hi,

I am building Amarok on a X86 Slackware 12.2

QT Copy: Checked out revision 1007088. Downloaded 05-August-2009 12:00 GMT+3
QT Support: Checked out external at revision 1007208. Downloaded 05-August-2009 12:00 GMT+3

QTDIR=/usr/local/qt4
KDEDIR=/usr/local/kde430
KDE_BUILD=/usr/local/kde430/build

I successfully manage to build a stable version of KDE 4.3

I prefer building all my applications from source.

Here it is the full configuration outout:

-- Taglib found: -L/usr/local/kde430/lib -ltag
-- Found Qt-Version 4.5.1 (using /usr/local/qt451/bin/qmake)
-- Found X11: /usr/lib/libX11.so
-- Phonon Version: 4.3.50
-- Found KDE 4.3 include dir: /usr/local/kde430/include
-- Found KDE 4.3 library dir: /usr/local/kde430/lib
-- Found the KDE4 kconfig_compiler preprocessor: /usr/local/kde430/bin/kconfig_compiler
-- Found automoc4: /usr/local/kde430/bin/automoc4
-- Checking if the QtScript Qt Bindings are installed.
-- includes /usr/local/qt451/include/QtCore;/usr/local/qt451/include/QtScript;/usr/local/kde430/include;/usr/local/kde430/include/KDE;/usr/local/kde430/include/KDE;/usr/local/kde430/include;/usr/local/qt451/include/QtWebKit;/usr/local/qt451/include/QtHelp;/usr/local/qt451/include/QtAssistant;/usr/local/qt451/include/QtDBus;/usr/local/qt451/include/QtTest;/usr/local/qt451/include/QtUiTools;/usr/local/qt451/include/QtScript;/usr/local/qt451/include/QtSvg;/usr/local/qt451/include/QtXml;/usr/local/qt451/include/QtSql;/usr/local/qt451/include/QtOpenGL;/usr/local/qt451/include/QtNetwork;/usr/local/qt451/include/QtDesigner;/usr/local/qt451/include/QtDesigner;/usr/local/qt451/include/QtAssistant;/usr/local/qt451/include/Qt3Support;/usr/local/qt451/include/QtGui;/usr/local/qt451/include/QtCore;/usr/local/qt451/include/Qt;/usr/local/qt451/mkspecs/default;/usr/local/qt451/include;/usr/include;/usr/include;/usr/include;/usr/include;/usr/include;/usr/include;/usr/include;/usr/include;/usr/include;/usr/include;/usr/include;/usr/include;/usr/include;/usr/include;/usr/include;/usr/include;/usr/include;/usr/include;/usr/include;/usr/include;/usr/include;/usr/include;/usr/include;/usr/include;/usr/include;/usr/include libraries /usr/local/qt451/lib/libQtScript.so;/usr/local/qt451/lib/libQtCore.so;-lpthread;/usr/local/qt451/lib/libQtGui.so;-L/usr/local/kde430/lib;-lkdecore;-lkdeui
-- QtBindings not found. run `make bindingstest && ./bindingstest && echo $?` to see what is missing. If it only prints '0' then you're actually fine.
-- Found MySQL: /usr/local/mysqlembedded/include/mysql, /usr/lib/libmysqlclient.so
-- Found MySQL Embedded: /usr/local/mysqlembedded/include/mysql, /usr/local/mysqlembedded/lib/mysql/libmysqld.a
-- Strigi API needs 'signed char'
-- WARNING: you are using the obsolete 'PKGCONFIG' macro use FindPkgConfig
-- Found MTP: /usr/lib/libmtp.so
-- Libgcrypt found: /usr/lib/libgcrypt.so
-- Found GObject libraries: /usr/lib/libgobject-2.0.so;/usr/lib/libgmodule-2.0.so;/usr/lib/libgthread-2.0.so;/usr/lib/libglib-2.0.so
-- Found GObject includes : /usr/include/glib-2.0/gobject
-- checking for one of the modules 'loudmouth-1.0'
-- Could NOT find Loudmouth (missing: LOUDMOUTH_INCLUDE_DIRS LOUDMOUTH_LIBRARIES)
-- WARNING: you are using the obsolete 'PKGCONFIG' macro use FindPkgConfig
-- WARNING: you are using the obsolete 'PKGCONFIG' macro use FindPkgConfig
-- Found MTP: /usr/lib/libmtp.so

-----------------------------------------------------------------------------
-- The following external packages were located on your system.
-- This installation will have the extra features provided by these packages.
-----------------------------------------------------------------------------
* kdelibs - The toolkit Amarok uses to build
* mysqld - Embedded MySQL
* zlib - zlib
* strigi - Index metadata of files
* Gdk - Support for artwork on iPod audio devices via GdkPixbuf
* libmtp - Enable Support for portable media devices that use the media transfer protocol
* curl - cURL provides the necessary network libraries required by mp3tunes.
* libxml2 - LibXML2 is an XML parser required by mp3tunes.
* openssl or libgcrypt - OpenSSL or GNU Libgcrypt provides cryptographic functions required by mp3tunes.
* gobject - Required by mp3tunes.
* Qt4 Glib support - Qt4 must be compiled with glib support for mp3tunes
* glib2 - Required by libgpod and mp3tunes

-----------------------------------------------------------------------------
-- The following OPTIONAL packages could NOT be located on your system.
-- Consider installing them to enable more features from this software.
-----------------------------------------------------------------------------
* libgpod (0.7.0 or higher) <http://sourceforge.net/projects/gtkpod/>
Support Apple iPod audio devices
* loudmouth <http://www.loudmouth-project.org>
Loudmouth is the communication backend needed by mp3tunes for syncing.

-----------------------------------------------------------------------------
-- The following REQUIRED packages could NOT be located on your system.
-- You must install these packages before continuing.
-----------------------------------------------------------------------------
* qtscript-qt <http://code.google.com/p/qtscriptgenerator/>
QtScript Qt Bindings




Many thanks.
User avatar
Mamarok
Manager
Posts
6071
Karma
16
OS
Make sure to set your $PATH correctly, erase the build folder and run cmake again, that should fix it, if you built the QtScriptGenerator correctly.
Works for me in a local build.


Running Kubuntu 22.10 with Plasma 5.26.3, Frameworks 5.100.0, Qt 5.15.6, kernel 5.19.0-23 on Ryzen 5 4600H, AMD Renoir, X11
FWIW: it's always useful to state the exact Plasma version (+ distribution) when asking questions, makes it easier to help ...
cquiros
Registered Member
Posts
5
Karma
0
Yep, that solved the problem. Thanks :)
User avatar
Shaan7
Registered Member
Posts
26
Karma
0
OS
I'm having the same problem. I've built QtScriptGenerator successfully using qtscriptgenerator-src-0.1.0 from its source.
But, cmake is unable to find it. (Same errors as posted by cquiros)
@cquiros What $PATH you set?
Thanks
User avatar
bcooksley
Administrator
Posts
19765
Karma
87
OS
You need to copy it to $QTDIR/lib

Normally $QTDIR on distributions is /usr, however if you compile Qt/KDE yourself from the source repositories, then its location will differ.


KDE Sysadmin
[img]content/bcooksley_sig.png[/img]
User avatar
Shaan7
Registered Member
Posts
26
Karma
0
OS
bcooksley wrote:You need to copy it to $QTDIR/lib

Normally $QTDIR on distributions is /usr, however if you compile Qt/KDE yourself from the source repositories, then its location will differ.


my $QTDIR is ~/kde-qt where i copied the qtscript dir in the lib dir so its path is now
~/kde-qt/lib/qtscriptgenerator-src-0.1.0

ls ~/kde-qt/lib/qtscriptgenerator-src-0.1.0 gives-
doc examples generated_cpp generator LICENSE.GPL plugins qtbindings README tools

Now I removed the amarok build dir and tried again, but no success, same errors.
Was I expected to copy something else?
User avatar
bcooksley
Administrator
Posts
19765
Karma
87
OS
You do not need to copy the full source folder. Rather you should build it outside there like KDE is built then copy the contents of plugins/ to it.


KDE Sysadmin
[img]content/bcooksley_sig.png[/img]
User avatar
Shaan7
Registered Member
Posts
26
Karma
0
OS
bcooksley wrote:You do not need to copy the full source folder. Rather you should build it outside there like KDE is built then copy the contents of plugins/ to it.


Ok, I copied the required files http://pastebin.ca/1561951
Still the error remains (but now it takes some time at the qtscript detection), so I went to ~/kde/src/amarok/cmake/modules/bindingstest , built it and executed ./bindigstest the output is
"qt.core" not found

what might be wrong?
User avatar
bcooksley
Administrator
Posts
19765
Karma
87
OS
Have you correctly exported the following environment variables?

KDEDIR
QTDIR
PATH
LD_LIBRARY_PATH
XDG_DATA_DIRS
CMAKE_PREFIX_PATH
PKG_CONFIG_PATH


KDE Sysadmin
[img]content/bcooksley_sig.png[/img]
User avatar
Shaan7
Registered Member
Posts
26
Karma
0
OS
bcooksley wrote:Have you correctly exported the following environment variables?

KDEDIR
QTDIR
PATH
LD_LIBRARY_PATH
XDG_DATA_DIRS
CMAKE_PREFIX_PATH
PKG_CONFIG_PATH


except $XDG_DATA_DIRS rest of the vars have the values http://pastebin.ca/1561965
Any modifications required?
User avatar
bcooksley
Administrator
Posts
19765
Karma
87
OS
That seems fine, neither of the below changes should make any difference.

You may wish to add $KDEDIR/share/pkgconfig additionally to $PKG_CONFIG_PATH
$XDG_DATA_DIRS should be $KDEDIR/share

Did you have have these variables set when you "make"'ed qtscriptgenerator?


KDE Sysadmin
[img]content/bcooksley_sig.png[/img]
User avatar
Shaan7
Registered Member
Posts
26
Karma
0
OS
bcooksley wrote:That seems fine, neither of the below changes should make any difference.

You may wish to add $KDEDIR/share/pkgconfig additionally to $PKG_CONFIG_PATH
$XDG_DATA_DIRS should be $KDEDIR/share

Did you have have these variables set when you "make"'ed qtscriptgenerator?


Yes, I did have those variables set. To confirm I re "make"'ed the qtscriptgenerator and copied the contents of plugins/script to $QTDIR/lib/ and tried clean+build amarok again. But failed :((
Is there some way to 'debug' this ?
User avatar
Mamarok
Manager
Posts
6071
Karma
16
OS
Did you erase your build folder an ran cmake again first? Else your CMakeCache.txt still has the old values.


Running Kubuntu 22.10 with Plasma 5.26.3, Frameworks 5.100.0, Qt 5.15.6, kernel 5.19.0-23 on Ryzen 5 4600H, AMD Renoir, X11
FWIW: it's always useful to state the exact Plasma version (+ distribution) when asking questions, makes it easier to help ...


Bookmarks



Who is online

Registered users: Bing [Bot], claydoh, Google [Bot], rblackwell, Yahoo [Bot]