HBMK2 Problem linking

User avatar
nageswaragunupudi
Posts: 8017
Joined: Sun Nov 19, 2006 5:22 am
Location: India
Contact:

Re: Editsource() Problem

Post by nageswaragunupudi »

Thanks. I am able to build the exe now.
Yes, there is a problem.
How this linking affects the logic inside the fwh lib is puzzling.
Let me see.
Regards

G. N. Rao.
Hyderabad, India
User avatar
ricbarraes
Posts: 49
Joined: Tue Jun 30, 2015 2:26 am
Location: Brazil

Re: Editsource() Problem

Post by ricbarraes »

Ok, thank you!

Let us know if you need help or anything :D
Sds,
Ricardo Arraes
ricardo@vfatec.com.br
User avatar
nageswaragunupudi
Posts: 8017
Joined: Sun Nov 19, 2006 5:22 am
Location: India
Contact:

Re: Editsource() Problem

Post by nageswaragunupudi »

Please build this small program with buildh.bat and hbmk2 and see the difference.

Code: Select all

#include "fivewin.ch"

function Main()

   local oCn, oRs
   local cSql, nAt := 0

   cSql  := "SELECT * FROM states AS st ORDER BY code LIMIT 5"
   HB_AtX( " ORDER BY | HAVING | LIMIT | GROUP ", cSql, .f., @nAt )
   ? nAt, cSql, SubStr( cSql, nAt )

 
return nil
 
In our library, we are depending on HB_AtX(...).
This Harbour function is returning different values with buildh.bat and hbmk2.
Please test and confirm.
Regards

G. N. Rao.
Hyderabad, India
User avatar
ricbarraes
Posts: 49
Joined: Tue Jun 30, 2015 2:26 am
Location: Brazil

Re: Editsource() Problem

Post by ricbarraes »

Ok, we are testing it right now, just a moment
Sds,
Ricardo Arraes
ricardo@vfatec.com.br
User avatar
vilian
Posts: 795
Joined: Wed Nov 09, 2005 2:17 am
Location: Brazil
Contact:

Re: Editsource() Problem

Post by vilian »

Yes, you are right. The exe generated with HBMK2 is returning 0(Zero) to nAt.
Sds,
Vilian F. Arraes
vilian@vfatec.com.br
Belém-Pa-Brazil
User avatar
nageswaragunupudi
Posts: 8017
Joined: Sun Nov 19, 2006 5:22 am
Location: India
Contact:

Re: Editsource() Problem

Post by nageswaragunupudi »

We request the hbmk2 experts to please see the hbp script and advise corrections to resolve this issue.
Regards

G. N. Rao.
Hyderabad, India
User avatar
vilian
Posts: 795
Joined: Wed Nov 09, 2005 2:17 am
Location: Brazil
Contact:

Re: Editsource() Problem

Post by vilian »

Do you know where is HB_AtX() function ? which .lib ?
Sds,
Vilian F. Arraes
vilian@vfatec.com.br
Belém-Pa-Brazil
User avatar
cnavarro
Posts: 5792
Joined: Wed Feb 15, 2012 8:25 pm
Location: España

Re: Editsource() Problem

Post by cnavarro »

C. Navarro
Hay dos tipos de personas: las que te hacen perder el tiempo y las que te hacen perder la noción del tiempo
Si alguien te dice que algo no se puede hacer, recuerda que esta hablando de sus limitaciones, no de las tuyas.
User avatar
vilian
Posts: 795
Joined: Wed Nov 09, 2005 2:17 am
Location: Brazil
Contact:

Re: Editsource() Problem

Post by vilian »

Thank you,
It's a really nice page!
Sds,
Vilian F. Arraes
vilian@vfatec.com.br
Belém-Pa-Brazil
User avatar
ricbarraes
Posts: 49
Joined: Tue Jun 30, 2015 2:26 am
Location: Brazil

Re: Editsource() Problem

Post by ricbarraes »

thank you, it helped us to track the function.

but it seems to be inside some core Harbour library:

# Function Library
935) hb_AtX harbour

so we don't know for sure how to access this lib, or even if it's accessible for us.

Could help us finding it?
Sds,
Ricardo Arraes
ricardo@vfatec.com.br
User avatar
nageswaragunupudi
Posts: 8017
Joined: Sun Nov 19, 2006 5:22 am
Location: India
Contact:

Re: Editsource() Problem

Post by nageswaragunupudi »

HB_AtX() is in hbrtl.lib.

HB_AtX() function is a regex function. While building with hbmk2 using the above script, some dummy function is being linked instead of the correct function.

It is possible to replace HB_AtX() in this particular case with a suitable FWH function like AAT() or FW_AT().

But we still do not know what other functions, particularly regex functions our FWH library will fail resulting in wrong behaviour. And you will all be complaining that it is a problem with our FWH library.

We can prove the functionality with buildh.bat.

I do not know hbmk2. You need to first consult experts and come out with a reliable hbp script. Till then, it is difficult for me to provide support if the application is built with hbmk2.

The caption "EditSource() problem" is misleading. There is no problem at all with EditSource. Please consider changing the title.
Regards

G. N. Rao.
Hyderabad, India
User avatar
ricbarraes
Posts: 49
Joined: Tue Jun 30, 2015 2:26 am
Location: Brazil

Re: Editsource() Problem

Post by ricbarraes »

Ok, I'll ask Vilian to change the title for a more specific now that everything is well understood.

Thank you guys for the support, we'll try to change that function but we are kinda concerned about the rest of our code

we didn't even know that hbmk2 has no relation to fivewin, in fact we thought it was an update over buildh...

Do you know anyone with more ackowledge about the hbmk2 that could help us with our hbp?

we are frequently visiting this website to get information about the hbmk2, but we couldn't recognize any parameter related to this issue

https://github.com/harbour/core/blob/ma ... bmk2.en.md

let's wait for some hbmk2 expert to show up...

thank you again
Sds,
Ricardo Arraes
ricardo@vfatec.com.br
User avatar
nageswaragunupudi
Posts: 8017
Joined: Sun Nov 19, 2006 5:22 am
Location: India
Contact:

Re: Editsource() Problem

Post by nageswaragunupudi »

Another sample.
Try with both buildh.bat and hbmk2.exe and see the difference.

Code: Select all

#include "fivewin.ch"

function Main()

   local cSql, aMatch

   cSql  := "SELECT * FROM customer WHERE AGE BETWEEN 50 AND 60 OR STATE = 'NY'"
   aMatch := hb_regex( "[a-z|0-9|_`]* between .* and ['|a-z|0-9|&|?|:]*", cSql, .f. )
   if aMatch == nil
      ? "function returned nil. It should return array"
   elseif Empty( aMatch )
      ? "function returns empty array"
   else
      ? "result:", aMatch[ 1 ]
   endif

return nil
 
This being the case it is not safe for you to build your release software with hbmk2 till you get expert guidance.
Regards

G. N. Rao.
Hyderabad, India
User avatar
Antonio Linares
Site Admin
Posts: 37481
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain
Contact:

Re: Editsource() Problem

Post by Antonio Linares »

Please try to remove hbwin and -mt from the hbp file and let us know what you get
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
nageswaragunupudi
Posts: 8017
Joined: Sun Nov 19, 2006 5:22 am
Location: India
Contact:

Re: Editsource() Problem

Post by nageswaragunupudi »

1. removing -mt made no difference.

2. removing -hbwin resulted in unresolved errors.

Code: Select all

hbmk2: Error: Referenced, missing, but unknown function(s): WIN_OLEERRORTEXT(),
       WIN_OLEAUTO(), __OLEINVOKEMETHOD(), __OLEINVOKEPUT(), __OLEINVOKEGET(),
       WIN_OLEERROR(), __OLEISDISP(), __OLECREATEOBJECT(), WIN_P2N(),
       __OLEGETACTIVEOBJECT(), WAPI_MESSAGEBOX(), __OLEVARIANTNEW(),
       WIN_OSVERSIONINFO(), WIN_OSISNT(), WIN_OSISNT351(), WIN_OSISNT4(),
       WIN_OSIS2000ORUPPER(), WIN_OSIS2000(), WIN_OSISXP(),
       WIN_OSISWINXPORUPPER(), WIN_OSIS2003(), WIN_OSISVISTA(),
       WIN_OSISVISTAORUPPER(), WIN_OSIS7(), WIN_OSIS8(), WIN_OSIS9X(),
       WIN_OSIS95(), WIN_OSIS98(), WIN_OSISME(), WIN_OSISTSCLIENT(),
       WIN_OSNETREGOK(), WIN_OSNETVREDIROK(), WIN_ANSITOWIDE(),
       WIN_WIDETOANSI(), WIN_AXINIT(), WAPI_CREATEWINDOWEX(),
       WIN_AXGETCONTROL(), WAPI_OUTPUTDEBUGSTRING()
 
Regards

G. N. Rao.
Hyderabad, India
Post Reply