Closed paroj closed 8 years ago
Original comment by christofer (Bitbucket: christofer, GitHub: christofer):
Well, thanks anyway. I'll try format device and build then...
Original comment by Jason McKesson (Bitbucket: alfonse, GitHub: alfonse):
Unfortunately, no.
I've built and run the executable in debug through Code::Blocks on Windows before. It seems to work fine for me. There is nothing on line 77 that would appear suspect. And I have no idea where it's getting wxString from, since neither my code nor any code it depends on uses wxWidgets.
The crash appears to be happening before main, in the allocation of one of the std::string objects. I cannot imagine why this would happen.
There's just nothing I can really do about it at this point without being physically on your machine.
Original comment by christofer (Bitbucket: christofer, GitHub: christofer):
It is something like: Program Tut 01 MainD.exe stopped working. System Windows is searching solution to the problem.
Info of debugger is:
#!
Building to ensure sources are up-to-date
Build succeeded
Selecting target:
Debug
Adding source dir: E:\Krzysiek\OGL\Tutorial 0.3.8\Tut 01 Hello Triangle\
Adding source dir: E:\Krzysiek\OGL\Tutorial 0.3.8\Tut 01 Hello Triangle\
Adding file: Tut 01 MainD.exe
Starting debugger:
done
Registered new type: wxString
Registered new type: STL String
Registered new type: STL Vector
Setting breakpoints
Debugger name and version: GNU gdb (GDB) 7.5
Child process PID: 3308
Program received signal SIGSEGV, Segmentation fault.
In libstdc++-6!_ZNSsC1EPKcRKSaIcE () (C:\Windows\system32\libstdc++-6.dll)
At E:\Krzysiek\OGL\Tutorial 0.3.8\Tut 01 Hello Triangle\tut1.cpp:77
This is call stack
Original comment by Jason McKesson (Bitbucket: alfonse, GitHub: alfonse):
Can you translate what that error message is? When you debug the program, where does it stop?
Also, none of those are compiler errors. Even though it does say "4 errors", it's wrong. Redefinition is a warning; Code::Blocks simply erroneously thinks that it's an error.
Original comment by christofer (Bitbucket: christofer, GitHub: christofer):
Well, I changed back code and if I build tut1 without changing freeglut_std.h, build messages are:
#!
..\glsdk\freeglut\include\GL\freeglut_std.h|60|warning: "NOMINMAX" redefined [enabled by default]|
c:\mingw\bin\..\lib\gcc\mingw32\4.7.2\include\c++\mingw32\bits\os_defines.h|46|note: this is the location of the previous definition|
..\glsdk\freeglut\include\GL\freeglut_std.h|60|warning: "NOMINMAX" redefined [enabled by default]|
c:\mingw\bin\..\lib\gcc\mingw32\4.7.2\include\c++\mingw32\bits\os_defines.h|46|note: this is the location of the previous definition|
..\glsdk\freeglut\include\GL\freeglut_std.h|60|warning: "NOMINMAX" redefined [enabled by default]|
c:\mingw\bin\..\lib\gcc\mingw32\4.7.2\include\c++\mingw32\bits\os_defines.h|46|note: this is the location of the previous definition|
c:\mingw\bin\..\lib\gcc\mingw32\4.7.2\include\c++\backward\backward_warning.h|33|warning: #warning This file includes at least one deprecated or antiquated header which may be removed without further notice at a future date. Please use a non-deprecated interface with equivalent functionality instead. For a listing of replacement headers and interfaces, consult the file backward_warning.h. To disable this warning use -Wno-deprecated. [-Wcpp]|
||=== Tut 01 Main, Debug ===|
..\glsdk\freeglut\include\GL\freeglut_std.h|60|warning: "NOMINMAX" redefined [enabled by default]|
c:\mingw\bin\..\lib\gcc\mingw32\4.7.2\include\c++\mingw32\bits\os_defines.h|46|note: this is the location of the previous definition|
||=== Build finished: 4 errors, 5 warnings ===|
When I change this one, these are:
#!
||=== framework, Debug ===|
c:\mingw\bin\..\lib\gcc\mingw32\4.7.2\include\c++\backward\backward_warning.h|33|warning: #warning This file includes at least one deprecated or antiquated header which may be removed without further notice at a future date. Please use a non-deprecated interface with equivalent functionality instead. For a listing of replacement headers and interfaces, consult the file backward_warning.h. To disable this warning use -Wno-deprecated. [-Wcpp]|
||=== Build finished: 0 errors, 1 warnings ===|
But when I try to run this, there are console's window and message of Win7 that program stopped working:
Original comment by Jason McKesson (Bitbucket: alfonse, GitHub: alfonse):
Deprecated does not mean removed. Those headers and code were fine. They aren't going anywhere until at least C++14, and I guarantee you that the C++ standards committee isn't going to break lots of C++ code by removing them.
In short: ignore the warnings; your "fixes" turned warnings into errors. I can't diagnose build problems if you change my code.
Also, please try to put any future output logs in proper Markdown tags. Specifically the code tags. It makes it much easier to read.
Original comment by christofer (Bitbucket: christofer, GitHub: christofer):
I've rebuilt glsdk, and build messages in Test are now:
||=== framework, Debug ===|
c:\mingw\bin..\lib\gcc\mingw32\4.7.2\include\c++\backward\backward_warning.h|33|warning: #warning This file includes at least one deprecated or antiquated header which may be removed without further notice at a future date. Please use a non-deprecated interface with equivalent functionality instead. For a listing of replacement headers and interfaces, consult the file backward_warning.h. To disable this warning use -Wno-deprecated. [-Wcpp]|
..\glsdk\freeglut\include\GL\freeglut_std.h|60|warning: "NOMINMAX" redefined [enabled by default]|
c:\mingw\bin..\lib\gcc\mingw32\4.7.2\include\c++\mingw32\bits\os_defines.h|46|note: this is the location of the previous definition|
..\glsdk\freeglut\include\GL\freeglut_std.h|60|warning: "NOMINMAX" redefined [enabled by default]|
c:\mingw\bin..\lib\gcc\mingw32\4.7.2\include\c++\mingw32\bits\os_defines.h|46|note: this is the location of the previous definition|
..\glsdk\freeglut\include\GL\freeglut_std.h|60|warning: "NOMINMAX" redefined [enabled by default]|
c:\mingw\bin..\lib\gcc\mingw32\4.7.2\include\c++\mingw32\bits\os_defines.h|46|note: this is the location of the previous definition|
c:\mingw\bin..\lib\gcc\mingw32\4.7.2\include\c++\backward\backward_warning.h|33|warning: #warning This file includes at least one deprecated or antiquated header which may be removed without further notice at a future date. Please use a non-deprecated interface with equivalent functionality instead. For a listing of replacement headers and interfaces, consult the file backward_warning.h. To disable this warning use -Wno-deprecated. [-Wcpp]|
||=== Build finished: 3 errors, 5 warnings ===|
In Tut 01 and propably every other (I checked to Tut 03) these are just: ||=== Tut 01 Main, Debug ===|
..\glsdk\freeglut\include\GL\freeglut_std.h|60|warning: "NOMINMAX" redefined [enabled by default]|
c:\mingw\bin..\lib\gcc\mingw32\4.7.2\include\c++\mingw32\bits\os_defines.h|46|note: this is the location of the previous definition|
||=== Build finished: 1 errors, 1 warnings ===|
Yes, I built debug and release.
EDIT: I have changed in freeglut_std.h
#!c++
# define NOMINMAX
to
#!c++
# ifndef NOMINMAX
# define NOMINMAX
# endif
Then, there was warning
This file includes at least one deprecated or antiquated header which \ may be removed without further notice at a future date. Please use a \ non-deprecated interface with equivalent functionality instead. For a \ listing of replacement headers and interfaces, consult the file \ backward_warning.h. To disable this warning use -Wno-deprecated.
So, I have changed funcitons and headers in Mesh.cpp and Scene.cpp to replacements in backward_warning.h:
/* A list of valid replacements is as follows:
Use: Instead of:
Originally reported by: christofer (Bitbucket: christofer, GitHub: christofer)
I have a problem with building Learning Modern 3D Graphics Programming tutorial. I've build attached glsdk (by premake and "build" in code::blocks), but when I try build any tutorial I have errors:
||=== Tut 01 Main, Debug ===|
ld.exe||cannot find -lglloadD|
ld.exe||cannot find -lglimgD|
||=== Build finished: 2 errors, 0 warnings ===|
PS I created an issue in SDK section, there I described other error - now (after remove and built again) I have only this.