Improvements of bakefile scripts

Money Manager Ex Development related posts
(http://github.moneymanagerex.org/)
Post Reply
Vadim
MMEX Developer
Posts: 142
Joined: Mon Aug 03, 2009 7:35 am
Are you a spam bot?: No

Improvements of bakefile scripts

Post by Vadim »

I have modified build system of mmex.
mmex.bkl moved to mmex/build/bakefiles. README.TXT updated and includes all necessary information how to build sources step by step. I have tested new build scripts on Fedora-11.

Now we can use MinGW to build mmex on Windows. But I didn't completed this task. I have some problems with generated makefile for gcc. bakefile will generate scripts in mmex/build/msw. But currently you should move scripts to mmex directory due to invalid paths to source files in makefile. MinGW gcc perfectly compiles mmex sources but could not link mmex.exe due to problems in wxWidgets libraries. I didn't resolved these errors yet.

Vadim
MMEX Developer
Posts: 142
Joined: Mon Aug 03, 2009 7:35 am
Are you a spam bot?: No

Re: Improvements of bakefile scripts

Post by Vadim »

Bakefile script now correctly generates makefile for MinGW. Anyone can run
cd trunk/mmex/build/msw
mingw32-make -f makefile.gcc

But linking error still remains :-(

Nikolay
MMEX Developer
Posts: 1287
Joined: Sat Dec 06, 2008 2:27 pm
Are you a spam bot?: No
Location: Sankt-Petersburg, Russia

Re: Improvements of bakefile scripts

Post by Nikolay »

I have the error:
.......
windres --use-temp-file -i../../resources/mmex.rc -ommex_mmex_rc.o --define HAV
E_W32API_H --define __WXDEBUG__ --define __WXMSW__ --include-dir \lib\gcc_lib\m
swd --include-dir /include --include-dir ../../include --include-dir ../../sqlit
e
../../resources/mmex.rc:2:24: wx/msw/wx.rc: No such file or directory
windres: gcc exited with status 1
mingw32-make.EXE: *** [mmex_mmex_rc.o] Error 1

Vadim
MMEX Developer
Posts: 142
Joined: Mon Aug 03, 2009 7:35 am
Are you a spam bot?: No

Re: Improvements of bakefile scripts

Post by Vadim »

May be you did not compile wxWidgets with MinGW. Firstly anyone should build wxWidgets, next try to compile mmex.

Nikolay
MMEX Developer
Posts: 1287
Joined: Sat Dec 06, 2008 2:27 pm
Are you a spam bot?: No
Location: Sankt-Petersburg, Russia

Re: Improvements of bakefile scripts

Post by Nikolay »


Vadim
MMEX Developer
Posts: 142
Joined: Mon Aug 03, 2009 7:35 am
Are you a spam bot?: No

Re: Improvements of bakefile scripts

Post by Vadim »

I have successfuly built mmex using MinGW :-)
Instructions:

1.Modify wxWidgets\include\wx\msw\setup.h
wxUSE_TAB_DIALOG 1
wxUSE_UNICODE 1

2.Modify wxWidgets\build\msw\config.gcc
UNICODE ?= 1
MONOLITHIC ?= 1

3.Build library
cd wxWidgets\build\msw
mingw32-make -f makefile.gcc %* 2> mingw.log

4. Modify mmex\build\msw\config.gcc for mmex
WX_UNICODE ?= 1
WX_MONOLITHIC ?= 1

5. Build mmex
cd mmex\build\msw
mingw32-make -f makefile.gcc %* 2> mingw.log

Vadim
MMEX Developer
Posts: 142
Joined: Mon Aug 03, 2009 7:35 am
Are you a spam bot?: No

Re: Improvements of bakefile scripts

Post by Vadim »

You do not need MSYS to build wxWidgets. It is not necessary.
OMG! :o The debug version of mmex.exe is 56 MB, release is 22 Mb!!!
Welcome to MONOLITHIC build of library! It's terrible size :-(

Nikolay
MMEX Developer
Posts: 1287
Joined: Sat Dec 06, 2008 2:27 pm
Are you a spam bot?: No
Location: Sankt-Petersburg, Russia

Re: Improvements of bakefile scripts

Post by Nikolay »

Hi again.

It does not work for me.

mingw32-make.EXE: *** No rule to make target `%*'. Stop.

or

process_begin: CreateProcess(NULL, -c "if not exist gcc_mswud mkdir gcc_mswud",
...) failed.
make (e=2): Не удается найти указанный файл.♪
mingw32-make.EXE: [gcc_mswud] Error 2 (ignored)
process_begin: CreateProcess(NULL, -c "if not exist ..\..\lib\gcc_lib\mswud mkdi
r ..\..\lib\gcc_lib\mswud", ...) failed.
make (e=2): Не удается найти указанный файл.♪
mingw32-make.EXE: *** [..\..\lib\gcc_lib\mswud] Error 2

Vadim
MMEX Developer
Posts: 142
Joined: Mon Aug 03, 2009 7:35 am
Are you a spam bot?: No

Re: Improvements of bakefile scripts

Post by Vadim »

Sorry, "%*" came from my .bat file. Create in build/msw file mingw.bat with this contents

set PATH=C:\bin\MinGW\bin;C:\bin\MinGW\lib;%PATH%
mingw32-make -f makefile.gcc %* 2> mingw.log

And compile sources using command "mingw.bat". To clean use "mingw.bat clean" and so on.

P.S. You should modify path to MinGW in one differs.

Vadim
MMEX Developer
Posts: 142
Joined: Mon Aug 03, 2009 7:35 am
Are you a spam bot?: No

Re: Improvements of bakefile scripts

Post by Vadim »

The release build of mmex.exe now is 10 MB, so everyone can freely use MinGW to build mmex. UPX compresses mmex.exe to 4.5 Mb.

Post Reply