CodeBlocks

  • 準備
    • wxWidgets2.6.2のインストール
      • 最初にsetup.hのコピーを忘れずに。"<wxdir>/include/wx/msw/setup.h" -> "<wxdir>/include/wx/setup.h"
    • code::Blockのコンパイルオプションでディレクトリ指定
Compiler:
C:\wxWidgets-2.6.2\include
C:\wxWidgets-2.6.2\contrib\include

Linker:
C:\wxWidgets-2.6.2\lib\gcc_dll

Resource compiler:
C:\wxWidgets-2.6.2\include

C:\wxWidgets-2.6.2\lib\gcc_dllフォルダを削除する
config.gccを以下のように変更

# =========================================================================
#     This configuration file was generated by
#     Bakefile 0.1.9 (http://bakefile.sourceforge.net)
#     Beware that all changes made to this file will be overwritten next
#     time you run Bakefile!
# =========================================================================


# -------------------------------------------------------------------------
# These are configurable options:
# -------------------------------------------------------------------------

# C compiler 
# CC = gcc
CC = mingw32-gcc.exe

# C++ compiler 
CXX = mingw32-g++.exe

# Standard flags for CC 
CFLAGS = -I"C:\Program Files\CodeBlocks\include"

# Standard flags for C++ 
CXXFLAGS = -I"C:\Program Files\CodeBlocks\include"

# Standard preprocessor flags (common for CC and CXX) 
CPPFLAGS = -I"C:\Program Files\CodeBlocks\include"

# Standard linker flags 
LDFLAGS = 

# What type of library to build? [0,1]
SHARED = 1

# Build wxUniversal instead of native port? [0,1]
WXUNIV = 0

# Compile Unicode build of wxWidgets? [0,1]
UNICODE = 0

# Use MSLU library when building Unicode version. [0,1]
MSLU = 0

# Type of compiled binaries [debug,release]
#BUILD = debug
BUILD = release

# Should debugging info be included in the executables? The default value
# "default" means that debug info will be included if BUILD=debug
# and not included if BUILD=release. [0,1,default]
DEBUG_INFO = default

# Should __WXDEBUG__ be defined? The default value "default" means that it will
# be defined if BUILD=debug and not defined if BUILD=release. [0,1,default]
DEBUG_FLAG = default

# Multiple libraries or single huge monolithic one? [0,1]
#MONOLITHIC = 0
MONOLITHIC = 1

# Build GUI libraries? [0,1]
USE_GUI = 1

# Build wxHTML library (USE_GUI must be 1)? [0,1]
USE_HTML = 1

# Build wxXRC library (USE_GUI must be 1)? [0,1]
USE_XRC = 1

# Build OpenGL canvas library (USE_GUI must be 1)? [0,1]
USE_OPENGL = 0

# Build ODBC database classes (USE_GUI must be 1)? [0,1]
USE_ODBC = 0

# Build quality assurance classes library (USE_GUI must be 1)? [0,1]
USE_QA = 0

# Enable exceptions in compiled code. [0,1]
USE_EXCEPTIONS = 1

# Enable run-time type information (RTTI) in compiled code. [0,1]
USE_RTTI = 1

# Enable threading in compiled code. [0,1]
USE_THREADS = 1

# Is this official build by wxWidgets developers? [0,1]
OFFICIAL_BUILD = 0

# Use this to name your customized DLLs differently 
#VENDOR = custom
VENDOR = cb

#  
WX_FLAVOUR = 

#  
WX_LIB_FLAVOUR = 

# Name of your custom configuration. This affects directory
# where object files are stored as well as the location of
# compiled .lib files and setup.h under the lib/ toplevel directory. 
CFG = 

# Compiler flags needed to compile test suite in tests directory. If you want
# to run the tests, set it so that the compiler can find CppUnit headers. 
CPPUNIT_CFLAGS = 

# Linker flags needed to link test suite in tests directory. If you want
# to run the tests, include CppUnit library here. 
CPPUNIT_LIBS = 

# Version of C runtime library to use. You can change this to
# static if SHARED=0, but it is highly recommended to not do
# it if SHARED=1 unless you know what you are doing. [dynamic,static]
RUNTIME_LIBS = dynamic

# Set the version of your Mingw installation here.
#     "3" ...... this is for Mingw 2.0 or newer (comes with gcc3)
#     "2.95" ... for Mingw 1.1 or any of the older versions [3,2.95]
GCC_VERSION = 3

パス移動

cd C:\wxWidgets-2.6.2\build\msw

コンパイル(時間かかります)

mingw32-make -f makefile.gcc BUILD=release SHARED=1 MONOLITHIC=1 USE_XRC=1 UNICODE=0 VENDOR=cb

C:\wx2.6.2\lib\gcc_dll配下にwxmsw26_gcc_cb.dllができます。
パスの通ってるフォルダにコピーしましょう(c:\windows\system32が最適だそうで)

次のパス移動

cd ..\..\contrib\build\stc

さらにコンパイル

mingw32-make -f makefile.gcc BUILD=release SHARED=1 MONOLITHIC=1 USE_XRC=1 UNICODE=0 VENDOR=cb

C:\wx2.6.2\lib\gcc_dll配下にwxmsw26_stc_gcc_cb.dllができます。
パスの通ってるフォルダにコピーしましょう(c:\windows\system32が最適だそうで)

  • wxSmith
    • まだ開発中くさいがcode::blocksのソースのプラグインの中に存在してる
    • コンパイルするにはwxWidgetsが必要