gsl-shell-info
[Top][All Lists]
Advanced

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

Re: [Gsl-shell-info] Building and Installing from Source on Ubunut 12.04


From: Martin Felis
Subject: Re: [Gsl-shell-info] Building and Installing from Source on Ubunut 12.04
Date: Fri, 16 Aug 2013 23:20:25 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130623 Thunderbird/17.0.7

Whoops! Just saw that I responded to the wrong thread. Sorry for that.
For completeness, here is the right mail for the right thread:

Hi Francesco,

thanks for your checks and reply.

I found the problem on my side: I had LUA_PATH using the command
'luarocks path'. If delete the environment variable LUA_PATH gsl-shell
works directly.

I tried to further investigate this, as it seemed odd to me that
gsl-shell has problems with the environment variable LUA_PATH. After
having a look at the code in luajit/src/lib_package.c:542 I figured,
that package.path is initialized using the environment variable of
LUA_PATH in which all occurences of ";;" are replaced with additional
default paths that are defined in luaconf.h in the #define LUA_PATH_DEFAULT.

After adding a double semicolon ";;" to LUA_PATH everything works.

Best regards,
Martin

P.S.: I also had a look at the standard Lua code at it has the same
behaviour. Am I lacking any common knowledge about package.path and
LUA_PATH here?


On 12.08.2013 23:37, Francesco Abbate wrote:
> 2013/8/12 Martin Felis <address@hidden>:
>> Hi there,
>>
>> just stumbled over gsl-shell and instantly got curious about it and
>> dearly hope to make good use of this fine composition of software!
> 
> Hi Martin,
> 
> I'm glad that you are interested in gsl shell, I hope you will find it useful.
> 
>> When trying to build it under Ubuntu 12.04 I ran into a few bumps that
>> I'd like to share and how to resolve them. Some of the things are
>> already hinted in INSTALL, however it lacked the setting of the LUA_PATH
>> which resulted in the error:
>>
>> gsl-shell: module 'gslext' not found:
>>         no field package.preload['gslext']
>>
>> First of all you need the following packages installed to make the
>> compilation work:
>>
>> libagg-dev
>> libgsl0-dev
>> libreadline-dev
>> libfreetype6-dev
>>
>> If you want to install it other than the default /usr/local you have to
>> edit the file makeconfig and set your desired path in the variable PREFIX.
> 
> Thank you for sharing that. I probably need to update the INSTALL file
> with more accurate informations :-)
> 
> The list of needed package is probably not exhaustive, you need to add:
> 
> libx11-dev
> 
> and for the FOX GUI
> 
> libfox-1.6-dev
> 
> In addition it is probably a good idea to install also libopenblas-dev
> since these are much better optimized then gslcblas included with the
> GSL library.
> 
>> After running a successful "make" and "make install" the files are
>> installed. To be able for gsl-shell to find your scripts you have to add
>> paths to the LUA_PATH environment variable. These are the following:
> 
> You should not need to set LUA_PATH. Just set PREFIX in makeconfig as
> you suggest, than make && make install. The you can invoke directly
> gsl shell without setting any variable.
> 
> I've just tested that with the vanilla gsl shell source code and it
> does work out of the box (setting PREFIX to /tmp/local):
> 
> ------------
> GSL Shell 2.3.0, Copyright (C) 2009-2013 Francesco Abbate
> GNU Scientific Library, Copyright (C) The GSL Team
> LuaJIT 2.0.1 -- Copyright (C) 2005-2013 Mike Pall. http://luajit.org/
> JIT: ON CMOV SSE2 SSE3 ATOM fold cse dce fwd dse narrow loop abc sink fuse
> 
> Documentation available at http://www.nongnu.org/gsl-shell/doc/.
> To obtain help on a function or object type: help(func).
> Type demo() to see the lists of demo.
> 
>> package.path
> ./?.lua;./templates/?.lua.in;/tmp/local/share/luajit-2.0.1/?.lua;/tmp/local/share/gsl-shell/2.3/?.lua;/tmp/local/share/gsl-shell/2.3/?/init.lua;/tmp/local/share/gsl-shell/2.3/templates/?.lua.in;/tmp/local/share/gsl-shell/2.3/?.lua;/tmp/local/share/gsl-shell/2.3/?/init.lua
> ------------
> 
>> After this you should be able to run gsl-shell from your favourite
>> terminal emulator.
> 
> 
> I really hope that gsl shell users don't need to set such a
> complicated variable just to use gsl shell! :-)
> 
> Francesco
> 


-- 
mail  : address@hidden
phone : +49 6221 544983
office: IWR | Speyerer Str 6 | Room 319 | 69115 Heidelberg | Germany



reply via email to

[Prev in Thread] Current Thread [Next in Thread]