Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 3 Jan 2005 16:36:36 +0100
From:      Michael Nottebrock <michaelnottebrock@gmx.net>
To:        freebsd-ports@freebsd.org
Subject:   Re: PThread Issue: -pthread vs. -lpthread for a new port
Message-ID:  <200501031636.40424.michaelnottebrock@gmx.net>
In-Reply-To: <20050103114221.GA897@galgenberg.net>
References:  <20050103114221.GA897@galgenberg.net>

next in thread | previous in thread | raw e-mail | index | archive | help
--nextPart1230678.1BTZnkYqzq
Content-Type: text/plain;
  charset="iso-8859-15"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

On Monday, 3. January 2005 12:42, Ulrich Spoerlein wrote:
> Hi all,
>
> I ported [1] wxruby [2] but am running into an issue wrt pthreads. The
> wxruby library gets linked like this:

[...]

> And running a ruby program requiring wxruby I get this error:
> /libexec/ld-elf.so.1: /usr/local/lib/libgthread-2.0.so.400: Undefined
> symbol "pthread_getschedparam"

This is expected: When shared libraries are linked with -pthread, the linke=
r=20
only resolves the necessary symbols but does not emit a DT_NEEDED symbol fo=
r=20
the resulting shared library, it only does for programs.

Bottom line: Pthread symbols must always be resolved through the actual=20
program. Make sure the program that uses wxruby is linked with -pthread as=
=20
well.

=2D-=20
   ,_,   | Michael Nottebrock               | lofi@freebsd.org
 (/^ ^\) | FreeBSD - The Power to Serve     | http://www.freebsd.org
   \u/   | K Desktop Environment on FreeBSD | http://freebsd.kde.org

--nextPart1230678.1BTZnkYqzq
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (FreeBSD)

iD8DBQBB2WaIXhc68WspdLARAvYYAKCnBUNrHgJVA6qusg35lq3VTUeabACePa9O
a/9fGG1J1wX7V0FpLJV2Vj8=
=c2Xa
-----END PGP SIGNATURE-----

--nextPart1230678.1BTZnkYqzq--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200501031636.40424.michaelnottebrock>