Vielleicht könnt ihr mir ja helfen?!



  • Hab mal wieder n schönen fehler beim compilieren bekommen. Kann mir aber schlecht vorstellen warum. hab an dieser genannten reent.h nix verändert. Und der code ist auch aus einem beispiel übernommen.

    //this is needed by KOS
    #define _arch_dreamcast
    
    /* Appwizard blank main template For Dreamcast Programming
       Assumes you are using KOS 1.1.9
    */
    
    #include <kos.h> 
    #include <string.h>	 
    #include <stdio.h>
    #include <stdlib.h>
    #include <math.h>
    #include <string.h>
    #include <SDL/SDL.h>
    #include <SDL/SDL_image.h>
    #include <SDL/SDL_mixer.h>   
    
    //Initiate KOS with These Flags
    KOS_INIT_FLAGS(INIT_DEFAULT | INIT_MALLOCSTATS);
    
    //Setup Romdisk and Enable romdisk usage
    //Remove comments below to Include romdisk
    //Create a directory in the same working project directory called "romdisk"
    //extern uint8 romdisk[];
    //KOS_INIT_ROMDISK(romdisk);
    
    int main(int argc, char **argv) 
    {  
      int audio_rate = 22050;
      Uint16 audio_format = AUDIO_S8; 
      int audio_channels = 1;
      int audio_buffers = 1024;
    
      Mix_Music * song1; 
    
      SDL_Init(SDL_INIT_AUDIO);
    
      /* Open mixer: */ 
      (Mix_OpenAudio(audio_rate, audio_format, audio_channels, audio_buffers));
    
       /* Load a song: */ 
      song1 = Mix_LoadMUS("/cd/test.ogg");
      Mix_PlayMusic(song1, -1);
    
    	return 0;
    }
    

    --------------------Configuration: OGGPlay - Win32 Debug--------------------
    Microsoft (R) Program Maintenance Utility Version 6.00.8168.0
    Copyright (C) Microsoft Corp 1988-1998. All rights reserved.
    D:\DevKitDC\bin\g++ -o OGGPlay.elf romdisk.o startup.o OGGPlay.cpp -I D:\DevKitDC\include -I D:\DevKitDC\kernel\arch\dreamcast\include -ml -m4-single-only -O2 -fno-builtin -fno-strict-aliasing -fomit-frame-pointer -fno-optimize-sibling-calls -nos
    tartfiles -nostdlib -Wl -Ttext=0x8c010000 -L D:\DevKitDC\lib -L D:\DevKitDC\sh-sega-dreamcast\lib -lkallisti -lSDL -lSDL_image -lpng -lz -ljpeg -lSDL -lSDL_ttf -lfreetype -lSDL_mixer -lSDL -loggvorbisplay -ltremor -lm -lk++ -Ttext=0x8c010000
    In file included from D:/DevKitDC/include/newlib-libm-sh4/math.h:9,
    from D:/DevKitDC/include/math.h:17,
    from OGGPlay.cpp:12:
    D:/DevKitDC/include/newlib-libm-sh4/sys/reent.h:183: field `_localtime_buf' has
    incomplete type
    NMAKE : fatal error U1077: 'D:\DevKitDC\bin\g++' : return code '0x1'
    Stop.
    Error executing NMAKE.

    OGGPlay.exe - 1 error(s), 0 warning(s)

    Hier der Teil aus reent.h der nicht richtig sein soll.

    {
              unsigned int _rand_next;
              char * _strtok_last;
              char _asctime_buf[26];
              struct tm _localtime_buf;
              int _gamma_signgam;
            } _reent;
    

    Wenn jemand die ganze datei braucht kann ich sie ihm gerne schicken



  • Du musst den Header time.h einbinden.



  • Hat nicht gebracht, es gibt immernoch den gleichen fehler


Anmelden zum Antworten