Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Inline-Lua CPAN distribution.

Report information
The Basics
Id: 31665
Status: resolved
Priority: 0/
Queue: Inline-Lua

People
Owner: Nobody in particular
Requestors: jamesw [...] bsdhosting.co.za
Cc: ILYAM [...] cpan.org
AdminCc:

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



Subject: Inline::Lua patch to replace lua-config with pkg-config
Date: Tue, 18 Dec 2007 12:42:28 -0800
To: bug-Inline-Lua [...] rt.cpan.org
From: James Wright <jamesw [...] bsdhosting.co.za>
pkg-config is a more portable solution for getting the libs and includes.
--- Makefile.PL.orig Mon Dec 3 11:37:58 2007 +++ Makefile.PL Mon Dec 3 11:38:28 2007 @@ -9,11 +9,11 @@ my $meth = shift; # lua-config is Debian specific if ($meth == LUA_LIBS) { - chomp (my $val = `lua-config --libs` || "-llua -llualib"); + chomp (my $val = `pkg-config lua --libs` || "-llua -llualib"); return $val; } if ($meth == LUA_INC) { - chomp (my $val = `lua-config --include` || ""); + chomp (my $val = `pkg-config lua --cflags` || ""); return $val; } }
I just tried to build this module on Ubuntu 9.04 with lua5.1. I found that I need a slightly different patch to build it: --- /tmp/Inline-Lua-0.04/Makefile.PL 2007-04-16 14:05:11.000000000 +0400 +++ Inline-Lua-0.04/Makefile.PL 2009-06-05 16:47:30.000000000 +0400 @@ -9,11 +9,11 @@ my $meth = shift; # lua-config is Debian specific if ($meth == LUA_LIBS) { - chomp (my $val = `lua-config --libs` || "-llua -llualib"); + chomp (my $val = `pkg-config lua5.1 --libs` || "-llua -llualib"); return $val; } if ($meth == LUA_INC) { - chomp (my $val = `lua-config --include` || ""); + chomp (my $val = `pkg-config lua5.1 --cflags` || ""); return $val; } } I.e. lua5.1 instead of lua in pkg-config call.
On Fri Jun 05 08:53:35 2009, ILYAM wrote: Show quoted text
> I just tried to build this module on Ubuntu 9.04 with lua5.1. I found > that I need a slightly different patch to build it: > > --- /tmp/Inline-Lua-0.04/Makefile.PL 2007-04-16 14:05:11.000000000 +0400 > +++ Inline-Lua-0.04/Makefile.PL 2009-06-05 16:47:30.000000000 +0400 > @@ -9,11 +9,11 @@ > my $meth = shift; > # lua-config is Debian specific > if ($meth == LUA_LIBS) { > - chomp (my $val = `lua-config --libs` || "-llua -llualib"); > + chomp (my $val = `pkg-config lua5.1 --libs` || "-llua -llualib"); > return $val; > } > if ($meth == LUA_INC) { > - chomp (my $val = `lua-config --include` || ""); > + chomp (my $val = `pkg-config lua5.1 --cflags` || ""); > return $val; > } > } > > I.e. lua5.1 instead of lua in pkg-config call.
That is unfortunate, the lua 5.1 tarball from the source contains a lua.pc, which debian's packaging renames, see http://pkg-lua.alioth.debian.org/policy.html but some systems (and hand-installed lua installations) will still use lua.pc really defeats the purpose of pkg-config *blah*
I modified this in 0.05 to try both lua-config and pkg-config.