000
19.04.2005, 12:39 Uhr
RedEagle
|
Hi ich möchte eine *.dll erstellen, aber mein Compiler (DEV-CPP) macht Probleme:
dll.h
C++: |
#ifndef _main_dll #define _main_dll
#if BUILDING_DLL # define DLLIMPORT __declspec (dllexport) #else /* Not BUILDING_DLL */ # define DLLIMPORT __declspec (dllimport) #endif /* Not BUILDING_DLL */
#include <windows.h> #include <stdio.h>
// Sonderzeichen const unsigned char ae = (char)132; //ä const unsigned char oe = (char)148; //ö const unsigned char ue = (char)129; //ü const unsigned char AE = (char)142; //Ä const unsigned char OE = (char)153; //Ö const unsigned char UE = (char)154; //Ü const unsigned char ss = (char)225; //ß
//ein paar defines...
//viele andere Funktionen... void DLLIMPORT coutput(char value, int x, int y); //noch eine Funktion...
#endif /* _main_dll */
|
dll.cpp
C++: |
#include "dll.h" #include <windows.h>
#define DLL_EXPORT
//... viele Funktionen
void APIENTRY RST_coutput(char value, int x, int y) { DWORD dwNumberOfCharsWritten = 1;
RST_gotoxy(x,y); WriteConsole(GetStdHandle(STD_OUTPUT_HANDLE), &value, 1, &dwNumberOfCharsWritten, NULL); } //######### HIER KOMMT EIN FEHLER ############
//noch ne Funktion
//------------------------------------------------------------------------------
BOOL APIENTRY DllMain (HINSTANCE hInst /* Library instance handle. */ , DWORD reason /* Reason this function is being called. */ , LPVOID reserved /* Not used. */ ) { switch (reason) { case DLL_PROCESS_ATTACH: break;
case DLL_PROCESS_DETACH: break;
case DLL_THREAD_ATTACH: break;
case DLL_THREAD_DETACH: break; }
/* Returns TRUE on success, FALSE on failure */ return TRUE; }
|
Fehler: |
Internal compiler error in rest_of_compilation, at toplev.c:
|
Was ist Falsch??
ps.: Original-code -- MFG RedEagle |