omit pragma interface/implementation by default?

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

omit pragma interface/implementation by default?

John W. Eaton-6
Should we switch to omitting the interface/implementation #pragma by
default?  The recent linking problems that have been reported on HP-UX
systems using gcc 3.2 go away if these pragmas are not used.  Octave
also fails to build on other systems (OS X and Cygiwn, possibly
others) when we use them.

I believe the idea behind using the pragmas was to avoid code
duplication and reduce the size of the binary, but the savings may not
be that much now.  On my i386 Debian system, compiling with -O2 -g, I
get a binary that is about 34MB with the pragmas, and 35MB without
them.

On the HP-UX system, -O2 -g and no pragmas produces a binary of about
99MB, but it strips to around 7MB.

If there are no objections, I'm going to change things so that instead
of using -DNO_PRAGMA_INTERFACE_IMPLEMENTATION to disable the pragmas,
you will have to use -DUSE_PRAGMA_INTERFACE_IMPLEMENTATION to enable
them, and there will be no special configure support for doing this
automatically on any system.

Comments?

Thanks,

jwe