Compilation error with gtk2

56 views
Skip to first unread message

Oleksiy Bondarenko

unread,
May 23, 2018, 11:10:03 AM5/23/18
to tumbi
Dear All,

I try to compile nsp-1.3 with gtk2, but make command finishes with the following error:


making all in src/graphics-new
make[2]: Entering directory `/home/Alex/Documents/nsp-1.3/src/graphics-new'
compiling Graphics-IN.c  Wall
compiling periCairoNew.c  Wall
In file included from periGtkstd.c:37,
                 from periCairoNew.c:28:
../../src/include/nsp/graphics-new/periGtk.h:215: error: expected specifier-qualifier-list before ‘cairo_rectangle_int_t’
make[2]: *** [periCairoNew.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[2]: Leaving directory `/home/Alex/Documents/nsp-1.3/src/graphics-new'
make all in sub directory graphics-new failed
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/Alex/Documents/nsp-1.3/src'
make scilex-lib in sub directory src failed
make: *** [scilex-lib] Error 2


my configuration: Scientific Linux 6.9 x86_64


The configure report is as follows:


*******************
*     Summary     *
*******************

FFTW3 support..........: yes
OpenGl support.........: no
Sndfile support........: no
Portaudio support......: no
Mongodb support........: no
Graphviz support.......: no
Asound support.........: yes
Glpk support...........: no
Clp support............: no
Cholmod support........: no
Umfpack support........: no
GtkSourceView support..: no
gobject-introspection..: no
epoxy support..........: no
qhull support..........: no
man vizualization......: webkit-gtk

Managed by pkg-config..: gtk+-2.0 webkit-1.0 gthread-2.0 fftw3 alsa
Lapack and Blas........: -llapack -lblas
gmp....................: -lgmp
zlib...................: -lz
Terminal...............: -lreadline -lncurses
default graphic driver.: gtk/cairo
cairo output files.....: pdf ps svg

man browser............:  webkit

C compiler.............: gcc
C options..............: -g -O2 -Wall -Wno-deprecated-declarations
C ldflags..............: -lieee -ldl -rdynamic -Wl,-relax
Fortran compiler.......: g77
Fortran options........: -g -O2 -Wall
Fortran ldflags........: -lieee -ldl -rdynamic -Wl,-relax

ocamlc compiler........: ocamlc
ocamlopt compiler......: ocamlopt

nsp toolboxes..........: compilers scicos-4.4 codegen-peval modnum_nsp coselica-0.4.8-nsp distmesh

jpc

unread,
May 23, 2018, 11:18:22 AM5/23/18
to tumbi
Hi Oleksiy,

It works for me with ubuntu.

1/Can you check if you have cairo in the printed list that you obtain with

pkg-config gtk+-2.0 --cflags

2/ Can you check if cairo_rectangle_int_t is defined in /usr/include/cairo/cairo.h

3/ On ubuntu it's provided by the libcairo2-dev package
 apt-file search  /usr/include/cairo/cairo.h
libcairo2-dev: /usr/include/cairo/cairo.h

I do not check for libcairo in the configure maybe it's a mistake and I should add this search.

By the way the preferred way to compile nsp is now with gtk+-3.0

Regards
jpc
Reply all
Reply to author
Forward
0 new messages