Re: Checking Installed library

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 





On Sat, Jul 18, 2009 at 1:05 PM, Manish Katiyar <mkatiyar@xxxxxxxxx> wrote:
On Sat, Jul 18, 2009 at 9:48 AM, Rishi Agrawal<rishi.b.agrawal@xxxxxxxxx> wrote:
>
>
> On Fri, Jul 17, 2009 at 7:22 PM, Manish Katiyar <mkatiyar@xxxxxxxxx> wrote:
>>
>> On Fri, Jul 17, 2009 at 10:34 PM, Rishi
>> Agrawal<rishi.b.agrawal@xxxxxxxxx> wrote:
>> >
>> >
>> > On Fri, Jul 17, 2009 at 12:40 PM, Rishi Agrawal
>> > <rishi.b.agrawal@xxxxxxxxx>
>> > wrote:
>> >>
>> >>
>> >> On Fri, Jul 17, 2009 at 12:27 PM, Mulyadi Santosa
>> >> <mulyadi.santosa@xxxxxxxxx> wrote:
>> >>>
>> >>> On 7/17/09, Rishi Agrawal <rishi.b.agrawal@xxxxxxxxx> wrote:
>> >>> > Is autoconfigure the only way to find this out.??
>> >>> >
>> >>> > On Wed, Jul 15, 2009 at 6:52 AM, Pei Lin <telent997@xxxxxxxxx>
>> >>> > wrote:
>> >>>
>> >>> Please don't do top posting...
>> >>>
>> >>> Although it's OOT, I can help a bit. IMO, you can directly check
>> >>> /usr/lib or parse /etc/ld.so.conf and so on to find the related DSO
>> >>> and header files. However, doing that will require more time and
>> >>> probably not portable across system, in fact it's kinda reinventing
>> >>> the wheel.
>> >>>
>> >>> So, I personally suggest to adopt autoconfigure.
>> >>>
>> >>> --
>> >>> regards,
>> >>>
>> >>> Mulyadi Santosa
>> >>> Freelance Linux trainer
>> >>> blog: the-hydra.blogspot.com
>> >>
>> >>
>> >> I will have a detailed look at the autoconfigure utility and see.
>> >>
>> >> Thanks for all the help.
>> >>
>> >> --
>> >> Regards,
>> >> Rishi B. Agrawal
>> >> http://www.linkedin.com/in/rishibagrawal
>> >> http://code.google.com/p/fscops/
>> >
>> >
>> > I have used it and it is working very good.
>> >
>> > I wanted to know that
>> >
>> > How to check the presence of libxml2 library using autoconfigure ?
>>
>> First link in google.
>>
>>
>> http://www.kdevelop.org/index.html?filename=3.0/doc/tutorial_autoconf.html
>>
>> Thanks -
>> Manish
>>
>> >
>> >
>> > --
>> > Regards,
>> > Rishi B. Agrawal
>> > http://www.linkedin.com/in/rishibagrawal
>> > http://code.google.com/p/fscops/
>> >
>>
>>
>>
>> --
>> Thanks -
>> Manish
>
> Actually I tried using that information earlier but somehow it did not work.

Can you please tell us a little more why it didn't work ? Any errors
or anything else ??

>
> Currently I am using a macro which checks wether a function is present in
> the mentioned library.

I didn't understand this ? are you using something like nm ??

>
> like printf can be checked in libc
>
> I used a function "xmlParsefile" and "libxml2" library and this works fine.
> The logic behind this is that when the function is present in the library
> then the library is also present on the system (is it correct ??)

Should be... but by any chance are you relying the library to be
present in a particular path ?? If that's the case it is not going to
work anywhere ?

Thanks -
Manish

>
>
>
>
>
>
> --
> Regards,
> Rishi B. Agrawal
> http://www.linkedin.com/in/rishibagrawal
> http://code.google.com/p/fscops/
>



--
Thanks -
Manish

I am using this particular line:

AC_CHECK_LIB(xml2,xmlParseFile,,AC_MSG_ERROR(oops! no function xmlParseFile function in xml?!?),) in my configure.in for autoconf

The use of macro is

AC_CHECK_LIB : Checks whether a function exists in the given library (library names without the leading lib, e.g., for libxml, use just xml here)

It seems that it is not path dependant.
--
Regards,
Rishi B. Agrawal
http://www.linkedin.com/in/rishibagrawal
http://code.google.com/p/fscops/

[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux