Full_Name: Martin Gansser Version: 1.5.1 OS: hp-ux 11.00 Submission from: (NULL) (195.145.22.147) cc -Wp,-H16000 -I. -I../../../src/include -I../../../src/include -I/opt/gnome/include/gnome-1.0 -DNE ED_GNOMESUPPORT_H -I/opt/gnome/lib/gnome-libs/include -I/opt/gnome/include/glib-1.2 -I/opt/gnome/lib /glib/include -I/opt/gnome/include/orbit-1.0 -I/opt/gnome/include/gtk-1.2 -I/opt/gnome/include/gnome -xml -I/opt/gnome/include -I/opt/gnome/include/gnome-1.0 -DNEED_GNOMESUPPORT_H -I/opt/gnome/lib/gnom e-libs/include -I/opt/gnome/include/glib-1.2 -I/opt/gnome/lib/glib/include -I/opt/gnome/include/orbi t-1.0 -I/opt/gnome/include/gtk-1.2 -I/usr/local/include -I/opt/gnome/include -DHAVE_CONFIG_H +Z - Wp,-H16000 -c system-showfiles.c -o system-showfiles.lo cpp: "/opt/gnome/include/gnome-1.0/libgnome/gnome-i18n.h", line 10: warning 2013: Unknown preprocess ing directive. cc: "system-showfiles.c", line 271: error 1502: Array size must be a constant expression. gmake[4]: *** [system-showfiles.lo] Error 1 gnome-1.4 for hpux 11.00 PS: R-1.5.1 compiles fine w/o gnome support -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-devel-request@stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
compilation breaks with gnome support on hp-ux 11.00 (PR#1757)
3 messages · mgansser@rand.de, Peter Dalgaard, Thomas Lumley
mgansser@rand.de writes:
cc: "system-showfiles.c", line 271: error 1502: Array size must be a constant expression. gmake[4]: *** [system-showfiles.lo] Error 1 gnome-1.4 for hpux 11.00 PS: R-1.5.1 compiles fine w/o gnome support
Hmm: const gint bufsize = 2048; gchar buf[bufsize]; is the culprit, so a quick fix should be obvious (just use #define instead). But is this usage of "const" variables an un-ANSI C extension in GCC, or is it the HP C compiler that is to blame??
O__ ---- Peter Dalgaard Blegdamsvej 3 c/ /'_ --- Dept. of Biostatistics 2200 Cph. N (*) \(*) -- University of Copenhagen Denmark Ph: (+45) 35327918 ~~~~~~~~~~ - (p.dalgaard@biostat.ku.dk) FAX: (+45) 35327907 -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-devel-request@stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
On 8 Jul 2002, Peter Dalgaard BSA wrote:
mgansser@rand.de writes:
cc: "system-showfiles.c", line 271: error 1502: Array size must be a constant expression. gmake[4]: *** [system-showfiles.lo] Error 1 gnome-1.4 for hpux 11.00 PS: R-1.5.1 compiles fine w/o gnome support
Hmm: const gint bufsize = 2048; gchar buf[bufsize]; is the culprit, so a quick fix should be obvious (just use #define instead). But is this usage of "const" variables an un-ANSI C extension in GCC, or is it the HP C compiler that is to blame??
It's not in ANSI C89, though it is in C99. The initialiser must be a constant expression and in C (but not C++) a const-qualified variable doesn't qualify. The reason I've seen for this is that the value of a const-qualfied variable is known at link time but not necessarily at compile time. -thomas -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.- r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html Send "info", "help", or "[un]subscribe" (in the "body", not the subject !) To: r-devel-request@stat.math.ethz.ch _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._