Building hmg3
Moderator: Rathinagiri
- Rathinagiri
- Posts: 5482
- Joined: Tue Jul 29, 2008 6:30 pm
- DBs Used: MariaDB, SQLite, SQLCipher and MySQL
- Location: Sivakasi, India
- Contact:
Re: Building hmg3
Hi Marek,
Yes, I am just working on that.
Yes, I am just working on that.
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
South or North HMG is worth.
...the possibilities are endless.
- Rathinagiri
- Posts: 5482
- Joined: Tue Jul 29, 2008 6:30 pm
- DBs Used: MariaDB, SQLite, SQLCipher and MySQL
- Location: Sivakasi, India
- Contact:
Re: Building hmg3
Hi,
I am just listing the procedure to be followed to build hmg using latest harbour.
I am just listing the procedure to be followed to build hmg using latest harbour.
- Download latest build of harbour (I had downloaded nightly build Harbour Windows executable from http://sourceforge.net/projects/harbour ... e/download)
- Install it in default directory (c:\hb21)
- Now backup your existing hmg folder somewhere safe and delete harbour, mingw folders
- Copy all the folders from c:\hb21\bin,lib,contrib,include,doc to c:\hmg\harbour\
- Copy all the folders from c:\hb21\comp\mingw\*.* to c:\hmg\mingw\
- Now, you have to make the following edits in hmg source to get the library compiled successfully.
- Edit in \hmg\source\c_media.c - Replace line no. 144 with the following:
Code: Select all
// hwnd=MCIWndCreate((HWND) hb_parnl(1),NULL,Style,hb_parc(2)); - Edit in \hmg\source\h_init.prg - Replace line no. 628 with the following:
Code: Select all
_HMG_SYSDATA [ 306 ] := ( EMPTY( CreateMutex( , .T., strtran(GetProgramFileName(),'\','_') ) ) .OR. (HMGGetLastError() > 0) ) - Edit in \hmg\source\c_winapimisc.c - Replace line no. 416 to 419 with the following:
Code: Select all
HB_FUNC ( HMGGETLASTERROR ) { hb_retnl( (LONG) GetLastError() ) ; } - Edit in \hmg\source\h_windows.prg. Replace line no 5588 with the following:
Code: Select all
uResult := CallDll32 ( "IsAppThemed" , "UXTHEME.DLL" )
- Edit in \hmg\source\c_media.c - Replace line no. 144 with the following:
- Now create these files:
- BuildLib.bat in c:\hmg
Code: Select all
@echo off SET HMGPATH=\hmg SET PATH=%HMGPATH%\harbour\bin;%HMGPATH%\mingw\bin;%PATH% hbmk2 hmg.hbp - hmg.hbp in c:\hmg
Code: Select all
-hblib -inc -olib/hmg -Iinclude -D__HBIDE__ -w0 -es2 source/ErrorSys.prg source/h_browse.prg source/h_button.prg source/h_checkbox.prg source/h_combo.prg source/h_controlmisc.prg source/h_datepicker.prg source/h_dialogs.prg source/h_editbox.prg source/h_error.prg source/h_font.prg source/h_frame.prg source/h_grid.prg source/h_help.prg source/h_hotkey.prg source/h_image.prg source/h_init.prg source/h_ipaddress.prg source/h_label.prg source/h_listbox.prg source/h_media.prg source/h_menu.prg source/h_monthcal.prg source/h_msgbox.prg source/h_progressbar.prg source/h_radio.prg source/h_richeditbox.prg source/h_rptgen.prg source/h_slider.prg source/h_spinner.prg source/h_status.prg source/h_tab.prg source/h_textbox.prg source/h_timer.prg source/h_toolbar.prg source/h_tree.prg source/h_winapimisc.prg source/h_windows.prg source/c_browse.c source/c_button.c source/c_checkbox.c source/c_combo.c source/c_controlmisc.c source/c_datepicker.c source/c_dialogs.c source/c_editbox.c source/c_font.c source/c_frame.c source/c_grid.c source/c_help.c source/c_hotkey.c source/c_image.c source/c_ipaddress.c source/c_label.c source/c_listbox.c source/c_media.c source/c_menu.c source/c_monthcal.c source/c_msgbox.c source/c_progressbar.c source/c_radio.c source/c_resource.c source/c_richeditbox.c source/c_slider.c source/c_spinner.c source/c_status.c source/c_tab.c source/c_textbox.c source/c_timer.c source/c_toolbar.c source/c_tree.c source/c_winapimisc.c source/c_windows.c - hmg.hbc in c:\hmg
Code: Select all
incpaths=include libpaths=lib incpaths=\hmg\include libpaths=\hmg\lib libs=hbmzip.hbc libs=hbwin.hbc libs=${hb_name}${__HB_DYN__} libs=hbct.hbc gui=yes
- BuildLib.bat in c:\hmg
- Run buildlib.bat from c:\hmg
- Now you can find various warnings etc,. and libhmg.a is created in c:\hmg\lib
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
South or North HMG is worth.
...the possibilities are endless.
- esgici
- Posts: 4543
- Joined: Wed Jul 30, 2008 9:17 pm
- DBs Used: DBF
- Location: iskenderun / Turkiye
- Contact:
Re: Building hmg3
Thanks a lot Rathi, you are a real diamondrathinagiri wrote: I am just listing the procedure to be followed to build hmg using latest harbour.
We will wait eagerlyrathinagiri wrote: Next I will tell you how to compile applications.
Best Regards
--
Esgici
Viva INTERNATIONAL HMG 
- Rathinagiri
- Posts: 5482
- Joined: Tue Jul 29, 2008 6:30 pm
- DBs Used: MariaDB, SQLite, SQLCipher and MySQL
- Location: Sivakasi, India
- Contact:
Re: Building hmg3
Now we shall see how to build an application.
- Create buildapp.bat in c:\hmg with the following:
Code: Select all
@echo off SET HMGPATH=c:\hmg SET PATH=%HMGPATH%\harbour\bin;%HMGPATH%\mingw\bin;%PATH% HBMK2 -gtgui %1 %2 %3 %4 %5 %6 %7 %8 - Create build.bat in your project folder with the following:
Code: Select all
@echo off c:\hmg\buildapp.bat %1 %2 %3 %4 %5 %6 %7 %8 -run - Create hbmk.hbm in the project folder with the following:
Code: Select all
c:\hmg\hmg.hbc - Create projectname.hbp in your project folder as usual with all the source files. If you have resource file (.rc) include the name of the resource file also.
- Use build projectname.hbp to build the project.
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
South or North HMG is worth.
...the possibilities are endless.
- Rathinagiri
- Posts: 5482
- Joined: Tue Jul 29, 2008 6:30 pm
- DBs Used: MariaDB, SQLite, SQLCipher and MySQL
- Location: Sivakasi, India
- Contact:
Re: Building hmg3
Now, in the above method, I had compiled one of my big projects and it works fine except for the following problems.
1. When the Windows is themed, some (label, slider, checkbox, radiobutton) controls (especially inside tab) are shown with black background. If the windows is not themed, it works fine.
2. We can't use player control. (Since we have commented out a line in c:\hmg\source\c_media.c to compile/build successfully.)
Now, IMHO, all the above problems can be solved by Harbour/C gurus in our forum in a matter of seconds. If you know the solution to any of the above problems or found any new problem, kindly post here.
1. When the Windows is themed, some (label, slider, checkbox, radiobutton) controls (especially inside tab) are shown with black background. If the windows is not themed, it works fine.
2. We can't use player control. (Since we have commented out a line in c:\hmg\source\c_media.c to compile/build successfully.)
Now, IMHO, all the above problems can be solved by Harbour/C gurus in our forum in a matter of seconds. If you know the solution to any of the above problems or found any new problem, kindly post here.
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
South or North HMG is worth.
...the possibilities are endless.
- esgici
- Posts: 4543
- Joined: Wed Jul 30, 2008 9:17 pm
- DBs Used: DBF
- Location: iskenderun / Turkiye
- Contact:
Re: Building hmg3
Thanks again Rathirathinagiri wrote:Now we shall see how to build an application.
Regards
--
Esgici
Viva INTERNATIONAL HMG 
- karweru
- Posts: 220
- Joined: Fri Aug 01, 2008 1:51 pm
- DBs Used: DBF,mysql,mariadb,postgresql,sqlite,odbc
- Contact:
Re: Building hmg3
Hi Rathi,
I just can't thank you enough for this. Thank you, thank you, thank you!
I just can't thank you enough for this. Thank you, thank you, thank you!
Kind regards,
Gilbert.
Gilbert.
- Rathinagiri
- Posts: 5482
- Joined: Tue Jul 29, 2008 6:30 pm
- DBs Used: MariaDB, SQLite, SQLCipher and MySQL
- Location: Sivakasi, India
- Contact:
Re: Building hmg3
I have solved the console window problem by changing buildapp.bat. Now we have just two problems to be solved.
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
South or North HMG is worth.
...the possibilities are endless.
- Rathinagiri
- Posts: 5482
- Joined: Tue Jul 29, 2008 6:30 pm
- DBs Used: MariaDB, SQLite, SQLCipher and MySQL
- Location: Sivakasi, India
- Contact:
Re: Building hmg3
I had done just nothing.karweru wrote:Hi Rathi,
I just can't thank you enough for this. Thank you, thank you, thank you!
Already Roberto utilized hbmk2 to build HMG 4 library. I tried to build the same way HMG 3 too. With just two modifications, I could build the library without any problems.
We have to solve the two problems to make it complete.
In the mean time, shall I make bundle of all these things and share it here?
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
South or North HMG is worth.
...the possibilities are endless.