VBCC linking issue
  • Order of the Butterfly
    Order of the Butterfly
    Minuous
    Posts: 161 from 2010/2/13
    Hello all, I have installed VBCC on Windows and am using it to cross-compile OS4 and MorphOS versions of my programs. It works fine for producing OS4 binaries, but at the linking stage for MOS binaries it gives lots of "Reference to undefined symbol NewList" and similar errors. Is the MOS VBCC target not configured to use amiga.lib by default?
  • »21.08.22 - 15:50
    Profile Visit Website
  • MorphOS Developer
    Piru
    Posts: 587 from 2003/2/24
    From: finland, the l...
    I'm sure it's also possible to get VBCC working, but I have no clue how that could be done. The best MorphOS cross-compiling results come by using GCC and the "official" SDK .deb from from bigfoot.

    If you really want to use Windows you can do the following:

    1. Install Windows Subsystem for Linux from: https://aka.ms/wslinstall

    2. Install Debian from Windows app store: https://www.microsoft.com/store/apps/9MSVKQC78PK6

    3. Install wget to the fresh Debian: sudo apt-get update && sudo apt-get install wget

    4. Download the SDK .deb provided by bigfoot and apt-get install it as described
  • »21.08.22 - 21:25
    Profile
  • Order of the Butterfly
    Order of the Butterfly
    Minuous
    Posts: 161 from 2010/2/13
    It's Windows 8.1 so that suggestion won't work.
  • »22.08.22 - 05:31
    Profile Visit Website
  • Priest of the Order of the Butterfly
    Priest of the Order of the Butterfly
    polluks
    Posts: 800 from 2007/10/23
    From: Gelsenkirchen,...
    I cannot see any reference to amiga.lib for +morphos
    Code:
    -ld=vlink -belf32morphos -Cvbccelf -P__amigappc__ -P__abox__ -nostdlib $VBCC/targets/ppc-morphos/lib/startup.o %s %s -L$VBCC/targets/ppc-morphos/lib -lvc -o %s
    -l2=vlink -belf32morphos -Cvbccelf -P__amigappc__ -P__abox__ -nostdlib %s %s -L$VBCC/targets/ppc-morphos/lib -o %s
    -ldv=vlink -belf32morphos -Cvbccelf -t -P__amigappc__ -P__abox__ -nostdlib $VBCC/targets/ppc-morphos/lib/startup.o %s %s -L$VBCC/targets/ppc-morphos/lib -lvc -o %s
    -l2v=vlink -belf32morphos -Cvbccelf -t -P__amigappc__ -P__abox__ -nostdlib %s %s -L$VBCC/targets/ppc-morphos/lib -o %s

    for example
    Pegasos II G4: MorphOS 3.9, Zalman M220W · iMac G5 12,1 17", MorphOS 3.18
    Power Mac G3: OSX 10.3 · PowerBook 5,8: OSX 10.5, MorphOS 3.18
  • »22.08.22 - 10:22
    Profile
  • Order of the Butterfly
    Order of the Butterfly
    Samurai_Crow
    Posts: 161 from 2009/12/10
    From: Minnesota, USA
    Quote:

    Minuous wrote:
    Hello all, I have installed VBCC on Windows and am using it to cross-compile OS4 and MorphOS versions of my programs. It works fine for producing OS4 binaries, but at the linking stage for MOS binaries it gives lots of "Reference to undefined symbol NewList" and similar errors. Is the MOS VBCC target not configured to use amiga.lib by default?


    No. ABox is the name of MorphOS' link library bindings. Amiga.lib is only for versions of AmigaOS. MorphOS has no access to the trademark "Amiga" name including the link library.
  • »27.08.22 - 22:52
    Profile
  • Priest of the Order of the Butterfly
    Priest of the Order of the Butterfly
    polluks
    Posts: 800 from 2007/10/23
    From: Gelsenkirchen,...
    Quote:

    Samurai_Crow schrieb:
    No. ABox is the name of MorphOS' link library bindings. Amiga.lib is only for versions of AmigaOS. MorphOS has no access to the trademark "Amiga" name including the link library.

    Nice story, but it's not true for VBCC:
    Code:
    > search vbcc:targets/ppc-morphos/lib/ newlist quiet
    System Backup:vbcc/targets/ppc-morphos/lib/libGLs.a
    System Backup:vbcc/targets/ppc-morphos/lib/libGL.a
    System Backup:vbcc/targets/ppc-morphos/lib/libamigas.a
    System Backup:vbcc/targets/ppc-morphos/lib/libamiga.a


    [ Editiert durch polluks 31.08.2022 - 08:30 ]
    Pegasos II G4: MorphOS 3.9, Zalman M220W · iMac G5 12,1 17", MorphOS 3.18
    Power Mac G3: OSX 10.3 · PowerBook 5,8: OSX 10.5, MorphOS 3.18
  • »30.08.22 - 19:59
    Profile
  • MorphOS Developer
    cyfm
    Posts: 537 from 2003/4/11
    From: Germany
    Quote:

    polluks schrieb:
    Quote:

    Samurai_Crow schrieb:
    No. ABox is the name of MorphOS' link library bindings. Amiga.lib is only for versions of AmigaOS. MorphOS has no access to the trademark "Amiga" name including the link library.

    Nice story, but it's not true:
    Code:
    > search vbcc:targets/ppc-morphos/lib/ newlist quiet
    System Backup:vbcc/targets/ppc-morphos/lib/libGLs.a
    System Backup:vbcc/targets/ppc-morphos/lib/libGL.a
    System Backup:vbcc/targets/ppc-morphos/lib/libamigas.a
    System Backup:vbcc/targets/ppc-morphos/lib/libamiga.a



    What is still true, though, is that MorphOS SDK indeed uses libabox.a as well as libaboxstubs.a which is obviously a API compatible version replicating functions used in the original amiga.lib

    What vbcc does is not within our scope and the vbcc author supplying the link libs can basically name his libs whatever he likes to do ..
  • »30.08.22 - 23:12
    Profile Visit Website