This is the mail archive of the
libffi-discuss@sourceware.org
mailing list for the libffi project.
Re: Headers installation into libdir?
- From: Luis Lavena <luislavena at gmail dot com>
- To: ssuominen at gentoo dot org, libffi-discuss at sourceware dot org
- Date: Sat, 3 Jul 2010 13:47:21 -0300
- Subject: Re: Headers installation into libdir?
- References: <AANLkTil8PCs4KEmlpVlDibA6F_1LTDsvjK6dnk8xloPm@mail.gmail.com> <4C2F67FF.80706@gentoo.org>
On Sat, Jul 3, 2010 at 1:40 PM, Samuli Suominen <ssuominen@gentoo.org> wrote:
> On 07/03/2010 07:26 PM, Luis Lavena wrote:
>> Hello,
>>
>> I was wondering why libffi 3.0.9 and current master (in GitHub) both
>> install ffi.h and ffitarget.h into libdir/libffi-X.Y.Z/include
>> directory?
>>
>> I believe that specific behavior is not good for packagers or users
>> trying to install libffi for normal usage.
>>
>> Please find attached a patch against master that corrects this behavior.
>>
>> Thank you.
>
> I think it's because of arch specific headers it installs.
>
> example snippet from ffi.h:
>
> /* Specify which architecture libffi is configured for. */
> #define X86_64
>
> So the way it's installed now is in fact correct.
>
> You should use pkg-config in your projects, like:
>
> gcc `pkg-config --cflags libffi` -lffi main.c
>
> $ pkg-config --cflags libffi
> -I/usr/lib64/libffi-3.0.9/include
> $ pkg-config --libs libffi
> -lffi
The problem is MinGW where there is no working, out of the box
pkg-config utility.
That you for your answer, I couldn't find any reference of other
library doing the same.
--
Luis Lavena
AREA 17
-
Perfection in design is achieved not when there is nothing more to add,
but rather when there is nothing more to take away.
Antoine de Saint-Exupéry