Author Topic: Why I should "Reactivate Compiler Plugin", and how to re-active compiler plugin?  (Read 6208 times)

Offline opalm

  • Single posting newcomer
  • *
  • Posts: 2
there is a similar topic years ago, the problem I met is slightly different, please help me.

by using the cb IDE(I mean in GUI mode, select to build with menu), I do compile well, however, when I try to use command line for batch build,
it will prompt "Deactivating the compiler plugin is most unwise, if you intent to open a project, you have to re-acvtive the compiler plugin firtly.".

I do confirmed the plugin managment, all the plugins are installed and enabled.

Moreover, I found when start the cb with command line, it will prompt :
---
> codeblocks
Initialize EditColourSet .....
....
Compiler: loaded
....
Added compiler "GNU GCC Compiler for myproject"
Compiler plugin activated
....
Initializing plugins...
---

it seams that before I can use cb it will do something to load/active/initializing the plugins,
and it seams I must do the same procedure before I use cb with other options in command line,
such as build...

but this seams unreasonable, and there should be some solution, anyone can help me? thank you.


BTW, the cb version I used is 8.02.



Offline stahta01

  • Lives here!
  • ****
  • Posts: 7588
    • My Best Post
Could be bug; I would check configuration first.

Under "Settings" -> "Compiler and Debugger"
In left column select "Batch Build"
Make sure "Compiler" is checked.

Also, check you have the correct default compiler set and it is configured correctly.

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 opalm

  • Single posting newcomer
  • *
  • Posts: 2
hi Tim

thank you very much for your help.

it works.

but as to my case, there is one more step when trying to check "Compiler" plugin in the Btach build settings.

when I try to check the "Compiler", it will not be saved, then I found in the configuration file,
it seams the below line a windows style configuration,
-----------
                                        <![CDATA[compiler.dll]]>
-----------

then I try to modify it as below manually, it works well. hope this help for the same situation as me.
------------
        <plugins>
                <TRY_TO_ACTIVATE>
                        <str>
                                <![CDATA[]]>
                        </str>
                </TRY_TO_ACTIVATE>
                <BATCH_BUILD_PLUGINS>
                        <astr>
                                <s>
                                        <![CDATA[libcompiler.so]]>
                                </s>
                        </astr>
                </BATCH_BUILD_PLUGINS>
                <INSTALL_GLOBALLY bool="1" />
                <INSTALL_CONFIRMATION bool="1" />
        </plugins>
------------

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7255
hi Tim

thank you very much for your help.

it works.

but as to my case, there is one more step when trying to check "Compiler" plugin in the Btach build settings.

when I try to check the "Compiler", it will not be saved, then I found in the configuration file,


If this is really the case you found a bug.
Never touch your conf-files manually (unless you know exactly what you do) or you might lose your C::B configuration.

Are you aware, that C::B only writes the configuration to disk if you close it ?
If an error occurs on closing, the changes might not be saved.

If you change other settings and close C::B, are they saved ?

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7255
You did not write which OS you use, but I guess you are using linux, because your compiler library has an .so-ending.

On linux there is indeed a bug that prevents the settings from being saved, but it also prevents an un checked compiler-plugin from being saved, so the settings can normally not get lost unless you chaneg it manually.

I fixed it in svn r6202, so it will not appear in next release (and/or nightly).

Jayno

  • Guest