Just upgraded to 3.0.38, but have problem...

General Help regarding HMG, Compilation, Linking, Samples

Moderator: Rathinagiri

User avatar
mol
Posts: 3774
Joined: Thu Sep 11, 2008 5:31 am
Location: Myszków, Poland
Contact:

Re: Just upgraded to 3.0.38, but have problem...

Post by mol »

rathinagiri wrote:Hi Marek,

hbvpdf library is not included I think. :(

Try include these files in your project code or create a separate library.
I had this library from previous version of harbour :D
thanks , Rathi!
James
Posts: 7
Joined: Sat Jul 16, 2011 4:05 pm

Re: Just upgraded to 3.0.38, but have problem...

Post by James »

Hi, Rathinagiri,

Thanks for your help!

I'm having difficulty making a console app, because when I put HB_GT_WIN_DEFAULT in the .prg, I get an error:

Image

Maybe I'm doing something wrong... :(
User avatar
l3whmg
Posts: 694
Joined: Mon Feb 23, 2009 8:46 pm
Location: Italy
Contact:

Re: Just upgraded to 3.0.38, but have problem...

Post by l3whmg »

Hi guys.
I have some problem with HMG 3.x and Harbour. I think, because I'm working with different installation.
Anyway:
I receive this errorlog from AGENDA samples:
hbmk2: Processing environment options: -compiler=mingw
Harbour 3.1.0dev (Rev. 16957)
Copyright (c) 1999-2011, http://harbour-project.org/
D:/HMiniGui/HMiniGui3/hmg/lib/libhmg.a(h_controlmisc.o):h_controlmisc.c:(.data+0xf18): undefined reference to `HB_FUN_FREELIBRARY'
D:/HMiniGui/HMiniGui3/hmg/lib/libhmg.a(h_controlmisc.o):h_controlmisc.c:(.data+0x1948): undefined reference to `HB_FUN_TOLEAUTO'
D:/HMiniGui/HMiniGui3/hmg/lib/libhmg.a(c_windows.o):c_windows.c:(.text+0x1780): undefined reference to `ISNIL'
D:/HMiniGui/HMiniGui3/hmg/lib/libhmg.a(c_windows.o):c_windows.c:(.text+0x2e4c): undefined reference to `ISCHAR'
D:/HMiniGui/HMiniGui3/hmg/lib/libhmg.a(c_winapimisc.o):c_winapimisc.c:(.text+0x741): undefined reference to `ISNIL'
D:/HMiniGui/HMiniGui3/hmg/lib/libhmg.a(c_winapimisc.o):c_winapimisc.c:(.text+0xded): undefined reference to `ISNIL'
D:/HMiniGui/HMiniGui3/hmg/lib/libhmg.a(c_winapimisc.o):c_winapimisc.c:(.text+0xe03): undefined reference to `ISNIL'
D:/HMiniGui/HMiniGui3/hmg/lib/libhmg.a(c_winapimisc.o):c_winapimisc.c:(.text+0xe23): undefined reference to `ISNIL'
D:/HMiniGui/HMiniGui3/hmg/lib/libhmg.a(c_winapimisc.o):c_winapimisc.c:(.text+0xfe7): undefined reference to `ISCHAR'
D:/HMiniGui/HMiniGui3/hmg/lib/libhmg.a(c_winapimisc.o):c_winapimisc.c:(.text+0x1013): undefined reference to `ISNIL'
D:/HMiniGui/HMiniGui3/hmg/lib/libhmg.a(c_dialogs.o):c_dialogs.c:(.text+0x8ee): undefined reference to `ISARRAY'
D:/HMiniGui/HMiniGui3/hmg/lib/libhmg.a(c_dialogs.o):c_dialogs.c:(.text+0x915): undefined reference to `ISARRAY'
D:/HMiniGui/HMiniGui3/hmg/lib/libhmg.a(c_dialogs.o):c_dialogs.c:(.text+0x93c): undefined reference to `ISARRAY'
D:/HMiniGui/HMiniGui3/hmg/lib/libhmg.a(c_dialogs.o):c_dialogs.c:(.text+0x963): undefined reference to `ISARRAY'
D:/HMiniGui/HMiniGui3/hmg/lib/libhmg.a(c_dialogs.o):c_dialogs.c:(.text+0x98a): undefined reference to `ISARRAY'
D:/HMiniGui/HMiniGui3/hmg/lib/libhmg.a(c_dialogs.o):c_dialogs.c:(.text+0x9b1): more undefined references to `ISARRAY' follow
D:/HMiniGui/HMiniGui3/hmg/lib/libhmg.a(c_dialogs.o):c_dialogs.c:(.text+0xb6d): undefined reference to `ISNIL'
D:/HMiniGui/HMiniGui3/hmg/lib/libhmg.a(c_dialogs.o):c_dialogs.c:(.text+0xb8a): undefined reference to `ISNIL'
D:/HMiniGui/HMiniGui3/hmg/lib/libhmg.a(c_dialogs.o):c_dialogs.c:(.text+0xbac): undefined reference to `ISNIL'
collect2: ld returned 1 exit status
hbmk2: Error: Running linker. 1
D:\HMiniGui\HARBOUR\comp\mingw\bin\gcc.exe C:/DOCUME~1/luigi/IMPOST~1/Temp/hbmk_qs8xgv.dir/agenda.o C:/DOCUME~1/luigi/IMPOST~1/Temp/hbmk_qs8xgv.dir/hbmk_0aoflx.o D:/HMiniGui/HMiniGui3/hmg/SAMPLES/AGENDA/_temp.o -mwindows -Wl,--start-group -lhmg -lcrypt -ledit -leditex -lgraph -lhfcl -lini -lreport -lmsvfw32 -lvfw32 -lhbct -lhbwin -lhbmzip -lminizip -lhbmemio -lhbmisc -lhbmysql -lmysql -lhbtip -lsqlite3 -lhbsqlit3 -lsddodbc -lrddsql -lsddmy -lhbodbc -lodbc32 -lhbhpdf -lhbfimage -lhbpgsql -lhbnetio -lhbextern -lhbdebug -lhbvm -lhbrtl -lhblang -lhbcpage -lgtcgi -lgtpca -lgtstd -lgtwin -lgtwvt -lgtgui -lhbrdd -lhbuddall -lhbusrrdd -lrddntx -lrddcdx -lrddnsx -lrddfpt -lhbrdd -lhbhsx -lhbsix -lhbmacro -lhbcplr -lhbpp -lhbcommon -lhbmainwin -lkernel32 -luser32 -lgdi32 -ladvapi32 -lws2_32 -lwinspool -lcomctl32 -lcomdlg32 -lshell32 -luuid -lole32 -loleaut32 -lmpr -lwinmm -lmapi32 -limm32 -lmsimg32 -lwininet -lhbpcre -lhbzlib -Wl,--end-group -oagenda.exe -LD:/HMiniGui/HARBOUR/lib/win/mingw -LD:/HMiniGui/HARBOUR/bin -LD:/HMiniGui/HMiniGui3/hmg/lib
I'm using this environment:

A) D:\HMiniGui\harbour: I have centralized Harbour distribution (bin and source complete)
B) D:\HMiniGui\HMiniGui3\hmg: hmg distribution without HARBOUR and MINGW folder
C) I do these little change within batch command:
C.1 buildlib.bat I add these lines to adjust Harbour path and keep clean my PATH var

Code: Select all

SET HB_COMPILER=mingw
SET HRBHOME=D:\HMiniGui\HARBOUR
SET HRBBIN=%HRBHOME%\bin
SET HRBLOG=hb_error.log
SET SAVPATH=%PATH%
SET PATH=%PATH%;%MGWBIN%;%HRBBIN%
C.2 build.bat I add these lines to adjust Harbour path and Mingw path (windres problem) and keep clean my PATH var

Code: Select all

	SET HMGPATH=%~dp0
SET HB_COMPILER=mingw
SET HRBHOME=D:\HMiniGui\HARBOUR
SET HRBBIN=%HRBHOME%\bin
SET MGWHOME=%HRBHOME%\comp\mingw
SET MGWBIN=%MGWHOME%\bin
rem ******************************************************************************
rem SET BINARIES PATHS
rem ******************************************************************************
rem	SET PATH=%HMGPATH%\harbour\bin;%HMGPATH%\mingw\bin;%PATH%
SET SAVPATH=%PATH%
SET PATH=%PATH%;%HRBBIN%;%MGWBIN%
Some idea about these problems?

Many thanks in advance.

Cheers
Luigi from Italy
www.L3W.it
User avatar
l3whmg
Posts: 694
Joined: Mon Feb 23, 2009 8:46 pm
Location: Italy
Contact:

Re: Just upgraded to 3.0.38, but have problem...

Post by l3whmg »

Hi guys,
no one? Well, I find the solution! The problem was harbour libs list. I have copied from hb.hbc all lines inside "# harbour contrib list" and then I can compile and run my program.
But a little question: what is the minimal lib list required by HMG3.0.38? ie I don't use: "crypt", "edit", "editex", "graph", "hfcl", "ini" and "report". In this situation what are the harbour contrib library that I must include (about hmg, obviously).

Many thanks.

Cheers
Luigi from Italy
www.L3W.it
User avatar
danielmaximiliano
Posts: 2625
Joined: Fri Apr 09, 2010 4:53 pm
Location: Argentina
Contact:

Re: Just upgraded to 3.0.38, but have problem...

Post by danielmaximiliano »

James wrote: I'm having difficulty making a console app, because when I put HB_GT_WIN_DEFAULT in the .prg, I get an error:
Hi James:
I do not use HB_GT_WIN_DEFAULT on mi .prg
build.bat simply use this in my folder where my console application

Code: Select all

@echo off
@echo  
SET HMGPATH=C:\HMG3.0.38\
if "%1"=="" goto Input
call %HMGPATH%build.bat  %*
goto Finish

:Input
SET Filename=
SET Parameter=
@cls
@echo ********************************************************************************
@echo   This batch file passes information to hbmk2 to make possible an easy 
@echo   (zero configuration build of HMG applications).
@echo ********************************************************************************
@echo.
rem @color 01
@echo Enter Filename to compile, Filename.hbp assume if it exists
@echo.
rem @echo Enter <Esc> for Exit
@Set /p Filename=                        Application Name :
@echo.
if {%Filename%}=={} goto :Finish
@echo *******************************************************************************
@echo  Extra parameters
@echo                           /n	no run after build
@echo                           /d	enabled debugger
@echo                           /c	console mode
@echo Note: " <Enter> key entering no parameter is passed "
@echo *******************************************************************************
@echo.
@Set /p Parameter=                      passing parameters :
@echo.
rem @if %Filename% 
If "%Parameter%"=="" goto Continue
@echo compilation with parameters
@if EXIST %Filename%.hbp Goto HBPParameters 
@if EXIST %Filename%.prg Goto PRGParameters
@echo 
@echo HMG Source not found !!!!!
@echo Press any key and Retry.....
@Pause >nul
goto Input



:HBPParameters
@Echo Compile %Filename%.hbp With %Parameter%
call %HMGPATH%build.bat %Parameter% %filename%.hbp 
goto Input

:PRGParameters
@Echo Compile %Filename%.PRG With %Parameter%
call %HMGPATH%build.bat %Parameter% %%filename%.prg
@Pause
goto Input


:Continue
@echo no parameters compilation
@if EXIST %Filename%.hbp Goto HBP 
@if EXIST %Filename%.prg Goto PRG
@echo.
@echo 
@echo HMG Source not found !!!!!
@echo Press any key and Retry.....
@pause > nul
@goto Input

:HBP
@Echo Compile %Filename%.hbp
call %HMGPATH%build.bat %filename%.hbp 
goto Input

:PRG
@Echo Compile %Filename%.prg
call %HMGPATH%build.bat %filename%.prg
goto Input

:Finish
@exit

*´¨)
¸.·´¸.·*´¨) ¸.·*¨)
(¸.·´. (¸.·` *
.·`. Harbour/HMG : It's magic !
(¸.·``··*

Saludos / Regards
DaNiElMaXiMiLiAnO

Whatsapp. := +54901169026142
Telegram Name := DaNiElMaXiMiLiAnO
User avatar
danielmaximiliano
Posts: 2625
Joined: Fri Apr 09, 2010 4:53 pm
Location: Argentina
Contact:

Re: Just upgraded to 3.0.38, but have problem...

Post by danielmaximiliano »

Hi James:
Mrs Rathinagiri Refers:
REQUEST HB_GT_WIN_DEFAULT in PRG code.

Example .PRG :

Code: Select all

#include "HMG.CH"
REQUEST HB_GT_CGI_DEFAULT
STATIC .....
Function MAIN
...... ...
.......
RETURN 
*´¨)
¸.·´¸.·*´¨) ¸.·*¨)
(¸.·´. (¸.·` *
.·`. Harbour/HMG : It's magic !
(¸.·``··*

Saludos / Regards
DaNiElMaXiMiLiAnO

Whatsapp. := +54901169026142
Telegram Name := DaNiElMaXiMiLiAnO
User avatar
Rathinagiri
Posts: 5480
Joined: Tue Jul 29, 2008 6:30 pm
DBs Used: MariaDB, SQLite, SQLCipher and MySQL
Location: Sivakasi, India
Contact:

Re: Just upgraded to 3.0.38, but have problem...

Post by Rathinagiri »

l3whmg wrote:Hi guys,
no one? Well, I find the solution! The problem was harbour libs list. I have copied from hb.hbc all lines inside "# harbour contrib list" and then I can compile and run my program.
But a little question: what is the minimal lib list required by HMG3.0.38? ie I don't use: "crypt", "edit", "editex", "graph", "hfcl", "ini" and "report". In this situation what are the harbour contrib library that I must include (about hmg, obviously).

Many thanks.

Cheers
Hi,

Had you seen hmg.hbc in hmg main folder?
East or West HMG is the Best.
South or North HMG is worth.
...the possibilities are endless.
James
Posts: 7
Joined: Sat Jul 16, 2011 4:05 pm

Re: Just upgraded to 3.0.38, but have problem...

Post by James »

danielmaximiliano wrote:Hi James:
Mrs Rathinagiri Refers:
REQUEST HB_GT_WIN_DEFAULT in PRG code.
Thanks, Daniel, I'm working now! :)
User avatar
l3whmg
Posts: 694
Joined: Mon Feb 23, 2009 8:46 pm
Location: Italy
Contact:

Re: Just upgraded to 3.0.38, but have problem...

Post by l3whmg »

Hello Rathinagiri,

yes I see hmg.hbc, but please pay attention to these personal observations:

A) I dont' use crypt, edit, editex, graph, hfcl, ini and report.
B) On the other hand why I must include (ie) hbmysql and mysql or hbodcb or odbc32, etc.. if I dont' use them?
C) I want to keep clean HMG distribution. I don't want mix with my projects
D) My folders structure it's different and I think everyone can have a different structure.

For these reasons I need to cutomize batch command.

I'm using this structure (note: if I can, I never use primary partition C: on MsWindow system)
  • D:\HMiniGui this is my main work folder for HMG development
    D:\HMiniGui\Harbour (1) this folder contains Harbour and MinGw official distribution (nightly)
    D:\HMiniGui\HMiniGui3 this main folder for HMG 3 version
    D:\HMiniGui\HMiniGui4 this main folder for HMG 4 version
subfolders
  • D:\HMiniGui\HMiniGui3\Hmg official HMG3 distribution. Note I want to keep original and clean
    D:\HMiniGui\HMiniGui3\Dbf projects based upon DBF file
    D:\HMiniGui\HMiniGui3\MySql project based upon MySql DB
    D:\HMiniGui\HMiniGui3\Pogres project based upon PostGres DB
    D:\HMiniGui\HMiniGui3\L3wSys personal libraries and resources used by all HMG3 projects
About D:\HMiniGui\HMiniGui4 the structure is the same

1) I want use the last Harbour/MinGw distribution see note (1) and for this reason I don't use HARBOUR and MINGW distribuited with Hmg
2) I don't use IDE
3) I have problem with hmb.hbc about this line: sources=$(hb_curdir)_temp.o. I receive File not found

For these reasons I must customize build.bat (paths, resources and libraries) and I must change buildlib.bat; both to gain Harbour commands than to gain MinGw commands ( within "D:\HMiniGui\Harbour" subfolders )

These facts are the basis of my question: what is the minimum list of libraries?

Anyway, now I can compile and use HMG3 and compile and link my projects.

Many thanks.

Cheers
Luigi from Italy
www.L3W.it
User avatar
l3whmg
Posts: 694
Joined: Mon Feb 23, 2009 8:46 pm
Location: Italy
Contact:

Re: Just upgraded to 3.0.38, but have problem...

Post by l3whmg »

Hi, please someone can tell me where is located this "ToleAuto():New()" used by h_controlmisc.prg.
I think there are differences between Harbour distribution and HMG-Harbour distribution; ie hbgs.a
Many thanks in advance.
Cheers
Luigi from Italy
www.L3W.it
Post Reply