gcc 2.96 build

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

gcc 2.96 build

Paul Kienzle-2
I got a successful build out of RH 7.x gcc 2.96!  

It passes all the usual tests.

I needed three changes:

(1) Placement delete is soon to be resolved.

(2) The compiler was consuming many hundreds of
megabytes of ram to initialize the map in octave_config_info.  
In the current build I just comment it out, but
I have converted it to build the map from an array of
pointers to strings.  I will send a patch to toplev.cc
when I know that it works.

(3) file-io uses std::auto_ptr which isn't available.  The
following batch converts it to use OCTAVE_LOCAL_BUFFER.

- Paul


Paul Kienzle <[hidden email]>
        * file-io.cc: Use one less feature of the compiler.
        OCTAVE_LOCAL_BUFFER is used elsewhere, auto_ptr isn't.


Index: file-io.cc
===================================================================
RCS file: /cvs/octave/src/file-io.cc,v
retrieving revision 1.137
diff -c -p -r1.137 file-io.cc
*** file-io.cc 2003/02/20 04:49:55 1.137
--- file-io.cc 2003/02/21 20:50:50
*************** error message.\n\
*** 1613,1620 ****
 
        if (! error_state)
  {
!  std::auto_ptr<char> tmp_auto_ptr (strsave (tmpl8.c_str ()));
!  char *tmp = tmp_auto_ptr.get ();
 
   int fd = mkstemp (tmp);
 
--- 1613,1620 ----
 
        if (! error_state)
  {
!  OCTAVE_LOCAL_BUFFER(char, tmp, tmpl8.size()+1);
!  strcpy(tmp, tmpl8.c_str());
 
   int fd = mkstemp (tmp);
 


Reply | Threaded
Open this post in threaded view
|

gcc 2.96 build

John W. Eaton-6
On 21-Feb-2003, Paul Kienzle <[hidden email]> wrote:

| (2) The compiler was consuming many hundreds of
| megabytes of ram to initialize the map in octave_config_info.  
| In the current build I just comment it out, but
| I have converted it to build the map from an array of
| pointers to strings.  I will send a patch to toplev.cc
| when I know that it works.

I think at least one of the elements is not a string, so it will
need to be handled separately.  But I think that's OK.

| (3) file-io uses std::auto_ptr which isn't available.  The
| following batch converts it to use OCTAVE_LOCAL_BUFFER.
|
| Paul Kienzle <[hidden email]>
| * file-io.cc: Use one less feature of the compiler.
| OCTAVE_LOCAL_BUFFER is used elsewhere, auto_ptr isn't.

I applied this patch.

Thanks,

jwe