[Solved - False] undefined reference createMemoryReadFile()
[Solved - False] undefined reference createMemoryReadFile()
I get undefined reference to createMemoryReadFile in dynamic linking version.
Static build works fine.
I build the lib with: mingw32-make NDEBUG=1 sharedlib_win32 -j4
(I'm using msys2 with gcc 7.2.0, windows 10 x64)
But it seems working with debug version of dynamic lib because I've just discovered NDEBUG=1 and before there was no issues.
Static build works fine.
I build the lib with: mingw32-make NDEBUG=1 sharedlib_win32 -j4
(I'm using msys2 with gcc 7.2.0, windows 10 x64)
But it seems working with debug version of dynamic lib because I've just discovered NDEBUG=1 and before there was no issues.
Last edited by mant on Fri Dec 15, 2017 5:18 am, edited 1 time in total.
Re-creating Irrlicht with Vulkan: http://irrlicht.sourceforge.net/forum/v ... =6&t=52404
Re: Dynamic linking version doesn't have createMemoryReadFil
Check if you get following warning when compiling Irrlicht:
"Compiling with __STRICT_ANSI__ not supported. g++ does set this when compiling with -std=c++11 or -std=c++0x. Use instead -std=gnu++11 or -std=gnu++0x. Or use -U__STRICT_ANSI__ to disable strict ansi."
"Compiling with __STRICT_ANSI__ not supported. g++ does set this when compiling with -std=c++11 or -std=c++0x. Use instead -std=gnu++11 or -std=gnu++0x. Or use -U__STRICT_ANSI__ to disable strict ansi."
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Re: Dynamic linking version doesn't have createMemoryReadFil
I tried adding -std=gnu++11 to CXXFLAGS in Makefile and the linking error is still the same.
I'm gonna try building with Code::Blocks.
Update: same error with config Release fast math dll
C::B project already defined -U__STRICT_ANSI__
I'm gonna try building with Code::Blocks.
Update: same error with config Release fast math dll
C::B project already defined -U__STRICT_ANSI__
Re-creating Irrlicht with Vulkan: http://irrlicht.sourceforge.net/forum/v ... =6&t=52404
Re: Dynamic linking version doesn't have createMemoryReadFil
Guess I have to experiment a little if I can reproduce. I don't have gcc 7 yet on Windows, maybe something changed. Which Irrlicht version are you using?
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Re: Dynamic linking version doesn't have createMemoryReadFil
I'm using 1.8.4, you can try MSYS2 to use the same environment like I have.
Re-creating Irrlicht with Vulkan: http://irrlicht.sourceforge.net/forum/v ... =6&t=52404
Re: Dynamic linking version doesn't have createMemoryReadFil
I'm not sure why you mention C::B - you do build from console, right?
I spend some time building it on my existing system.
So some stuff which might be trouble...
- You should also have "make" usually which tends to works slightly better I think. At least if you have installed msys (mingw alone does only have the mingw32-make I think).
- To ensure you don't have old builds and/or mixed versions first call: make clean
- Check if you get any other build errors. For example in my case MinGW did set CC to cc. Which does not exist. So I had to build with: make CC=gcc NDEBUG=1 sharedlib_win32
- The build-file for all Makefiles doesn't seem to support win32 builds (or I couldn't figure it out). It seems you have to build examples one-by-one
- The example build is like: make NDEBUG=1 all_win32
I spend some time building it on my existing system.
So some stuff which might be trouble...
- You should also have "make" usually which tends to works slightly better I think. At least if you have installed msys (mingw alone does only have the mingw32-make I think).
- To ensure you don't have old builds and/or mixed versions first call: make clean
- Check if you get any other build errors. For example in my case MinGW did set CC to cc. Which does not exist. So I had to build with: make CC=gcc NDEBUG=1 sharedlib_win32
- The build-file for all Makefiles doesn't seem to support win32 builds (or I couldn't figure it out). It seems you have to build examples one-by-one
- The example build is like: make NDEBUG=1 all_win32
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Re: Dynamic linking version doesn't have createMemoryReadFil
I did make clean before building the lib, and I've tried many times rebuild Irrlicht DLL from scratch (delete the whole folder and extract again)
Something I didn't make clear is that building the lib itself doesn't introduce any errors.
The error occurs when building my app. I use createMemoryReadFile.
I mention C::B because I tried that too (delete folder, extract, open with C::B and build)
Is there any possibility that some developer make createMemoryReadFile not public when exporting DLL symbols to prevent usage?
Something I didn't make clear is that building the lib itself doesn't introduce any errors.
The error occurs when building my app. I use createMemoryReadFile.
I mention C::B because I tried that too (delete folder, extract, open with C::B and build)
Is there any possibility that some developer make createMemoryReadFile not public when exporting DLL symbols to prevent usage?
Re-creating Irrlicht with Vulkan: http://irrlicht.sourceforge.net/forum/v ... =6&t=52404
Re: Dynamic linking version doesn't have createMemoryReadFil
Please call "make NDEBUG=1 all_win32" inside examples/21.Quake3Explorer just to ensure it fails there as well. That example uses createMemoryReadFile (and does link here).
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Re: Dynamic linking version doesn't have createMemoryReadFil
The makefile of example 21 doesn't define NDEBUG, there is no effects for that.
And currently there is: CXXFLAGS = -g -Wall
So I removed -g and run. It runs fine. But my project still gets error.
Maybe it's because of CEGUI, both dynamic and static CEGUI libs link to the same static Irrlicht library.
So I'm gonna make CEGUI libs compile with dynamic lib and see.
Linking order may also cause this.
Thanks CuteAlien.
And currently there is: CXXFLAGS = -g -Wall
So I removed -g and run. It runs fine. But my project still gets error.
Maybe it's because of CEGUI, both dynamic and static CEGUI libs link to the same static Irrlicht library.
So I'm gonna make CEGUI libs compile with dynamic lib and see.
Linking order may also cause this.
Thanks CuteAlien.
Re-creating Irrlicht with Vulkan: http://irrlicht.sourceforge.net/forum/v ... =6&t=52404
Re: [Solved - False] undefined reference createMemoryReadFil
Solved, I link both dynamic and static lib because the linker is complaining about the function without "imp" in its name.
I notice that "imp" should present if we're compiling with dynamic Irrlicht.
Luckily, linker only links what it needs from the static lib so that's fine.
I notice that "imp" should present if we're compiling with dynamic Irrlicht.
Luckily, linker only links what it needs from the static lib so that's fine.
Re-creating Irrlicht with Vulkan: http://irrlicht.sourceforge.net/forum/v ... =6&t=52404
Re: [Solved - False] undefined reference createMemoryReadFil
Hm, interesting that Makefiles in examples miss NDEBUG. Really have to go over all make systems some day (there's a bunch of other problems as well).
But good it works for now :-)
But good it works for now :-)
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm