aboutsummaryrefslogtreecommitdiffstats
path: root/USER/Makefile.PL
diff options
context:
space:
mode:
authorDaouda Lo <daouda@mandriva.com>2003-08-22 11:02:16 +0000
committerDaouda Lo <daouda@mandriva.com>2003-08-22 11:02:16 +0000
commit8506646e8b632e9be720ebc6be6917bddebc3acb (patch)
tree371256a287e1361272dd62be461a1db497c56017 /USER/Makefile.PL
parent971d99e772be4dd3a6bd0df91861d5d21440efe9 (diff)
downloaduserdrake-8506646e8b632e9be720ebc6be6917bddebc3acb.tar
userdrake-8506646e8b632e9be720ebc6be6917bddebc3acb.tar.gz
userdrake-8506646e8b632e9be720ebc6be6917bddebc3acb.tar.bz2
userdrake-8506646e8b632e9be720ebc6be6917bddebc3acb.tar.xz
userdrake-8506646e8b632e9be720ebc6be6917bddebc3acb.zip
- use pkg-config
Diffstat (limited to 'USER/Makefile.PL')
-rw-r--r--USER/Makefile.PL8
1 files changed, 6 insertions, 2 deletions
diff --git a/USER/Makefile.PL b/USER/Makefile.PL
index 528ff24..209af58 100644
--- a/USER/Makefile.PL
+++ b/USER/Makefile.PL
@@ -2,13 +2,17 @@ use ExtUtils::MakeMaker;
$Verbose=1;
# See lib/ExtUtils/MakeMaker.pm for details of how to influence
# the contents of the Makefile that is written.
+my $libs = "" . `pkg-config --libs libuser`;
+chomp $libs;
+$libs .= "-lpam_misc -lpam ";
+print "\n\n\n\nI need to link with «$libs»\n\n\n\n\n\n";
WriteMakefile(
'NAME' => 'USER',
'VERSION_FROM' => 'USER.pm',
'OBJECT' => 'USER.o', # link all the C files too
- 'LIBS' => ['-lgmodule-2.0 -lglib-2.0 -lgobject-2.0 -libpam_misc -libpam -lcrypt -luser'], # e.g., '-lm'
+ 'LIBS' => "\"$libs\"", # e.g., '-lm'
'DEFINE' => '', # e.g., '-DHAVE_SOMETHING'
- 'INC' => '-I/usr/include/libuser -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include', # e.g., '-I. -I/usr/include/other'
+ 'INC' => "`pkg-config --cflags libuser`", # e.g., '-I. -I/usr/include/other'
'XSPROTOARG' => '-noprototypes',
'TYPEMAPS' => ['../perlobject.map' ],
);