lua-users home
lua-l archive

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

On Mon, Dec 1, 2008 at 8:51 AM, Simon Lundström <> wrote:
> Hello,
> I'm trying to install lrexlib-pcre via luarocks on Mac OS X where I have
> installed pcre via MacPorts. MacPorts puts its files in /opt/local so
> luarocks doesn't find pcre.h. That should be solved by setting PCRE_DIR to
> /opt/local/include/ but it doesn't.
> bash-3.2# file /opt/local/include/pcre.h
> /opt/local/include/pcre.h: ASCII c program text
> bash-3.2# export PCRE_DIR=/opt/local/include/
> bash-3.2# luarocks install lrexlib-pcre
> Installing
> Archive:
> /tmp/luarocks-rock-lrexlib-pcre-2.3.0-1-1335/lrexlib-pcre-2.3.0-1.src.rock
>  inflating: lrexlib-pcre-2.3.0-1.rockspec
>  extracting:
> Error: Could not find expected file pcre.h for PCRE -- you may have to
> install PCRE in your system and/or set the PCRE_DIR variable

The error message refers to a LuaRocks variable, not a shell
environment variable. Try this:

luarocks install lrexlib-pcre PCRE_DIR=/opt/local/include/

Sorry if the error message is unclear; it will be improved in future versions.

-- Hisham