[R] [FORGED] Re: installing "rgl" package

Rolf Turner
Fri, 24 Nov 2017 05:04:59 -0000

On 24/11/17 12:10, Duncan Murdoch wrote:
> On 23/11/2017 6:05 PM, Santosh wrote:
>> Hi Rxperts,
>> I am trying to install 'rgl' package in Ubuntu.. Would highly
appreciate
>> your assistance .. I tried several leads available on various
discussion
>> fora and nothing helped so far.
>
> Your message is really hard to follow, since you posted in HTML.? You
> need the OpenGL development packages.? On Ubuntu, that probably means
> MesaGL, but I don't know the names of the development packages. >
> Duncan Murdoch
>

The installation of rgl runs without complaint on my system, so
apparently I have whatever libraries are needed.

I did "apt-show-versions | grep mesa" on my laptop (a trick I just
learned from Berwin Turlach; thanks Berwin!) and got a slew of bumff:

> libegl1-mesa:amd64/xenial-updates 17.0.7-0ubuntu0.16.04.2 uptodate
> libegl1-mesa-drivers:amd64/xenial-updates 12.0.6-0ubuntu0.16.04.1 uptodate
> libgl1-mesa-dev:amd64/xenial-updates 17.0.7-0ubuntu0.16.04.2 uptodate
> libgl1-mesa-dri:amd64/xenial-updates 17.0.7-0ubuntu0.16.04.2 uptodate
> libgl1-mesa-glx:amd64/xenial-updates 17.0.7-0ubuntu0.16.04.2 uptodate
> libglapi-mesa:amd64/xenial-updates 17.0.7-0ubuntu0.16.04.2 uptodate
> libglu1-mesa:amd64/xenial 9.0.0-2.1 uptodate
> libglu1-mesa-dev:amd64/xenial 9.0.0-2.1 uptodate
> libwayland-egl1-mesa:amd64/xenial-updates 17.0.7-0ubuntu0.16.04.2 uptodate
> mesa-common-dev:amd64/xenial-updates 17.0.7-0ubuntu0.16.04.2 uptodate
> mesa-utils:amd64/xenial 8.3.0-1 uptodate
> mesa-vdpau-drivers:amd64/xenial-updates 17.0.7-0ubuntu0.16.04.2 uptodate

(There were also a bunch of lines referring to i386 versions not being
installed; I deleted these to save space.)

So it would seem that you need to do at least:

     sudo apt-get install libegl1-mesa
     sudo apt-get install libegl1-mesa-dev

Doing this may result in the other bumff that is referred to getting
installed automatically.  Try it and see if it works.  If not, keep
doing the sudo apt-get install thing to the other bits and pieces until
it does work.

Hope this helps; kind of a case of the blind leading the blind, but I
*think* this should get you going with rgl.

cheers,

Rolf Turner

--
Technical Editor ANZJS
Department of Statistics
University of Auckland
Phone: +64-9-373-7599 ext. 88276

>>
>>
>> * installing *source* package ?rgl? ...checking for gcc... gcc
-std=gnu99
>> checking whether the C compiler works... yes
>> checking for C compiler default output file name... a.out
>> checking for suffix of executables...
>> checking whether we are cross compiling... no
>> checking for suffix of object files... o
>> checking whether we are using the GNU C compiler... yes
>> checking whether gcc -std=gnu99 accepts -g... yes
>> checking for gcc -std=gnu99 option to accept ISO C89... none needed
>> checking how to run the C preprocessor... gcc -std=gnu99 -E
>> checking for gcc... (cached) gcc -std=gnu99
>> checking whether we are using the GNU C compiler... (cached) yes
>> checking whether gcc -std=gnu99 accepts -g... (cached) yes
>> checking for gcc -std=gnu99 option to accept ISO C89... (cached) none
>> needed
>> checking for libpng-config... yes
>> configure: using libpng-config
>> configure: using libpng dynamic linkage
>> checking for X... libraries , headers
>> checking GL/gl.h usability... yes
>> checking GL/gl.h presence... yes
>> checking for GL/gl.h... yes
>> checking GL/glu.h usability... yes
>> checking GL/glu.h presence... yes
>> checking for GL/glu.h... yes
>> checking for glEnd in -lGL... noconfigure: error: missing required
>> library GLERROR: configuration failed for package ?rgl?* removing
>> ?/data/R/lib/rgl?Warning in install.packages :
>> ?? installation of package ?rgl? had non-zero exit status
>>
>> Checking the system dependencies based on README..
>>
>> system('dpkg -l |grep? libgl1')ii? libgl1-mesa-dev
>> ?? 10.1.3-0ubuntu0.6?????????????????????? amd64??????? free
>> implementation of the OpenGL API -- GLX development files
>>
>>> system('dpkg -l |grep? libglu1')ii
>>> libglu1-mesa:amd64
>>> 9.0.0-2???????????????????????????????? amd64??????? Mesa OpenGL
>>> utility library (GLU)
>> ii? libglu1-mesa-dev????????????????????? 9.0.0-2
>> ??????????? amd64??????? Mesa OpenGL utility library -- development
>> files
>>
>>> system('dpkg -l |grep? libpng')ii
>>> libpng12-0:amd64
>>> 1.2.50-1ubuntu2.14.04.2???????????????? amd64??????? PNG library -
>>> runtime
>> ii? libpng12-dev????????????????????????? 1.2.50-1ubuntu2.14.04.2
>> ??????????? amd64??????? PNG library - development
>>
>> I also tried installing .. using the following command..
>> install.packages("rgl",dep=T,
>> INSTALL_opts="--no-multiarch",
>> configure.args=c(rgl="--with-gl-includes=/usr/include/GL"))