From kde-core-devel Thu Nov 01 11:05:42 2007 From: Thiago Macieira Date: Thu, 01 Nov 2007 11:05:42 +0000 To: kde-core-devel Subject: Re: WITH_PREFIX for kdemodules? Message-Id: <200711011205.49638.thiago () kde ! org> X-MARC-Message: https://marc.info/?l=kde-core-devel&m=119391518819717 MIME-Version: 1 Content-Type: multipart/mixed; boundary="--nextPart1193942664.CJXjiLClBH" --nextPart1193942664.CJXjiLClBH Content-Type: text/plain; charset="iso-8859-6" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Em Thursday 01 November 2007 10:12:48 Alexander Neundorf escreveu: > On Wednesday 31 October 2007, Thiago Macieira wrote: > > Em Wednesday 31 October 2007 16:28:46 Matthias Kretz escreveu: > > > On Monday 29 October 2007, Jaroslaw Staniek wrote: > > > > Is there a technical reason (e.g. some tools expect this) to use > > > > 'lib' prefix for kde plugins? > > > > > > I was chatting with dirk about this once and he convinced me that it's > > > a nice feature to have on Linux where it's possible to use the lib as > > > plugin and shared lib at the same time. E.g. applications like konsole > > > that provide a KPart and a shell. To save some startup time konsole on > > > Linux could link to it's part instead of dlopening it. > > > > That's a great feature, but that doesn't work in all platforms. > > > > Fortunately, I don't know of any platform that Qt supports and where th= at > > feature isn't supported. I recall MacOS X being one of them, but I no > > longer can find that information. > > > > Maybe it's for MacOS X < 10.3 (which introduced dlfcn.h and dlopen(3)). > > Which feature ? > Linking to a shared library (which is a plugin at the same time) which > doesn't have the "lib" prefix ? The feature in which "module" and "library" are the same. Normally, you can: - link to a library - dlopen a module With ELF, you also can: - dlopen a library - link to a module That's because modules and libraries are the same thing called "shared=20 objects". MacOS X (Mach-O file format) has a difference between those two: modules ar= e=20 of type MH_BUNDLE while libraries are of type MH_DYLIB. But I've just check= ed=20 the Qt/Mac builds and our plugins are MH_DYLIB -- that's probably why the=20 restriction no longer applies. None of the other platforms we support have this distinction (AIX is XCOFF,= =20 Windows is COFF PE, everything else is ELF). =2D-=20 =A0 Thiago Macieira =A0- =A0thiago (AT) macieira.info - thiago (AT) kde.org =A0 =A0 PGP/GPG: 0x6EF45358; fingerprint: =A0 =A0 E067 918B B660 DBD1 105C =A0966C 33F5 F005 6EF4 5358 --nextPart1193942664.CJXjiLClBH Content-Type: application/pgp-signature; name=signature.asc Content-Description: This is a digitally signed message part. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.7 (GNU/Linux) iD8DBQBHKbMGM/XwBW70U1gRArxRAJ0dhsrVyvoPMMyW4qw7ebY4hien9wCgi5+Z 67Ge//8OwGwhdj7234PAZy4= =weMN -----END PGP SIGNATURE----- --nextPart1193942664.CJXjiLClBH--