octave-maintainers
[Top][All Lists]
Advanced

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

address@hidden: more gcc 4.3 warnings]


From: Rafael Laboissiere
Subject: address@hidden: more gcc 4.3 warnings]
Date: Wed, 4 Apr 2007 09:18:32 +0200
User-agent: Mutt/1.5.13 (2006-08-11)

Hi Andrew,

I am forwarding below a message from John Eaton (the author of Octave) sent
to the Octave maintainers mailing list and regarding the changes needed to
make it compile with gcc 4.3.  It seems that there are some issues with the
glpk headers.  Could you please look at this?

Cheers,

-- 
Rafael
--- Begin Message --- Subject: more gcc 4.3 warnings Date: Tue, 3 Apr 2007 23:24:38 -0400
I made the following changes to avoid warnings like this from gcc 4.3:

  src/DLD-FUNCTIONS/__glpk__.cc:260: warning: deprecated conversion from string 
constant to 'char*'

I'd rather avoid ugliness like this, so would someone like to work on
making the glpk headers and functions const friendly and getting
the necessary changes accepted upstream?

Thanks,

jwe

Index: src/DLD-FUNCTIONS/__glpk__.cc
===================================================================
RCS file: /cvs/octave/src/DLD-FUNCTIONS/__glpk__.cc,v
retrieving revision 1.21
diff -u -u -r1.21 __glpk__.cc
--- src/DLD-FUNCTIONS/__glpk__.cc       29 Mar 2007 12:49:52 -0000      1.21
+++ src/DLD-FUNCTIONS/__glpk__.cc       4 Apr 2007 03:22:08 -0000
@@ -257,7 +257,8 @@
 
   if (save_pb)
     {
-      if (lpx_write_cpxlp (lp, "outpb.lp") != 0)
+      static char tmp[] = "outpb.lp";
+      if (lpx_write_cpxlp (lp, tmp) != 0)
        {
          error ("__glpk__: unable to write problem");
          longjmp (mark, -1);
@@ -308,7 +309,8 @@
 #ifdef GLPK_PRE_4_14
       insist (method != method);
 #else
-      glpk_fault_hook (0, "method != method");
+      static char tmp[] = "method != method";
+      glpk_fault_hook (0, tmp);
 #endif
     }
 

--- End Message ---

reply via email to

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