Viktor,

no, its the other way around, I need to have the full RTL plus the HVM because
my exported (from the .dll) C code calls some .prg code.

Best regards.

Maurilio.


Viktor Szakáts wrote:
> Hi Maurilio,
> 
> Try '-nohblib-' option. It should make the link 
> errors disappear, but I'm not sure if it's enough 
> to reach your final goal.
> 
> Brgds,
> Viktor
> 
> On 2010 Mar 10, at 15:33, Maurilio Longo wrote:
> 
>> Viktor and all,
>>
>> I have a little piece of code I built long ago with xharbour which was
>> producing a win32 .dll which was self-contained and was able to export some
>> function names to make it possible to create .cdx indexes from a program
>> written in another language and which was dinamically loading my .dll.
>>
>> I try to be clearer.
>>
>> mysource.c
>>
>> HB_EXPORT void __stdcall xhb_dbUseArea( BOOL lNewArea,
>>                                        char * cDBE,
>>                                        char * cFileName,
>>                                        char * cAlias,
>>                                        BOOL lShared,
>>                                        BOOL lReadonly ) {
>>
>>   static PHB_DYNS Dyns = NULL;
>>
>>   if ( ! Dyns ) {
>>      Dyns = hb_dynsymFind( "_DBUSEAREA" );
>>   }
>>
>>   if ( Dyns ) {
>>        hb_vmPushDynSym( Dyns );
>>      hb_vmPushNil();
>>      hb_vmPushLogical( lNewArea );
>>      hb_vmPushString( cDBE, strlen( cDBE ) );
>>      hb_vmPushString( cFileName, strlen( cFileName ) );
>>      hb_vmPushString( cAlias, strlen( cAlias ) );
>>      hb_vmPushLogical( lShared );
>>      hb_vmPushLogical( lReadonly );
>>      hb_vmDo( 6 );
>>
>>      return;
>>      }
>> }
>>
>>
>> mysource.prg
>>
>> function _dbUseArea()
>>
>>   does what it's name says, that is it calls
>>   harbour dbUseArea() to open a .dbf file
>> return nil
>>
>>
>> Now, using hbmk2 I'm not able to build my .dll
>>
>> All I get is a long list of unresolved externals.
>>
>> I call it with
>>
>> hbmk2 -st -hbdyn mysource.prg mysource.c
>>
>> I'd expect to have mysource.dll which contains the full harbour RTL+VM so 
>> that
>> the exported xhb_dbUseArea() is able to run.
>>
>> Any idea how I could reach such a goal?
>>
>> I can share the sources, they're not very clean or well thought over, but 
>> were
>> able to work as expected :)
>>
>> Thanks.
>>
>> Maurilio.
>>
>>
>> -- 
>> __________
>> |  |  | |__| Maurilio Longo
>> |_|_|_|____| farmaconsult s.r.l.
>>
>> 
>> _______________________________________________
>> Harbour mailing list (attachment size limit: 40KB)
>> Harbour@harbour-project.org
>> http://lists.harbour-project.org/mailman/listinfo/harbour
> 
> _______________________________________________
> Harbour mailing list (attachment size limit: 40KB)
> Harbour@harbour-project.org
> http://lists.harbour-project.org/mailman/listinfo/harbour
> 

-- 
 __________
|  |  | |__| Maurilio Longo
|_|_|_|____| farmaconsult s.r.l.


_______________________________________________
Harbour mailing list (attachment size limit: 40KB)
Harbour@harbour-project.org
http://lists.harbour-project.org/mailman/listinfo/harbour

Reply via email to