These are chat archives for jheinen/GR.jl

25th
Mar 2019
Alish Dipani
@alishdipani
Mar 25 15:55

Hello,

I am trying to install GR library for C on Ubuntu 18.04, I followed the steps mentioned on the website here. This did not work and gave the error :
foo.c:1:10: fatal error: gr.h: No such file or directory

include <gr.h>

      ^~~~~~

compilation terminated.

I also tried source install from git mentioned here but it gives the same error.

I also tried using GR prebuilt binaries using this command : gcc -L/home/alu57202/Downloads/gr/lib -I/home/alu57202/Downloads/gr/include -lGR foo.c
This command recognizes gr but then gives the following error :
/tmp/cckVLH59.o: In function main': foo.c:(.text+0xc0): undefined reference togr_polyline'
foo.c:(.text+0xd5): undefined reference to gr_tick' foo.c:(.text+0xef): undefined reference togr_tick'
foo.c:(.text+0x11f): undefined reference to `gr_axes'
collect2: error: ld returned 1 exit status

Can anyone help me regarding this?

Thank You.

Josef Heinen
@jheinen
Mar 25 16:39
cc -I/usr/local/gr/include foo.c -L/usr/local/gr/lib -lGR -Wl,-rpath,/usr/local/gr/lib - probably a candidate for an alias or script
... or should be explained in the documentation

@v0dro :

@jheinen is it possible to explicitly set the X/Y co-ordinates on the axes and not rely solely on the parameters passed to gr_axes?

It's on our TODO list ...

Alish Dipani
@alishdipani
Mar 25 18:15
cc -I/usr/local/gr/include foo.c -L/usr/local/gr/lib -lGR -Wl,-rpath,/usr/local/gr/lib - probably a candidate for an alias or script
This works perfectly. Thank You.