News:

The new Release 25.03 is out! You can download binaries for Windows and many major Linux distros here .

Main Menu

The 07 July 2012 build (8086) is out.

Started by killerbot, July 07, 2012, 05:24:13 PM

Previous topic - Next topic

Jenna

Nighly packages for RedHat/CentOS 5 and 6 are now available from my rpm-repo .
You need additional packages from other repos, see my site for details.

stahta01

#16
Quote from: cacb on July 08, 2012, 11:28:32 AM
@Tim S.

On this particular machine (XP SP3) I have installed MS Visual Studio Express 2010 (=msvc10) and MS Visual Studio Express 2008 (=msvc8), i.e. the free versions only.

Since I have been using different machines with different compilers installed (at work, the full non-free versions of VS2010 and VS2008) and since at one stage I was using VS2010 on one machine and VS2008 on another at the same time, I have made a "generic MS compiler" in C::B called "msvc" which is  just a clone of the currently preferred MS compiler, and "msvc" is then always the default C::B compiler when running under Windows. My C::B projects refer to the msvc compiler, so they will work with whatever is installed.

I hope I am not confusing the issue, I am just trying to give you the full picture.

Edit: msvc maps to MS Visual Studio Express 2010 in this case

After, I added the linker path "C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\Lib" I saw no problem using "Microsoft Visual Studio 10.0" as the Compiler on Windows 7 machine at work.

Tested Nightly Build (8086).

It has no MinGW GCC installed on it(That I know of; will search the Hard drive for one).
(Found an gcc for embedded MCU; likely has cygwin on it somewhere also.)

It was a fresh Code::Blocks install on a Machine with a fresh re-image of the windows 7 installation.
Note: This is not a windows 7 only install; has many other apps needed on the College Campus where I work.
I set the detected MSVC as the default; other that adding the linker path the hello world C++ command line app worked OK.

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

cacb

@Tim S.

Thank you for your efforts to help, it is appreciated.  I have the settings below, setting the linker path does not make any difference in my case. I installed VS2010 to a non-default location as you can see (2nd partition on same HD, the C-partition was getting crowded). Not sure if XP vs. Win7 makes any difference.


<user_sets>
<msvc>
<NAME>
<str>
<![CDATA[MSVC]]>
</str>
</NAME>
<PARENT>
<str>
<![CDATA[msvc10]]>
</str>
</PARENT>
<INCLUDE_DIRS>
<str>
<![CDATA[C:\Program Files\Microsoft SDKs\Windows\v7.0A\Include;D:\zzSystem\Program Files\Microsoft Visual Studio 10.0\VC\include;]]>
</str>
</INCLUDE_DIRS>
<RES_INCLUDE_DIRS>
<str>
<![CDATA[C:\Program Files\Microsoft SDKs\Windows\v7.0A\Include;D:\zzSystem\Program Files\Microsoft Visual Studio 10.0\VC\include;]]>
</str>
</RES_INCLUDE_DIRS>
<LIBRARY_DIRS>
<str>
<![CDATA[C:\Program Files\Microsoft SDKs\Windows\v7.0A\Lib;D:\zzSystem\Program Files\Microsoft Visual Studio 10.0\VC\lib;]]>
</str>
</LIBRARY_DIRS>
<MASTER_PATH>
<str>
<![CDATA[D:\zzSystem\Program Files\Microsoft Visual Studio 10.0\VC]]>
</str>
</MASTER_PATH>
<EXTRA_PATHS>
<str>
<![CDATA[D:\zzSystem\Program Files\Microsoft Visual Studio 10.0\Common7\IDE;C:\Program Files\Microsoft SDKs\Windows\v7.0A\bin;]]>
</str>
</EXTRA_PATHS>
</msvc>
</user_sets>



One thing I found which may have helped my endless series of hangs and delays with this version was that I opened default.conf and deleted very long lists of references  to wxWidgets types under <HeaderFixup>. It reduced the size of default.conf from almost 500 KB to about 70KB. If the default.conf file is being saved/reloaded constantly (is it?), it might cause freeze-ups in the GUI for all I know, and that is what I have been seeing.

I just tried deleting MinGW again, and miracles, I don't get the yellow pop-up errors anymore after that..... I have also played around with disabling as many plugins as possible to see if that could fix it. See attached screenshot of my list. Perhaps one of the disabled ones were causing troubles.

I still get strange delays during compilation, but after reducing the size of the default.conf file at least the GUI is more responsive.

MortenMacFly

Quote from: cacb on July 09, 2012, 08:53:16 PM
I opened default.conf and deleted very long lists of references  to wxWidgets types under <HeaderFixup>. It reduced the size of default.conf from almost 500 KB to about 70KB.
This cannot cause such a delay. ConfigManager ind C::B can handle way more than that easily. However, in recent versions of C::B these settings are no longer stored in the defaut.conf if not really needed (due to changes made by the user). It looks like you had used an old version of C::B were this wasn't the case or really changed some of the options related to this plugin.
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: [url="https://www.codeblocks.org/docs/main_codeblocks_en.html"]https://www.codeblocks.org/docs/main_codeblocks_en.html[/url]
C::B FAQ: [url="https://wiki.codeblocks.org/index.php?title=FAQ"]https://wiki.codeblocks.org/index.php?title=FAQ[/url]

Hadomunt

Found a problem:
The Code::Blocks project template for gtk doesn't work with new versions of gtk.
The gtk developers have added a new needed by default library.

After some experimenting I came up with a solution.
Script that needs to be modified is:
<install dir>\CodeBlocks\share\CodeBlocks\templates\wizard\gtk\wizard.script

The gdk-pixbuf-2.0 library needs to be added.
(In the file after line 124.)
Code needs to be added that does a check on the relative path name and if it's there adds it.

Code that needs to be added:

if( IO.DirectoryExists(GtkPathDefaultInc + wxFILE_SEP_PATH + _T("gdk-pixbuf-2.0")) ){
   project.AddIncludeDir(GtkPathDefaultInc + wxFILE_SEP_PATH + _T("gdk-pixbuf-2.0"));
}


Adding the three lines of code solves the problem. Works with old and new versions of the gtk library.

sensey

hello, I have a problem with codeblocks but I dont know if it's really a codeblocks fault or a compiler problem, I compiled drivers with gcc 3.16 but since I upgraded to 4.x throws me the following error:

gcc.exe: error: unrecognized option '--subsystem,native'

anyone know if it can be solved?

MortenMacFly

Quote from: sensey on July 13, 2012, 03:27:04 AM
gcc.exe: error: unrecognized option '--subsystem,native'

anyone know if it can be solved?
Don't use that option with this compiler. The compiler does not recognise, a.k.a support the option. It is as simple as that.
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: [url="https://www.codeblocks.org/docs/main_codeblocks_en.html"]https://www.codeblocks.org/docs/main_codeblocks_en.html[/url]
C::B FAQ: [url="https://wiki.codeblocks.org/index.php?title=FAQ"]https://wiki.codeblocks.org/index.php?title=FAQ[/url]

sensey

Quote from: MortenMacFly on July 13, 2012, 09:55:23 AMDon't use that option with this compiler. The compiler does not recognise, a.k.a support the option. It is as simple as that.

but how to remove? it is auto added when you configure the target as native:

Quotemingw32-g++.exe  -o ..\driver.sys ..\driver.o   -s -nostartfiles -nostdlib -Wl,--entry,_DriverEntry@8 -Wl,--file-alignment,0x1000 -Wl,--section-alignment,0x1000 -Wl,--image-base,0x00010000 -Wl,--subsystem,native -def driver.def -s -static-libgcc -static-libstdc++  -lntoskrnl -lhal -lwin32k  --subsystem,native

this are the options of the project:

Quote-s -nostartfiles -nostdlib -Wl,--entry,_DriverEntry@8 -Wl,--file-alignment,0x1000 -Wl,--section-alignment,0x1000 -Wl,--image-base,0x00010000 -Wl,--subsystem,native -def driver.def -s -static-libgcc -static-libstdc++  -lntoskrnl -lhal -lwin32k

and the last: "--subsystem,native" is added by codeblocks, I also try disable the linker policy ("use project options only"), but it is still added...


Alpha

Does this patch fix it?

Index: src/plugins/compilergcc/compilerMINGW.cpp
===================================================================
--- src/plugins/compilergcc/compilerMINGW.cpp (revision 8106)
+++ src/plugins/compilergcc/compilerMINGW.cpp (working copy)
@@ -178,7 +178,7 @@
     m_Commands[(int)ctLinkConsoleExeCmd].push_back(CompilerTool(_T("$linker $libdirs -o $exe_output $link_objects $link_resobjects $link_options $libs")));
     if (platform::windows)
     {
-        m_Commands[(int)ctLinkNativeCmd].push_back(CompilerTool(_T("$linker $libdirs -o $exe_output $link_objects $link_resobjects $link_options $libs --subsystem,native")));
+        m_Commands[(int)ctLinkNativeCmd].push_back(CompilerTool(_T("$linker $libdirs -o $exe_output $link_objects $link_resobjects $link_options $libs -Wl,--subsystem,native")));
         m_Commands[(int)ctLinkExeCmd].push_back(CompilerTool(_T("$linker $libdirs -o $exe_output $link_objects $link_resobjects $link_options $libs -mwindows")));
         m_Commands[(int)ctLinkDynamicCmd].push_back(CompilerTool(_T("$linker -shared -Wl,--output-def=$def_output -Wl,--out-implib=$static_output -Wl,--dll $libdirs $link_objects $link_resobjects -o $exe_output $link_options $libs")));
     }


sensey

#24
Quote from: Alpha on July 13, 2012, 09:56:34 PMDoes this patch fix it?

Index: src/plugins/compilergcc/compilerMINGW.cpp
===================================================================
--- src/plugins/compilergcc/compilerMINGW.cpp (revision 8106)
+++ src/plugins/compilergcc/compilerMINGW.cpp (working copy)
@@ -178,7 +178,7 @@
    m_Commands[(int)ctLinkConsoleExeCmd].push_back(CompilerTool(_T("$linker $libdirs -o $exe_output $link_objects $link_resobjects $link_options $libs")));
    if (platform::windows)
    {
-        m_Commands[(int)ctLinkNativeCmd].push_back(CompilerTool(_T("$linker $libdirs -o $exe_output $link_objects $link_resobjects $link_options $libs --subsystem,native")));
+        m_Commands[(int)ctLinkNativeCmd].push_back(CompilerTool(_T("$linker $libdirs -o $exe_output $link_objects $link_resobjects $link_options $libs -Wl,--subsystem,native")));
        m_Commands[(int)ctLinkExeCmd].push_back(CompilerTool(_T("$linker $libdirs -o $exe_output $link_objects $link_resobjects $link_options $libs -mwindows")));
        m_Commands[(int)ctLinkDynamicCmd].push_back(CompilerTool(_T("$linker -shared -Wl,--output-def=$def_output -Wl,--out-implib=$static_output -Wl,--dll $libdirs $link_objects $link_resobjects -o $exe_output $link_options $libs")));
    }


I did not try but it would be better if you can disable it by "linker policy"... (or if you can edit what is added to)

carra

Quote from: ham on July 07, 2012, 10:51:54 PM
FEATURE REQUESTs for PROJECT MANAGER TreeView

multiselect files -> set (build) properties
multiselect files -> remove files
multiple selection of folder dialog when adding recursivly
I'm not sure if this should be taken as a feature request or rather as a bug... The Mananger window actually lets you select multiple files, and as a user one expects that any right-click menu option is applied to all of them. If I select 4 files and select "open", or "remove for project", only the first file is processed. So, why let me select multiple files then?

MortenMacFly

Quote from: carra on July 15, 2012, 01:49:23 PM
So, why let me select multiple files then?
This is a bug and should not be allowed. You can handle multiple files via the context menu of the project tree.
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: [url="https://www.codeblocks.org/docs/main_codeblocks_en.html"]https://www.codeblocks.org/docs/main_codeblocks_en.html[/url]
C::B FAQ: [url="https://wiki.codeblocks.org/index.php?title=FAQ"]https://wiki.codeblocks.org/index.php?title=FAQ[/url]

MortenMacFly

Quote from: MortenMacFly on July 15, 2012, 02:04:52 PM
This is a bug and should not be allowed. You can handle multiple files via the context menu of the project tree.
WRONG! the multiple selections are there for functionality like e.g. drag&drop. If "remove" and e.g. "open" does not work on all files than its simply not implemented.
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: [url="https://www.codeblocks.org/docs/main_codeblocks_en.html"]https://www.codeblocks.org/docs/main_codeblocks_en.html[/url]
C::B FAQ: [url="https://wiki.codeblocks.org/index.php?title=FAQ"]https://wiki.codeblocks.org/index.php?title=FAQ[/url]

stefanos_

Can someone please help me with this new issue that appeared with svn-8133 (compiled a couple of hours ago)? As soon as I start typing whatever has been parsed, for example a class, it gives me the tip-like message on top of class name and cannot see what the heck I am typing!


Below you can see yourself the attachment. As you can see, even the parentheses are not visible!

teto

Quote from: MortenMacFly on July 15, 2012, 02:36:38 PM
Quote from: MortenMacFly on July 15, 2012, 02:04:52 PM
This is a bug and should not be allowed. You can handle multiple files via the context menu of the project tree.
WRONG! the multiple selections are there for functionality like e.g. drag&drop. If "remove" and e.g. "open" does not work on all files than its simply not implemented.
I was going to post about this but too late. Another thing I noticed:
If a file belongs to any of the open projects , The entry "Add to active project" (when you right-click on an open file tab) disappears even if this very file doesn't belong to the active project.

Good job with merging branches.