Gentoo Archives: gentoo-user

From: Paul Hartman <paul.hartman+gentoo@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] [Slightly OT] Linking to a non-standard library installed using portage
Date: Thu, 03 Feb 2011 19:48:08
Message-Id: AANLkTin+E8gpRm6e3rtdECGv9FuzFAWcAcJQ2a=1NZ9o@mail.gmail.com
In Reply to: [gentoo-user] [Slightly OT] Linking to a non-standard library installed using portage by Mark Knecht
1 On Thu, Feb 3, 2011 at 12:39 PM, Mark Knecht <markknecht@×××××.com> wrote:
2 > Hi,
3 >   This is going to be trivial for anyone who actually programs.
4 > Thanks in advance.
5 >
6 >   How do I link to a library I installed using portage? If someone
7 > could show me an example make file that would be great.
8
9 Don't know about nvcc but with gcc you'd use -l (that's a lower-case letter L):
10
11 -lyourlibname
12
13 So in your case maybe something like this might work:
14
15 nvcc -L/usr/lib64/libta_lib ta-lib-ma.cu -o ta-lib-ma -lta_lib