Author Topic: Code::Blocks + Linux = trouble  (Read 5873 times)

Offline sasq

  • Multiple posting newcomer
  • *
  • Posts: 13
Code::Blocks + Linux = trouble
« on: November 22, 2005, 05:13:39 pm »
Hello.
I have compiled wxGTK-2.4.2.tgz
Everything goes fine.
Next, i have downloaded release from CVS [sources from download page didn't run, I've got errors in ./bootstrap].
Bootstrap for CVS version goes OK, so as ./configure.
But after calling "make" i have the following error:

Code
In file included from bindings/sc_wxarraystring.cpp:4:
bindings/sc_wxarraystring.h:20:23: wx/arrstr.h: No such file or directory
bindings/sc_wxarraystring.cpp: In function `wxString& StringAt(unsigned int,
   scWxArrayString&)':
bindings/sc_wxarraystring.cpp:48: error: `size' undeclared (first use this
   function)
bindings/sc_wxarraystring.cpp:48: error: (Each undeclared identifier is
   reported only once for each function it appears in.)

What's wrong and how to fix it?
I am phuckin' with this since two days and still don't have C::B running on my Aurox 9.1 box ;(

Offline rickg22

  • Lives here!
  • ****
  • Posts: 2283
Re: Code::Blocks + Linux = trouble
« Reply #1 on: November 22, 2005, 05:30:08 pm »
OK Um, first of all, the CVS version of codeblocks requires wxWidgets 2.6.1. Second, i think some of the files are in DOS format, you need to run dos2unix on them. There was some info on the forums, but I don't remember where... sorry
« Last Edit: November 22, 2005, 05:32:00 pm by rickg22 »

Offline Michael

  • Lives here!
  • ****
  • Posts: 1608
Re: Code::Blocks + Linux = trouble
« Reply #2 on: November 22, 2005, 05:46:41 pm »
Second, i think some of the files are in DOS format, you need to run dos2unix on them. There was some info on the forums, but I don't remember where... sorry

May be here?

http://forums.codeblocks.org/index.php/topic,733.0.html

If not a fast search in the forum can be helpful.

Best wishes,
Michael

Offline sasq

  • Multiple posting newcomer
  • *
  • Posts: 13
Re: Code::Blocks + Linux = trouble
« Reply #3 on: November 22, 2005, 06:35:18 pm »
Quote from: rickg22
OK Um, first of all, the CVS version of codeblocks requires wxWidgets 2.6.1.

NOW you tell me? :|
OK, i have downloaded wxWidgets-2.6.2, compilled and installed OK according to Tutorial on Wiki.
When I "make" the C::B sources next, the compilation goes a while longer, and I get a nice stuff of errors in my face. There is so many errors, so I paste only a few first of that:

Code
bindings/scriptbindings.cpp:15: error: `cbProject' was not declared in this scope
bindings/scriptbindings.cpp:15: error: `p' was not declared in this scope
bindings/scriptbindings.cpp:15: error: variable or field `DummyAddRef' declared void
bindings/scriptbindings.cpp:15: error: syntax error before `{' token
bindings/scriptbindings.cpp:16: error: `cbProject' was not declared in this scope
bindings/scriptbindings.cpp:16: error: `p' was not declared in this scope
bindings/scriptbindings.cpp:16: error: variable or field `DummyRelease' declared void
bindings/scriptbindings.cpp:16: error: syntax error before `{' token
bindings/scriptbindings.cpp: In function `void gDebugLog(const wxString&)':
bindings/scriptbindings.cpp:36: error: `DBGLOG' undeclared (first use this function)
bindings/scriptbindings.cpp:36: error: (Each undeclared identifier is reported only once for each function it appears in.)
bindings/scriptbindings.cpp: In function `wxString gReplaceMacros(const wxString&, bool)':
bindings/scriptbindings.cpp:39: error: `Manager' undeclared (first use this function)
bindings/scriptbindings.cpp:39: error: syntax error before `::' token
bindings/scriptbindings.cpp: In function `void Register_ConfigManager(asIScriptEngine*)':
bindings/scriptbindings.cpp:88: error: `wxConfigBase' undeclared (first use this function)
bindings/scriptbindings.cpp:88: error: syntax error before `::' token
bindings/scriptbindings.cpp:88: error: `::Convert' undeclared (first use here)
bindings/scriptbindings.cpp:88: error: syntax error before `::' token
bindings/scriptbindings.cpp:88: error: syntax error before `&' token
bindings/scriptbindings.cpp:89: error: syntax error before `::' token

etc.
Why it's so HARD to compile?? I have tried so many ways and still i got errors.
Why don't you write exactly what libs and stuff are needed, how to compile it troublelessly and have fun?

Quote from: rickg22
Second, i think some of the files are in DOS format, you need to run dos2unix on them. There was some info on the forums, but I don't remember where... sorry

Not in CVS-version AFAIK..

Offline thomas

  • Administrator
  • Lives here!
  • *****
  • Posts: 3979
Re: Code::Blocks + Linux = trouble
« Reply #4 on: November 22, 2005, 06:45:28 pm »
Aurox 9.1 ships with gcc 3.2.2, maybe you want to use a more recent version?
We use 3.4.4 for development, and although it should probably work with 3.2 too, this might be a reason (gcc 3.2 does not support precompiled headers, so it is possible that a few things are undefined because some #includes are missing, and we never notice that because it works.) You might try turning precompiled headers off too (if I knew how you do that...).
"We should forget about small efficiencies, say about 97% of the time: Premature quotation is the root of public humiliation."

Offline rickg22

  • Lives here!
  • ****
  • Posts: 2283
Re: Code::Blocks + Linux = trouble
« Reply #5 on: November 22, 2005, 06:48:11 pm »
Also, please accept our apologies. This week we implemented some major changes in CVS, and a few things broke - including, it seems, some parts of the linux compilation process (it compiles alright under windows, tho).

Um, Yiannis, mind giving us a hand in here? ;-)

Offline Der Meister

  • Regular
  • ***
  • Posts: 307
Re: Code::Blocks + Linux = trouble
« Reply #6 on: November 22, 2005, 06:52:21 pm »
As we discoverd in this thread Code::Blocks still compiles properly (at least the current CVS from last sunday) if a recent compiler (at least gcc 3.4) ist used. (Only one include-path seemed to be missing.)
But compiling without precompiled headers seems to be a bigger issue.
Real Programmers don't comment their code. If it was hard to write, it should be hard to understand.
Real Programmers don't write in BASIC. Actually, no programmers write in BASIC, after the age of 12.

Offline sasq

  • Multiple posting newcomer
  • *
  • Posts: 13
Re: Code::Blocks + Linux = trouble
« Reply #7 on: November 22, 2005, 10:00:47 pm »
:lol: i don't believe THAT was the cause! :P
I have compiled wxGTK version 2.6.2 and used Source-RPM. Now it WORKS! :)
All compiled well, only I have had to "force" the output RPM because its dependencies.
Looks like someone has forgot to change the Tutorial on Wiki - it is still for wxGTK-2.4.2 there, but the new CVS and Source-RPM is based on wxGTK-2.6.2. Thanx good man for 2 days of good fun ;P and thanx you guys for hints ;)