Create FiveH.Lib and FiveHx.Lib from C:\FWH\Source\Classes

Postby anserkk » Thu Oct 16, 2008 11:18 am

Yes Mr.Antonio I agree with you. It was just curious about building the lib for learning purpose. As you rightly said, at this point of time for me it is more easier to modify a class and compile it and link it as part of my application instead of rebuilding the entire library.

I After spending some time trying to solve the problem found the following and sharing it here for Your Information

I find that few prg's and C files inside the source folder is having compilation error and does not produce OBJ equivalent, Which in turn giving UNRESOLVED FUNCTIONS fails while linking OBJ's to lib

List of PRG's having problem
--------------------------------
dbm.Prg
dbms.prg
ddeserv.prg
field.prg
vbxctrl.prg
'_index.prg

Regards

Anser

C:\classes>c:\xharbour\bin\harbour dbm.prg /n /ic:\fwh\include;c:\xharbour\include
xHarbour Compiler build 1.1.0 (SimpLex) (Rev. 6195)
Copyright 1999-2008, http://www.xharbour.org http://www.harbour-project.org/
Compiling 'dbm.prg'...

dbm.prg(38) Error E0030 Syntax error: "syntax error at 'ODICT'"
dbm.prg(51) Error E0030 Syntax error: "syntax error at 'AFIELDS'"

2 errors

No code generated

C:\classes>c:\xharbour\bin\harbour dbms.prg /n /ic:\fwh\include;c:\xharbour\include
xHarbour Compiler build 1.1.0 (SimpLex) (Rev. 6195)
Copyright 1999-2008, http://www.xharbour.org http://www.harbour-project.org/
Compiling 'dbms.prg'...

dbms.prg(29) Warning W0027 Meaningless use of expression: ':'
dbms.prg(29) Warning W0027 Meaningless use of expression: ':'
dbms.prg(30) Warning W0027 Meaningless use of expression: ':'
dbms.prg(30) Warning W0027 Meaningless use of expression: ':'
dbms.prg(38) Error E0030 Syntax error: "syntax error at 'CFILE'"

1 error

No code generated


C:\classes>c:\xharbour\bin\harbour ddeserv.prg /n /ic:\fwh\include;c:\xharbour\include
xHarbour Compiler build 1.1.0 (SimpLex) (Rev. 6195)
Copyright 1999-2008, http://www.xharbour.org http://www.harbour-project.org/
Compiling 'ddeserv.prg'...

ddeserv.prg(11) Error F0029 Can't open #include file: 'DdeFV.ch'


C:\classes>c:\xharbour\bin\harbour field.prg /n /ic:\fwh\include;c:\xharbour\include
xHarbour Compiler build 1.1.0 (SimpLex) (Rev. 6195)
Copyright 1999-2008, http://www.xharbour.org http://www.harbour-project.org/
Compiling 'field.prg'...

field.prg(35) Error E0030 Syntax error: "syntax error at 'CNAME'"
field.prg(36) Error E0030 Syntax error: "syntax error at 'CTYPE'"
field.prg(37) Error E0030 Syntax error: "syntax error at 'NLEN'"
field.prg(38) Error E0030 Syntax error: "syntax error at 'NDEC'"

4 errors

No code generated


C:\classes>c:\xharbour\bin\harbour vbxctrl.prg /n /ic:\fwh\include;c:\xharbour\include
xHarbour Compiler build 1.1.0 (SimpLex) (Rev. 6195)
Copyright 1999-2008, http://www.xharbour.org http://www.harbour-project.org/
Compiling 'vbxctrl.prg'...

vbxctrl.prg(152) Error E0019 #error: 'Method "InitEvents()" not declared in class: TVbControl'

vbxctrl.prg(251) Error E0030 Syntax error: "syntax error at 'BLOCK'"
vbxctrl.prg(252) Error E0030 Syntax error: "syntax error at 'BLOCK'"
vbxctrl.prg(254) Error E0030 Syntax error: "syntax error at 'BLOCK'"
vbxctrl.prg(255) Error E0030 Syntax error: "syntax error at 'BLOCK'"

5 errors

No code generated

C:\classes>c:\xharbour\bin\harbour _index.prg /n /ic:\fwh\include;c:\xharbour\include
xHarbour Compiler build 1.1.0 (SimpLex) (Rev. 6195)
Copyright 1999-2008, http://www.xharbour.org http://www.harbour-project.org/
Compiling '_index.prg'...

_index.prg(24) Error E0030 Syntax error: "syntax error at 'CNAME'"
_index.prg(25) Error E0030 Syntax error: "syntax error at 'CKEY'"
_index.prg(26) Error E0030 Syntax error: "syntax error at 'CFOR'"
_index.prg(27) Error E0030 Syntax error: "syntax error at 'BKEY'"
_index.prg(28) Error E0030 Syntax error: "syntax error at 'BFOR'"
_index.prg(29) Error E0030 Syntax error: "syntax error at 'LUNIQUE'"

6 errors
User avatar
anserkk
 
Posts: 1331
Joined: Fri Jun 13, 2008 11:04 am
Location: Kochi, India

Postby Antonio Linares » Thu Oct 16, 2008 11:37 am

Those files require a modified header (CH) file.

But you will not need them by now :-)
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41366
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Postby Enrico Maria Giordano » Thu Oct 16, 2008 2:05 pm

This is what I use to rebuild FWH library:

Code: Select all  Expand view
@ ECHO OFF

COPY e:\fwharbour\source\function\*.prg
COPY e:\fwharbour\source\winapi\*.prg
COPY e:\fwharbour\source\classes\*.prg

DEL expbuild.prg
DEL db10.prg
DEL odbc32.prg
DEL dbm.prg
DEL vbxctrl.prg
DEL _index.prg
DEL dbms.prg
DEL ddeserv.prg
DEL field.prg
DEL tnewsins.prg
DEL c3.prg

SET HARBOURCMD=/a /es1 /gc0 /l /m /n /q /w
SET INCLUDE=e:\fwharbour\include;e:\xharbour\include
FOR %%i IN (*.prg) DO e:\xharbour\harbour %%i
SET HARBOURCMD=
SET INCLUDE=
IF EXIST *.prg DEL *.prg

FOR %%i IN (*.c) DO e:\bcc55\bin\bcc32 +xharbour.cfg -c %%i
IF EXIST *.c DEL *.c

FOR %%i IN (*.obj) DO e:\bcc55\bin\tlib Fivehx /P32 +%%i
IF EXIST *.obj DEL *.obj
IF EXIST *.bak DEL *.bak

IF EXIST fivehx.lib COPY fivehx.lib e:\fwharbour\lib
IF EXIST fivehx.lib DEL fivehx.lib


XHARBOUR.CFG:

Code: Select all  Expand view
-5
-DHB_FM_STATISTICS_OFF
-DHB_GUI
-DHB_NO_PROFILER
-DHB_NO_TRACE
-DHB_WIN32_IO
-Ie:\fwharbour\include;e:\xharbour\include;e:\bcc55\include
-k-
-O1
-O2
-OS
-Ov
-v-
-W
-w
-w-inl-


EMG
User avatar
Enrico Maria Giordano
 
Posts: 8356
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia

Postby anserkk » Fri Oct 17, 2008 5:14 am

Dear Mr.Enrico

Your solution worked excellently.

I have noticed a single error while executing your solution. But the Lib is getting generated

C Compile error
Borland C++ 5.5.1 for Win32 Copyright (c) 1993, 2000 Borland
ttray.c:
Error E2451 ttray.prg 174: Undefined symbol 'NIF_INFO' in function HB_FUN_GETNOTIFYICONDATA
Error E2451 ttray.prg 175: Undefined symbol 'dwInfoFlags' in function HB_FUN_GETNOTIFYICONDATA
Error E2451 ttray.prg 175: Undefined symbol 'NIIF_INFO' in function HB_FUN_GETNOTIFYICONDATA
Error E2451 ttray.prg 179: Undefined symbol 'szInfo' in function HB_FUN_GETNOTIFYICONDATA
Error E2451 ttray.prg 180: Undefined symbol 'szInfoTitle' in function HB_FUN_GETNOTIFYICONDATA
*** 5 errors in Compile ***


During the execution of TLIB the following warning message is also appearing repeatedly and I assume that it is not a big problem

TLIB Warning
Warning: public '_HB_FUN_MSGGET' in module 'msgget' clashes with prior module 'fwppc'


Prior to your solution, I was trying to compile and link all the available PRG and C programs in the C:\FWH\Source folders, which was the main cause of getting too many errors.

Reading your batch file it is very clear that only the PRG files from the source folders ( C:\FWH\Source\Classes, C:\FWH\Source\Functions, C:\FWH\Source\Winapi ) are required to create FiveHx.Lib file.

Hope there will not be any change in Harbour.CFG (except the Harbour path) to create FiveH.Lib using Harbour

HARBOUR.CFG
-5
-DHB_FM_STATISTICS_OFF
-DHB_GUI
-DHB_NO_PROFILER
-DHB_NO_TRACE
-DHB_WIN32_IO
-Ic:\fwh\include;c:\harbour\include;c:\Borland\bcc55\include
-k-
-O1
-O2
-OS
-Ov
-v-
-W
-w
-w-inl-

Once again thank you very much.

Regards

Anser
User avatar
anserkk
 
Posts: 1331
Joined: Fri Jun 13, 2008 11:04 am
Location: Kochi, India

Previous

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 45 guests