Author Topic: Strange error when debugging  (Read 5475 times)

Offline Krice

  • Almost regular
  • **
  • Posts: 150
Strange error when debugging
« on: September 05, 2017, 08:38:47 am »
When I run the project in debug mode (F8) gdb.exe tells "These is no disk in the drive. Please insert a disk into drive :I". When you press Cancel three times it goes away and the program runs. I don't know if this is compiler or IDE related problem. I is the card reader (one of its "disk drives"), what could gdb want from that? Could this be some kind of virus in gdb?

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: Strange error when debugging
« Reply #1 on: September 05, 2017, 08:44:54 am »
I think it is known bug in gdb on windows... Try to search the internet. I've seen this reported for drive e: it helps.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline Krice

  • Almost regular
  • **
  • Posts: 150
Re: Strange error when debugging
« Reply #2 on: September 05, 2017, 11:10:33 am »
I like how the status is "closed":

https://sourceforge.net/p/mingw/bugs/2108/

It's a bug that could be fixed, but looks like another case of stubborn open source developers refusing to do anything about it.

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7582
    • My Best Post
Re: Strange error when debugging
« Reply #3 on: September 05, 2017, 04:23:12 pm »
I like how the status is "closed":

https://sourceforge.net/p/mingw/bugs/2108/

It's a bug that could be fixed, but looks like another case of stubborn open source developers refusing to do anything about it.

I suggest you read the bug report to the end!!

They fixed the problem in their release; but, they did NOT fix it in other people releases!
Note: You need to report the problem with details to the site the created the GCC release you are using.
NOTE: If the mingw GCC is from the CB site, report the problem to the TDM site.

Tim S.
C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 64 bit.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

Offline Krice

  • Almost regular
  • **
  • Posts: 150
Re: Strange error when debugging
« Reply #4 on: September 06, 2017, 07:52:39 am »
NOTE: If the mingw GCC is from the CB site, report the problem to the TDM site.

What's TDM? Anyway, I doubt it will change anything. They know it exists and wont fix it for whatever reason. That's open source for you. I mean why would your program try to access random disk drives? For what reason it has to do that? The worst thing is that gcc is I guess the only thing left if you rage quit VC like I did. I removed everything Visual Studio related when it stopped working because there was a mystery account someone made outside my own environment. Great way to alienate developers, Microsoft.

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: Strange error when debugging
« Reply #5 on: September 06, 2017, 11:20:59 am »
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline Krice

  • Almost regular
  • **
  • Posts: 150
Re: Strange error when debugging
« Reply #6 on: September 06, 2017, 03:42:12 pm »
It's some kind of gcc for Code::Blocks? Last updated 2015. Anyway, I noticed there are other versions of gcc for Windows so why not try. There is mingw-w64 which has an installer for Windows. Changed the compiler and debugger paths in Code::Blocks and it works. Well, other than a strange warning message the compiler is giving to one of its own include files:

Code
C:/Program Files (x86)/mingw-w64/i686-7.1.0-posix-dwarf-rt_v5-rev2/mingw32/i686-w64-mingw32/include/intrin.h:59:23: note: previous declaration of 'unsigned int __builtin_ia32_crc32qi(unsigned int, unsigned char)'
   extern unsigned int __builtin_ia32_crc32qi (unsigned int, unsigned char);
                       ^~~~~~~~~~~~~~~~~~~~~~
<built-in>: warning: redundant redeclaration of 'unsigned int __builtin_ia32_crc32hi(unsigned int, short unsigned int)' in same scope [-Wredundant-decls]

Maybe you should use warning options in your own builds, gcc dudes.
« Last Edit: September 06, 2017, 03:44:14 pm by Krice »

Offline Krice

  • Almost regular
  • **
  • Posts: 150
Re: Strange error when debugging
« Reply #7 on: September 07, 2017, 08:17:48 am »
Also tried the official mingw package. The debugger has the I: bug, but the compiler doesn't have redundant-decl warning. First I tried to copy-paste the debugger from mingw-w64 to mingw, but it seems the w64 version is very different and it's asking for a python .dll which is missing when you move the .exe. So w64 dudes are using python in programming gcc and gdb. That's wrong in so many ways, but then I realized I can point the compiler to mingw official and debugger to w64 version.

I never realized that Windows version of gcc was in such a low state. These people don't seem to know what they are doing.

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: Strange error when debugging
« Reply #8 on: September 07, 2017, 09:30:41 am »
So w64 dudes are using python in programming gcc and gdb. That's wrong in so many ways...
Ranting without having an idea about things or without doing a quick search to educate yourself; doesn't look good in the others eyes.

https://sourceware.org/gdb/onlinedocs/gdb/Python.html#Python
https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/6/html/Developer_Guide/debuggingprettyprinters.html

I never realized that Windows version of gcc was in such a low state. These people don't seem to know what they are doing.
Ranting here is a waste of time...
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline Krice

  • Almost regular
  • **
  • Posts: 150
Re: Strange error when debugging
« Reply #9 on: September 07, 2017, 07:28:13 pm »
Ranting here is a waste of time...

I'm not so sure about it. After all you do have Code::Blocks version with mingw. It should be important to make sure it stays decent. There has been some reports about random people trying to take over open source projects and ruin them (possibly without bad intentions but just being bad programmers). Didn't Linus Torvalds himself go into rage mode when some people tried to do something shady to linux core? These things happen, because open source is not protected from changes. I think include files in compiler packages should be double checked for any problems whatsoever. Back like ten years ago we still had rock rolid quality in compilers and IDEs. Visual Studio 2010 was the last good version, then it started to go downhill.

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7582
    • My Best Post
Re: Strange error when debugging
« Reply #10 on: September 07, 2017, 10:54:04 pm »
@Krice: Please read and follow the rules for this site!
http://forums.codeblocks.org/index.php/topic,9996.0.html
C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 64 bit.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: Strange error when debugging
« Reply #11 on: September 07, 2017, 11:59:56 pm »
I'm not so sure about it.
I'm 100% sure... Nothing will going to change about bugs in the compiler here! There is no one here that is active developer on these projects as far as I know...
If you want to change something you have to report the problems to people that could or would do something about them...
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline Krice

  • Almost regular
  • **
  • Posts: 150
Re: Strange error when debugging
« Reply #12 on: September 08, 2017, 11:50:43 am »
If you want to change something you have to report the problems to people that could or would do something about them...

Well.. guess I don't have to. The TDM-GCC from 2015 (latest release) is actually newer than one that comes with Code::Blocks. And it has that disk drive bug fixed and also there is no compiler warning bug. Winpthreads license sounds bit shady though, but I think all it requires is license.txt copy shipped with your program. No idea why it's required.

Offline BlueHazzard

  • Developer
  • Lives here!
  • *****
  • Posts: 3353
Re: Strange error when debugging
« Reply #13 on: September 08, 2017, 01:46:45 pm »
Quote
And it has that disk drive bug fixed and also there is no compiler warning bug.
so you where wrong here
Quote
I never realized that Windows version of gcc was in such a low state. These people don't seem to know what they are doing.

inform first before you complain. And always think about https://en.wikipedia.org/wiki/Dunning%E2%80%93Kruger_effect