PDA

View Full Version : Designer doesn't load wwWidgets plugin



reimer
20th June 2008, 14:23
Hi everyone,

I need wwWidgets support in my Designer but after compilation and installation Designer doesn't load it.

Furthermore the header files are not copied into one of the Qt folders.

I'm using Tiger (Mac OS X 10.4).

jpn
23rd June 2008, 07:20
What does Help->About Plugins say?

wysota
23rd June 2008, 08:30
Did you run make install after compilation with super user privileges? Could you check if the installer tried to copy the header files somewhere? It should be in the installation log on your console.

reimer
23rd June 2008, 09:33
Oh no. I think I did it with no super user privileges.

I've just installed it as su and the header files are now located in /usr/include/wwWidgets

Fine so far.

In Designer the plugin is listed under "Failed Plugins". Designer tells me that it's no valid plugin. :eek:

reimer
23rd June 2008, 10:13
I can't find anything in my log files except what I did today.

wysota
23rd June 2008, 11:36
Could you check if the libwwwidgets4.dylib (or similar) file exists in lib subdir of your Qt installation along other Qt libraries?

reimer
23rd June 2008, 11:48
Could you check if the libwwwidgets4.dylib (or similar) file exists in lib subdir of your Qt installation along other Qt libraries?

It exists => /Developer/Applications/Qt/plugins/designer/libwwwidgetsplugin.dylib

The problem is not my plugin itself but the header files I suppose. The header files were copied to /usr/include/wwWidgets/ because there were no rules for Mac OS. But I should create a framework too for wwWidgets. I have to check how I can do this.

wysota
23rd June 2008, 12:42
Not that file. I meant libwwwidgets4.dylib not the plugin. The plugin depends on the widget library. The header files have nothing to do with loading the plugin into Designer. The only two files that matter are the plugin and the widget library. I've seen the plugin work on Mac, so it should work for you as well.

reimer
23rd June 2008, 12:54
There is such a file in /Library/Frameworks . Maybe it's in the wrong directory?

There are two possibilities to install Qt, as framework or as like under Unix/Linux.

wysota
23rd June 2008, 13:51
Call ldd on the plugin and see if the widget library is found or not.

It should contain output similar to:

libwwwidgets4.so.0 => /usr/local/Qt4/qt-4.4/lib/libwwwidgets4.so.0 (0xb7e7e000)

reimer
23rd June 2008, 15:55
otool can't find it.

wysota
23rd June 2008, 21:44
Try placing it (widget library) alongside other Qt libs. Make sure otool has the same environment set as all Qt stuff.

reimer
24th June 2008, 09:55
otool -L /Developer/Applications/Qt/Designer.app/Contents/MacOS/Designer
/Developer/Applications/Qt/Designer.app/Contents/MacOS/Designer:
QtDesignerComponents.framework/Versions/4/QtDesignerComponents (compatibility version 4.3.0, current version 4.3.4)
QtDesigner.framework/Versions/4/QtDesigner (compatibility version 4.3.0, current version 4.3.4)
QtAssistant.framework/Versions/4/QtAssistant (compatibility version 4.3.0, current version 4.3.4)
QtScript.framework/Versions/4/QtScript (compatibility version 4.3.0, current version 4.3.4)
QtXml.framework/Versions/4/QtXml (compatibility version 4.3.0, current version 4.3.4)
QtGui.framework/Versions/4/QtGui (compatibility version 4.3.0, current version 4.3.4)
/System/Library/Frameworks/Carbon.framework/Versions/A/Carbon (compatibility version 2.0.0, current version 128.0.0)
/System/Library/Frameworks/AppKit.framework/Versions/C/AppKit (compatibility version 45.0.0, current version 824.34.0)
QtNetwork.framework/Versions/4/QtNetwork (compatibility version 4.3.0, current version 4.3.4)
QtCore.framework/Versions/4/QtCore (compatibility version 4.3.0, current version 4.3.4)
/usr/lib/libz.1.dylib (compatibility version 1.0.0, current version 1.2.3)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 88.1.3)
/usr/lib/libiconv.2.dylib (compatibility version 5.0.0, current version 5.0.0)
/System/Library/Frameworks/ApplicationServices.framework/Versions/A/ApplicationServices (compatibility version 1.0.0, current version 22.0.0)
/usr/lib/libstdc++.6.dylib (compatibility version 7.0.0, current version 7.4.0)
/usr/lib/libgcc_s.1.dylib (compatibility version 1.0.0, current version 1.0.0)
I didn't use otool correctly yesterday. But Designer can't find it anyway. I found out that there's no standard location I can put my dynamic libraries into. I'm not so familiar with that stuff so I'm learning many new things. Maybe it's possible to add the location manually in Designer.app.

Interesting link: http://www.cocoadev.com/index.pl?ApplicationLinking

wysota
24th June 2008, 23:14
Unfortunately I'm not familiar with Mac framework design, so I'm not able to help you much... I can suggest putting the widget library into /usr/lib and it should work there, but that's a dirty solution...

reimer
25th June 2008, 08:20
As I said there's no standard location. It didn't work.

reimer
25th June 2008, 10:16
I've seen the plugin work on Mac...Do you remember where you've seen it?

wysota
25th June 2008, 13:55
Yes, I think so. I'll try to get some info about it, but it won't happen before next week. Unfortunately I don't have access to a Mac, so I can't check it out myself.

reimer
27th June 2008, 14:00
To create a framework you have to add lib_bundle to CONFIG. Then adjust the path to the lib. For me it didn't worked fine. Should anything else be done?
widgets.pro

mac : CONFIG += lib_bundle

plugin.pro


mac : LIBS += -L../widgets/wwwidgets4.framework -lwwwidgets4
#mac : LIBS += -L../widgets/wwwidgets4.framework/Versions/0 -lwwwidgets4


/usr/libexec/gcc/i686-apple-darwin8/4.0.1/libtool: can't locate file for: -lwwwidgets4
/usr/libexec/gcc/i686-apple-darwin8/4.0.1/libtool: file: -lwwwidgets4 is not an object file (not allowed in a library)

reimer
4th July 2008, 22:34
Yes, I think so. I'll try to get some info about it, but it won't happen before next week. Unfortunately I don't have access to a Mac, so I can't check it out myself.
Any news ?

wysota
6th July 2008, 09:48
Blah, sorry, I forgot :( Give me time until Wednesday, please.

A side question - does the widget library work? Apart from the non-working plugin, can you use wwWidgets by adding CONFIG+=wwwidgets to your project file?

wysota
6th July 2008, 12:27
Ok, I've done some reading. First of all please run otool on the wwidgets plugin (libwwwidgetsplugin.dylib) and post the result here. Then run otool on the widget library (libwwwidgets4.dylib) and post the result as well. Finally post the absolute path to:
1. Qt libraries
2. libwwwidgets4.dylib
3. libwwwidgetsplugin.dylib

You'll need all that information to use a tool called install_name_tool. You can enter its name in Qt Assistant to learn about what it does.

GoaSkin
7th February 2009, 03:23
I solved it... the solution by Reimer was very close.

But you cannot add a reference to a framework like a library. Mac OS X frameworks are little bit different that .dylib libraries, so libtool fails if you handle the framework like a dylib.

In plugin.pro, the correct declaration is:



LIBS += -framework wwwidgets4


Note that this requires that the framework already exists in /Library/Frameworks!

So, compile the main plugin, run 'make install' and produce the designer plugin after...