Menu

#53 Error xharbour and Bcc 7.2

v1.0_(example)
closed
nobody
None
1
2020-11-30
2020-09-07
sygecom
No

Error compile xHarbour + Bcc 7.2
Type: C >>>bcc32.exe -o"xbp\arr2str.obj" -c -DHWG_USE_POINTER_ITEM -I"include" -I"d:\devel\xharbour_bcc7\include" "contrib\misc\arr2str.c"<<<

Embarcadero C++ 7.20 for Win32 Copyright (c) 1993-2016 Embarcadero Technologies, Inc.
contrib\misc\arr2str.c:
Error E2451 contrib\misc\arr2str.c 150: Undefined symbol 'HB_LONGLONG' in function WriteArray
Error E2379 contrib\misc\arr2str.c 150: Statement missing ; in function WriteArray
Error E2140 contrib\misc\arr2str.c 152: Declaration is not allowed here in function WriteArray
Error E2140 contrib\misc\arr2str.c 153: Declaration is not allowed here in function WriteArray
Error E2451 contrib\misc\arr2str.c 215: Undefined symbol 'ullVal' in function WriteArray
5 errors in Compile

Discussion

  • Wilfried Brunken

    Hello sygecom,
    that is a problem of xHarbour, we must use compiler switches
    to differ the definitions between Harbour an xHarbour.

    In Harbour, the necessary defintions are written in "hbdefs.h" :

    / Native Harbour types /

    ifndef HB_LONG_LONG_OFF

    #if defined( HB_OS_WIN ) && ! defined( GNUC )
    typedef __int64 HB_LONGLONG;
    typedef unsigned __int64 HB_ULONGLONG;
    #else
    typedef signed long long HB_LONGLONG;
    typedef unsigned long long HB_ULONGLONG;
    #endif

    ....
    In xHarbour, these defintions are only defined as LONGLONG and ULONGLONG and so on.

    Use of:

    if defined(XHARBOUR)

    ...

    else

    ...

    endif

    Compile output on Ubuntu LINUX 16.04 LTS:
    ~/hwgui/contrib$ ./build.sh
    gcc -Wall -O3 -c -I../include -I/home/cltest/Harbour/core-master/include -o obj/arr2str.o misc/arr2str.c
    ar rc ../lib/libhwg_misc.a obj/arr2str.o obj/blowfish.o obj/miscfunc.o obj/richtext.o obj/saymoney.o

    I posted here a modified source file of arr2str.c as a first suggestion.
    Exchange it with your local copy of HWGUI installation and try to compile and test again.

    I need some time to install a full environment with xHarbour and BCC, so
    i think, this is the fastest solution to solve your problem.

    Please give feedback, if you have success. If it is necessary to make more modifications,
    please post the corrected file with this ticket.

    So i will commit it into the source repository afterwards.

    With regards
    MNI TNX, 73 es 55 de
    DF7BE, Wilfried

     
  • sygecom

    sygecom - 2020-09-16

    Thank you.
    It worked.

     
  • Wilfried Brunken

    Hello sygecom,
    Committed with r2883.

    MNI TNX for your support.

    To Alexander Kresin: Please close this ticket.

    With regards,
    MNI TNX, 73 es 55 de
    DF7BE, Wilfried

     
  • Maurizio la Cecilia

    • status: open --> closed
     

Log in to post a comment.