Developer forums (C::B DEVELOPMENT STRICTLY!) > Development

Using minGW with STLport to compile wxWidgets anyone want the steps?

(1/2) > >>

stahta01:
I am compiling wxWidgets both 2.6 and 2.8 using minGW with STLport with wxUSE_STL=1.
Anyone want the steps I followed to do it?

Tim S

RJP Computing:
Sure. Information is always helpful. Please share.

stahta01:

--- Quote from: RJP Computing on February 05, 2007, 05:07:01 pm ---Sure. Information is always helpful. Please share.

--- End quote ---

OK, once I reach a stopping post I will add entries to this thread and later to the WiKi.
Working in trying to get C::B compiling against it. A lot of changes needed.

To many changes I gave up getting C::B to use the wxWidgets using STLport.

Tim S

stahta01:
Note, STLport-5.1.0 had problems for me it may work for you, but 5.0.3 worked to build 2.6 CVS branch.
Note, follow the readme for cygwin without the vb6 option and it worked for me to build STLport the first time. Note, I have notice some things (not STLport but other things) do NOT like make version 3.81 or 3.79 so use make version 3.80 if you can.

Step 1 download STLport-5.0.3 from http://sourceforge.net/projects/stlport

Step 2 extract files

Step 3 copy the deepest STLport-5.0.3 folder which contains sub-folders build, stlport, test and etc. to your mingw folder.

This should result in a path like below, you can rename STLport-5.0.3 if you want, but all directories below it can NOT be renamed.
c:\mingw\STLport-5.0.3\build\lib

My mingw is the candidate version with GCC 3.4.5 and mingw32-make.exe version of 3.80
My MSys is from MSYS-1.0.11-2004.04.30-1.exe

Step 4A Open MSys
Step 4B cd /mingw/STLport-5.0.3/build/lib
Note: It worked for me without doing configure, but another post had it and it makes sense to do it.
STEP 4B2 configure -c gcc
Step 4C mingw32-make.exe -f gcc.mak depend
Step 4D mingw32-make.exe -f gcc.mak install

Step 5A cd ..
Step 5B cd test/unit
Step 5C mingw32-make.exe -f gcc.mak
Warnings are normal; errors are NOT!
"undefined references" should not happen either but they did for me on the test.

Note: You need to copy the DLLs in the STLport-5.0.3/bin to were the exe files are.

The commands to compile wxWidgets 2.6 is below


--- Code: ---SET PATH=C:\MinGW\bin;C:\MinGW\mingw32\bin
CD wxWidgets-2.6_BRANCH\build\msw
mingw32-make -f makefile.gcc VENDOR=branch-26-stlport USE_XRC=1 SHARED=1 MONOLITHIC=1 BUILD=release UNICODE=1 CLEAN
mingw32-make -f makefile.gcc VENDOR=branch-26-stlport USE_XRC=1 SHARED=1 MONOLITHIC=1 BUILD=release UNICODE=1 CPPFLAGS="-DWINVER=0x0600 -isystem C:\apps\MinGW_GCC_3.4.5_API_3_8_STLport\STLport\stlport -isystem C:\apps\MinGW_GCC_3.4.5_API_3_8_STLport\include" LDFLAGS="-LC:\apps\MinGW_GCC_3.4.5_API_3_8_STLport\STLport\lib -lstlport.5.0.dll -lstlportg.5.0.dll -lstlportstlg.5.0.dll"


--- End code ---

Meaning of some of the build options
  VENDOR=branch-26-stlport set the DLL to have branch-26-stlport in the name (This is optional)
  CPPFLAGS set Preprocessor flags to define WINVER=0x0600 (this is the value for windows vista and is the default value used by wxWidgets, therefore it can be removed but it helps to make bad code in wxWidgets work so if compiling against CVS it is highly recommened.)
  CPPFLAGS is also used to set the system include directories using the -isystem option.
  Note, the stlport must be the first system include directory.

  LDFLAGS is used to pass linker options the order of libraries was random it worked for me building wxWidgets building something else the order my need correction.

Tim S









stahta01:
The setting in code::blocks needed to compile and link a program that uses STLport.

[Global Compiler Settings]

Compiler -> Other Options
  -isystem C:\MinGW\STLport\stlport
  -isystem C:\MinGW\include

Linker (note the order was random no idea if it is correct.)
  stlport.5.0.dll
  stlportg.5.0.dll
  stlportstlg.5.0.dll

Directories

  Compiler (this is a folder that does not exist to prevent a value from being set on C::B startup.)
     C:\null

  Linker
     C:\MinGW\STLport\lib
     C:\MinGW\lib

   Resource Compiler
     C:\MinGW\include

Tim S



Navigation

[0] Message Index

[#] Next page

Go to full version