Skip Menu |

This queue is for tickets about the Conf-Libconfig CPAN distribution.

Report information
The Basics
Id: 57613
Status: new
Priority: 0/
Queue: Conf-Libconfig

People
Owner: Nobody in particular
Requestors: djerius [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: use ExtUtils::PkgConfig to find libconfig
Hi, Thanks for the interface to libconfig. libconfig installs a pkg-config configuration file. Attached is a patch to Makefile.PL that uses ExtUtils::PkgConfig to use that information to find the library. Thanks, Diab
Subject: Conf-Libconfig-0.017.patch
# This is a patch for Conf-Libconfig-0.017.orig to update it to Conf-Libconfig-0.017 # # To apply this patch: # STEP 1: Chdir to the source directory. # STEP 2: Run the 'applypatch' program with this patch file as input. # # If you do not have 'applypatch', it is part of the 'makepatch' package # that you can fetch from the Comprehensive Perl Archive Network: # http://www.perl.com/CPAN/authors/Johan_Vromans/makepatch-x.y.tar.gz # In the above URL, 'x' should be 2 or higher. # # To apply this patch without the use of 'applypatch': # STEP 1: Chdir to the source directory. # STEP 2: Run the 'patch' program with this file as input. # #### End of Preamble #### #### Patch data follows #### diff -c 'Conf-Libconfig-0.017.orig/Makefile.PL' 'Conf-Libconfig-0.017/Makefile.PL' Index: ./Makefile.PL *** ./Makefile.PL Fri Mar 19 02:17:06 2010 --- ./Makefile.PL Tue May 18 18:05:54 2010 *************** *** 1,6 **** --- 1,7 ---- use strict; use lib '.'; use inc::Module::Install; + use ExtUtils::PkgConfig; #use Devel::CheckLib qw(check_lib_or_exit); name 'Conf-Libconfig'; *************** *** 11,26 **** #requires 'Cwd' => 1.00; #requires 'File::Find' => 1.00; requires 'XSLoader' => 0.05; test_requires 'Test::Deep' => 0.10; test_requires 'Test::More' => 0.90; test_requires 'Test::Warn' => 0.20; test_requires 'Test::Exception' => 0.25; #test_requires 'Test::Spelling' => 0.10; #check_lib_or_exit lib => [qw(config)]; ! checklibs lib => [qw(config)], header => [qw(libconfig.h)]; ! cc_inc_paths '/usr/include', '/usr/local/include'; ! cc_lib_paths '/usr/lib' , '/usr/lib64', '/usr/local/lib', '/usr/local/lib64'; cc_lib_links 'config'; can_cc or die 'This module requires C compiler.'; no_index directory => qw(t inc); auto_install(); --- 12,35 ---- #requires 'Cwd' => 1.00; #requires 'File::Find' => 1.00; requires 'XSLoader' => 0.05; + + configure_requires 'ExtUtils::PkgConfig'; + + test_requires 'Test::Deep' => 0.10; test_requires 'Test::More' => 0.90; test_requires 'Test::Warn' => 0.20; test_requires 'Test::Exception' => 0.25; #test_requires 'Test::Spelling' => 0.10; #check_lib_or_exit lib => [qw(config)]; ! ! my @inc_paths = map { s/-I//; $_ } split(' ', ExtUtils::PkgConfig->cflags_only_I('libconfig')); ! my @lib_paths = map { s/-L//; $_ } split(' ', ExtUtils::PkgConfig->libs_only_L('libconfig')); ! cc_inc_paths @inc_paths; ! cc_lib_paths @lib_paths; cc_lib_links 'config'; + checklibs lib => [qw(config)], header => [qw(libconfig.h)], + incpath => \@inc_paths, libpath => \@lib_paths; can_cc or die 'This module requires C compiler.'; no_index directory => qw(t inc); auto_install(); #### End of Patch data #### #### ApplyPatch data follows #### # Data version : 1.0 # Date generated : Tue May 18 18:07:02 2010 # Generated by : makepatch 2.03 # Recurse directories : Yes # Excluded files : (\A|/).*\~\Z # (\A|/).*\.a\Z # (\A|/).*\.bak\Z # (\A|/).*\.BAK\Z # (\A|/).*\.elc\Z # (\A|/).*\.exe\Z # (\A|/).*\.gz\Z # (\A|/).*\.ln\Z # (\A|/).*\.o\Z # (\A|/).*\.obj\Z # (\A|/).*\.olb\Z # (\A|/).*\.old\Z # (\A|/).*\.orig\Z # (\A|/).*\.rej\Z # (\A|/).*\.so\Z # (\A|/).*\.Z\Z # (\A|/)\.del\-.*\Z # (\A|/)\.make\.state\Z # (\A|/)\.nse_depinfo\Z # (\A|/)core\Z # (\A|/)tags\Z # (\A|/)TAGS\Z # p './Makefile.PL' 1114 1274220354 0100644 #### End of ApplyPatch data #### #### End of Patch kit [created: Tue May 18 18:07:02 2010] #### #### Patch checksum: 91 3488 35684 #### #### Checksum: 109 4194 28658 ####