Hi,

I am trying to build the new lyx version on a Solaris 2.5.1 system with the Sun
Workshop 5.0 compiler. The build crashes with the following error:

make[3]: Entering directory `/scratch/hanke/lyx-1.1.1/src/mathed'
CC -DHAVE_CONFIG_H -I. -I. -I../../src -I../../images -I./../   -I/afs/nada.kth.
se/home/num/hanke/Private/include  -I/usr/local/include/X11    -I/usr/openwin/in
clude  -xO4 -xtarget=native -dalign -c math_inset.C
"/usr/include/stdio.h", line 143: Error: __iob, of type FILE[20], was previously
 declared __FILE[20].
1 Error(s) detected.
make[3]: *** [math_inset.o] Error 1
make[3]: Leaving directory `/scratch/hanke/lyx-1.1.1/src/mathed'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/scratch/hanke/lyx-1.1.1/src'
make[1]: *** [all-recursive-am] Error 1
make[1]: Leaving directory `/scratch/hanke/lyx-1.1.1/src'
make: *** [all-recursive] Error 1

Having a closer look at the include files, I found out that <stdio.h> and
<cstdio> are incompatible!! This seems to be a compiler error. Changing all
occurences of cstdio to stdio.h resolves the problem.

The compilation of math_panel.C crashes with:

"../../images/sqrt.xpm", line 2: Error: Multiple declaration for sqrt.

Since the definition of stdlib.h is in effect, the following errors occur:

"math_panel.C", line 257: Error: Cannot return extern "C" double(*)(double) from
 a function that should return char**.
"math_panel.C", line 282: Error: Formal argument 2 of type char** in call to fl_
set_pixmap_data(flobjs_*, char**) is being passed extern "C" double(*)(double).
3 Error(s) and 200 Warning(s) detected.
make: *** [math_panel.o] Error 3

probably, it is a good idea to avoid the redefinition of a C object? (I am not
sure if it is really a vioaltion of the C++ language standard.)
Unfortunately, I do not have the time to trace down the problem further.

I know that the 1.1.1 version is a major rewrite of the old stable 1.0.4
version. So I cannot resist in expressing one of my greatest wishes: Is there
any chance to code the GREAT thing in conpliance to the official 1998 C++
standard such that one can use other compilers than gcc?

Thank you very much.

Michael
-- 
+---------------------------------------------------------------+
|  Michael Hanke                Royal Institute of Technology   |
|                               NADA                            |
|                               S-10044 Stockholm               |
|                               Sweden                          |
+---------------------------------------------------------------+
|  Visiting address:            Lindstedtsvaegen 3              |
|  Phone:                       + (46) (8) 790 6278             |
|  Fax:                         + (46) (8) 790 0930             |
|  Email:                       [EMAIL PROTECTED]               |
|                               [EMAIL PROTECTED]       |
+---------------------------------------------------------------+

Reply via email to