hi everyone
is it possible to build a static link library (no dll) to link directly with my app so i don't have to add the dll to the package?
thank you
ferdi
static link lib
How To
1.) Add the following to irrlicht.h
#define IRRLICHT_EXPORTS
2.) Change the project to a static library
3.) Added the appropriate path to "Additional Libraries Directories" in the linker properties of you application and include "irrlicht.h"
That should do it.
#define IRRLICHT_EXPORTS
2.) Change the project to a static library
3.) Added the appropriate path to "Additional Libraries Directories" in the linker properties of you application and include "irrlicht.h"
That should do it.
Lets try this again
OK, Lets try this again.
In the Irrlicht.h (DON'T FORGET their are TWO Irrlich.h file) Replace the similar section with
#if defined(WIN32) && !defined(IRRLICHT_STATIC)
#ifdef IRRLICHT_EXPORTS
#define IRRLICHT_API __declspec(dllexport)
#else
#define IRRLICHT_API __declspec(dllimport)
#endif // IRRLICHT_EXPORT
#else
#define IRRLICHT_API
#endif // WIN32
In the CIrrDeviceWin32.cpp replace the similar section with
#if !defined(IRRLICHT_STATIC)
#ifdef IRRLICHT_EXPORTS
#define IRRLICHT_API __declspec(dllexport)
#else
#define IRRLICHT_API __declspec(dllimport)
#endif
#else
#define IRRLICHT_API
#endif
Then in your project properties->C/C++->PreProcessor definitions put in
IRRLICHT_STATIC
Then do a clean and recompile everything.
In the Irrlicht.h (DON'T FORGET their are TWO Irrlich.h file) Replace the similar section with
#if defined(WIN32) && !defined(IRRLICHT_STATIC)
#ifdef IRRLICHT_EXPORTS
#define IRRLICHT_API __declspec(dllexport)
#else
#define IRRLICHT_API __declspec(dllimport)
#endif // IRRLICHT_EXPORT
#else
#define IRRLICHT_API
#endif // WIN32
In the CIrrDeviceWin32.cpp replace the similar section with
#if !defined(IRRLICHT_STATIC)
#ifdef IRRLICHT_EXPORTS
#define IRRLICHT_API __declspec(dllexport)
#else
#define IRRLICHT_API __declspec(dllimport)
#endif
#else
#define IRRLICHT_API
#endif
Then in your project properties->C/C++->PreProcessor definitions put in
IRRLICHT_STATIC
Then do a clean and recompile everything.