On Thursday 05 March 2015 12:39:14 Antonio Larrosa wrote:
> Hello,
> I have a problem compiling an application (kde4-kupdateapplet) to which
> I'm adding some code that uses libzypp. When compiling, I'm getting this
> error: http://paste.opensuse.org/36038415
> It seems to be related to the for_ definition in libzypp
> 9.37.10- (which is what SLES11-SP3 is using) as:
> #define for_(IT,BEG,END) for ( typeof(BEG) IT = BEG, _for_end = END; IT
> != _for_end; ++IT )

Sorry, my fault.

  If you are writing a header file that must work when included in 
  ISO C programs, write __typeof__ instead of typeof. 

'typeof' is a gcc extension. It's turned off because you're using 'c++ -ansi'.

- Either drop using -ansi
- or change the header to use __typeof__ 
- or maybe
    #define typeof __typeof__
    #include <zypp/ZYppFactory.h>

    Michael Andres

Key fingerprint = 2DFA 5D73 18B1 E7EF A862  27AC 3FB8 9E3A 27C6 B0E4
Michael Andres       SUSE LINUX GmbH, Development,        m...@suse.de
Maxfeldstrasse 5, D-90409 Nuernberg, Germany, ++49 (0)911 - 74 053-0
SUSE Linux GmbH GF: Felix Imend├Ârffer, Jane Smithard, Jennifer Guild
       Dilip Upmanyu, Graham Norton, HRB 21284 (AG N├╝rnberg)
To unsubscribe, e-mail: zypp-devel+unsubscr...@opensuse.org
To contact the owner, e-mail: zypp-devel+ow...@opensuse.org

Reply via email to