LUA_CPATH_DEFAULT broken when not building with debhelper
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
lua5.1 (Debian) |
New
|
Undecided
|
Unassigned | ||
lua5.1 (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
There was an upstream changeset (5.1.4-6) which introduced DEB_HOST_MULTIARCH for the LUA_CPATH_DEFAULT like in luaconf.h, like so:
#define LUA_CDIR2 LUA_ROOT2 "lib/" DEB_HOST_MULTIARCH "/lua/5.1/"
...
#define LUA_CPATH_DEFAULT \
"./?.so;" LUA_CDIR"?.so;" LUA_CDIR2"?.so;" LUA_CDIR3"?.so;" LUA_CDIR"
#endif
The DEB_HOST_MULTIARCH is only set during the Debian build process, or manually through the preprocessor. Since Lua packages are built in this way they include the LUA_CPATH_DEFAULT properly.
However, this change breaks the compilation of programs which embed Lua and rely upon LUA_CPATH_DEFAULT:
error: expected ')' before 'DEB_HOST_
A workaround is to set DEB_HOST_MULTIARCH manually (dpkg-architecture -qDEB_HOST_
This is a change between Oneiric (using 5.1.4-5) and Precise (5.1.4-12ubuntu1). Perhaps the affected population is small since this change has been in Debian since July 2011.
This bug was fixed in the package lua5.1 - 5.1.5-2
---------------
lua5.1 (5.1.5-2) unstable; urgency=low
* Put in the pkg-config .pc file -DDEB_HOST_ MULTIARCH so that including
lua.h (and consequently luaconf.h) works fine even if one is not using
debhelpers (Closes: #671286, LP: #977813)
-- Enrico Tassi <email address hidden> Thu, 03 May 2012 14:34:16 +0200