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

Re: [wmx] Compile Errors in WMX-6 with gcc 3.2 and intel C++

Teemu Voipio - Mon Sep 23 21:13:14 2002

On Mon, Sep 23, 2002 at 02:16:40PM -0400, Andrew Fant wrote:
> Date: Mon, 23 Sep 2002 14:16:40 -0400 (EDT)
> From: Andrew Fant <andrew.fant@tufts.edu>
> Subject: [wmx] Compile Errors in WMX-6 with gcc 3.2 and intel C++
> To: wmx@42.org
> 
> 
> When I try to compile wmx-6 ( or patch level 1) under g++ version 3.2 I
> get the following error:

What is this "patch level 1", as I never heard of it ?
I have my self patched with a gnomepatch that I ported from earlier
release and a "move window from any part by pressing meta" patch but
compiles clean with these and from fresh release 6..

> c++ -c -g -O2 -I/usr/X11R6/include Menu.C
> Menu.C:625: default argument given for parameter 3 of `
>    CommandMenu::CommandMenu(WindowManager*, XEvent*, char* = 0)'
> Menu.h:92: after previous specification in `
>    CommandMenu::CommandMenu(WindowManager*, XEvent*, char* = 0)'
> make: *** [Menu.o] Error 1
> 
> under intel C++, I get the following variant:
> 
> icc -c -g -O2 -I/usr/X11R6/include Menu.C
> Menu.C
> Menu.C(623): error: redefinition of default argument
>   CommandMenu::CommandMenu(WindowManager *manager, XEvent *e,
>   ^
> 
> compilation aborted for Menu.C (code 2)
> make: *** [Menu.o] Error 2
> 
> Has anyone else seen this error before, and if so, does anyone else have
> any suggestions about how to deal with it?
> 
> Thanks,
>         Andy

Nope, works on gcc2.95.3, GNU/Linux, glibc2.2, i686 =)

But I remember seeing something similar with some other project some
day, can't recall what it was.. try adding a "#define NULL 0" in Config.h
or some other place, and if such a define exist, try removing it..

It might be that having a pointer argument default to 0 causes
problems.. workaround would be to define another "wrapper" function
(like one would do in java I think)..

If you can give any details on your system it would help a lot..

-- 
 - Teemu Voipio <mystran@joutomaa.net>
-----------------------------------------------------------------
    Mystran  ==  my very own nick @ IRC  ==  god's gift to net
  does  not                              ==
  use           that                     ==
  MS  software   software    and    has  ==  a verb
  at     home   has    to   only  Linux  ==  Linux from Scratch
  since   he    be    free   at    home  ==  wasteland.pp.htv.fi
   believes     for    all   therefore.        (is encrypted)
-----------------------------------------##----------------------


Next: