Author Topic: The 04 May 2007 build will NOT be out.  (Read 7443 times)

Offline killerbot

  • Administrator
  • Lives here!
  • *****
  • Posts: 5177
The 04 May 2007 build will NOT be out.
« on: May 04, 2007, 08:07:26 pm »
it seems once again, it doesn't build on linux.

Code: [Select]
codesnippets.cpp:23:6: error: #error IS_PLUGIN_CODE *not* defined for plugin code
make[5]: *** [codesnippets.lo] Error 1

To all developers, please use include files [next week I will post some information on include files and a guideline on how to use them] correctly or other ifdef stuff. And please please, build with a non pch environment. PCH's are bad, bad, bad, they are a very easy tool to break compilation. They have benefits, but to be honest currently on the CB project they do more damage then good.
To be honest 50% of the commits these days are breaking the linux build.

Offline stahta01

  • Lives here!
  • ****
  • Posts: 6591
    • My Best Post
Re: The 04 May 2007 build will NOT be out.
« Reply #1 on: May 04, 2007, 08:59:07 pm »
it seems once again, it doesn't build on linux.

Code: [Select]
codesnippets.cpp:23:6: error: #error IS_PLUGIN_CODE *not* defined for plugin code
make[5]: *** [codesnippets.lo] Error 1

To all developers, please use include files [next week I will post some information on include files and a guideline on how to use them] correctly or other ifdef stuff. And please please, build with a non pch environment. PCH's are bad, bad, bad, they are a very easy tool to break compilation. They have benefits, but to be honest currently on the CB project they do more damage then good.
To be honest 50% of the commits these days are breaking the linux build.

I assume from this that if I submit my patches needed to compile Code::Blocks under windows without using pch, that they will be used.

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

Offline killerbot

  • Administrator
  • Lives here!
  • *****
  • Posts: 5177
Re: The 04 May 2007 build will NOT be out.
« Reply #2 on: May 04, 2007, 09:03:26 pm »
Cb project itself on windows (cbp files) fall back on GCC with pch. But with makefiles on linux it more often without pch (good ;-)  );
So if it builds on widows by turning off pch one can already be more confident it will also build on linux, though still no full guarantee (wx is sometimes different)

Offline Pecan

  • Plugin developer
  • Lives here!
  • ****
  • Posts: 2162
Re: The 04 May 2007 build will NOT be out.
« Reply #3 on: May 04, 2007, 09:54:00 pm »
The problem with codesnippets on linux is not precompile headers.

Mandrav took out the BUILDING_PLUGIN define in the codesnippets-unix.cbp, so I had to come up with something else. I chose "IS_PLUGIN_CODE".

I have no idea where to put the define for make files.

Does it go in the .am somewhere?

To be honest 50% of the commits these days are breaking the linux build.

Yuup, it's a development environment. And CB is built around .cbp files. Those are working. Where's the make file? I'll try to figure out how to fix it.
« Last Edit: May 04, 2007, 10:42:54 pm by Pecan »

Offline mandrav

  • Project Leader
  • Administrator
  • Lives here!
  • *****
  • Posts: 4291
    • Code::Blocks IDE
Re: The 04 May 2007 build will NOT be out.
« Reply #4 on: May 05, 2007, 12:02:02 am »
Quote
Mandrav took out the BUILDING_PLUGIN define in the codesnippets-unix.cbp, so I had to come up with something else. I chose "IS_PLUGIN_CODE".

I removed it because it disabled the use of pch. But if you need this put it back.
Be patient!
This bug will be fixed soon...

Offline Pecan

  • Plugin developer
  • Lives here!
  • ****
  • Posts: 2162
Re: The 04 May 2007 build will NOT be out.
« Reply #5 on: May 05, 2007, 12:15:10 am »
Quote
Mandrav took out the BUILDING_PLUGIN define in the codesnippets-unix.cbp, so I had to come up with something else. I chose "IS_PLUGIN_CODE".

I removed it because it disabled the use of pch. But if you need this put it back.

I don't need it if I can define my own "IS_PLUGIN_CODE" without screwing up Killerbot's makefile.

How can I define my own compiler flag in the .cbp without disabling the makefile?

Offline pasgui

  • Almost regular
  • **
  • Posts: 165
    • LGP
Re: The 04 May 2007 build will NOT be out.
« Reply #6 on: May 05, 2007, 09:50:08 am »
Quote
Mandrav took out the BUILDING_PLUGIN define in the codesnippets-unix.cbp, so I had to come up with something else. I chose "IS_PLUGIN_CODE".

I removed it because it disabled the use of pch. But if you need this put it back.

I don't need it if I can define my own "IS_PLUGIN_CODE" without screwing up Killerbot's makefile.

How can I define my own compiler flag in the .cbp without disabling the makefile?


To compile rev3934, I made this modification in codeblocks/src/plugins/contrib/codesnippets/Makefile.am file:

Index: Makefile.am
===================================================================
--- Makefile.am   (révision 3934)
+++ Makefile.am   (copie de travail)
@@ -4,7 +4,7 @@
         $(WX_GTK2_CFLAGS) \
       -I$(top_srcdir)/src/include \
       -I$(top_srcdir)/src/include/wxscintilla/include \
-        -I$(top_srcdir)/src/include/wxFlatNotebook/include
+        -I$(top_srcdir)/src/include/wxFlatNotebook/include -DBUILDING_PLUGIN
 
 
 libdir = $(pkgdatadir)/plugins
@@ -16,7 +16,6 @@
 libcodesnippets_la_LIBADD = $(PLUGIN_WX_LIBS) ../../../sdk/libcodeblocks.la
 
 libcodesnippets_la_SOURCES =    codesnippets.cpp \
-         codesnippetsapp.cpp \
          codesnippetstreectrl.cpp \
          codesnippetswindow.cpp \
          edit.cpp \
@@ -36,7 +35,6 @@
          version.cpp
 
 noinst_HEADERS =     codesnippets.h \
-         codesnippetsapp.h \
          codesnippetstreectrl.h \
          codesnippetswindow.h \
          defsext.h \

Offline killerbot

  • Administrator
  • Lives here!
  • *****
  • Posts: 5177
Re: The 04 May 2007 build will NOT be out.
« Reply #7 on: May 05, 2007, 10:14:37 am »
fyi : rev 3934 still hasn't fixed the problem though

Offline Pecan

  • Plugin developer
  • Lives here!
  • ****
  • Posts: 2162
Re: The 04 May 2007 build will NOT be out.
« Reply #8 on: May 05, 2007, 11:13:59 am »
fyi : rev 3934 still hasn't fixed the problem though

Ok, I'll start ripping out the code.
If we can't represent the .cbp in the linux makefile, I don't want to fight it.

Offline killerbot

  • Administrator
  • Lives here!
  • *****
  • Posts: 5177
Re: The 04 May 2007 build will NOT be out.
« Reply #9 on: May 05, 2007, 11:57:55 am »
although I haven't looked at the actual problem, it should be possible to add extra preprocessor directives in a makefile , += to CFLAGS or those darn things

Offline Pecan

  • Plugin developer
  • Lives here!
  • ****
  • Posts: 2162
Re: The 04 May 2007 build will NOT be out.
« Reply #10 on: May 05, 2007, 12:38:35 pm »
although I haven't looked at the actual problem, it should be possible to add extra preprocessor directives in a makefile , += to CFLAGS or those darn things

Yeah, I spent hours on google trying to figure out how.

But for now, I'll just remove the code from linux that causes the problem.

Then, if I ever learn makefile.am preprocessors, I'll think about putting it back. But I doubt it.