Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't run CatComp with vamos #212

Open
walkero-gr opened this issue Sep 28, 2024 · 3 comments
Open

Can't run CatComp with vamos #212

walkero-gr opened this issue Sep 28, 2024 · 3 comments

Comments

@walkero-gr
Copy link

I recently started testing vamos for one of my projects, where I need to use catcomp, the tool that manages translation and catalog files.

When I am trying to use it, I get the following error

12:32:09.175        lib:WARNING:  ? CALL: (dos.library)  366 SetVBuf( fh[d1]=00005ac9, buff[d2]=00000000, type[d3]=00000001, size[d4]=00001000 ) from PC=00446c -> d0=0 (default)
12:32:09.191        lib:WARNING:  ? CALL: (dos.library)  366 SetVBuf( fh[d1]=00005ac9, buff[d2]=00000000, type[d3]=00000001, size[d4]=00001000 ) from PC=004fd2 -> d0=0 (default)
12:32:09.194    machine:  ERROR:  ----- ERROR in CPU Run #1 -----
12:32:09.194    machine:  ERROR:  Run: 'CatComp': Initial PC=00215c, SP=0104ac
12:32:09.194    machine:  ERROR:  PC=000111fe  SR=-----    USP=000103a0 ISP=00000700 MSP=00000780
12:32:09.194    machine:  ERROR:  D0=000000df  D1=000000df  D2=000000df  D3=00000001  D4=00000001  D5=00000000  D6=0000000b  D7=0000000c
12:32:09.194    machine:  ERROR:  A0=00010748  A1=00012b20  A2=00012ae0  A3=00000000  A4=00012b20  A5=00010748  A6=0001116c  A7=000103a0
12:32:09.194    machine:  ERROR:  SP-32=000000 SP-28=000000 SP-24=000000 SP-20=000000 SP-16=000000 SP-12=000000 SP-08=000000 SP-04=000000
12:32:09.194    machine:  ERROR:  SP+00=003672 SP+04=000000 SP+08=000001 SP+12=000000 SP+16=000001 SP+20=005ac9 SP+24=016b50 SP+28=012b20
12:32:09.195    machine:  ERROR:  Traceback (most recent call last):
12:32:09.195    machine:  ERROR:    File "src/pytraps.pyx", line 19, in machine68k.trap_wrapper
12:32:09.195    machine:  ERROR:    File "/py-venv/lib/python3.12/site-packages/amitools/vamos/libcore/stub.py", line 207, in base_func
12:32:09.195    machine:  ERROR:      res = method(ctx)
12:32:09.195    machine:  ERROR:            ^^^^^^^^^^^
12:32:09.195    machine:  ERROR:    File "/py-venv/lib/python3.12/site-packages/amitools/vamos/lib/UtilityLibrary.py", line 61, in ToUpper
12:32:09.195    machine:  ERROR:      return ord(chr(a).upper())
12:32:09.195    machine:  ERROR:             ^^^^^^^^^^^^^^^^^^^
12:32:09.195    machine:  ERROR:  TypeError: ord() expected a character, but string of length 2 found
12:32:09.195       main:  ERROR:  vamos failed!
12:32:09.196     libmgr:WARNING:  shutdown: can't expunge 1 amiga libs/devs!
12:32:09.196     libmgr:WARNING:  can't expunge: 'dos.library' with open count 2
12:32:09.196     libmgr:WARNING:  can't expunge: 'utility.library' with open count 2
12:32:09.196     libmgr:WARNING:  shutdown: can't expunge 2 vamos libs/devs!

and here is the full output when I use -l libmgr:info

12:34:13.987     libmgr:   INFO:  libs config:
12:34:13.987     libmgr:   INFO:    default: LibCfg(create_mode=auto, force_version=0, expunge_mode=shutdown, num_fake_funcs=0)
12:34:13.987     libmgr:   INFO:    lib '68030.library': LibCfg(create_mode=off, force_version=0, expunge_mode=shutdown, num_fake_funcs=0)
12:34:13.987     libmgr:   INFO:    lib '68040.library': LibCfg(create_mode=off, force_version=0, expunge_mode=shutdown, num_fake_funcs=0)
12:34:13.987     libmgr:   INFO:    lib '68060.library': LibCfg(create_mode=off, force_version=0, expunge_mode=shutdown, num_fake_funcs=0)
12:34:13.987     libmgr:   INFO:    lib 'dos.library': LibCfg(create_mode=auto, force_version=0, expunge_mode=shutdown, num_fake_funcs=0)
12:34:13.987     libmgr:   INFO:    lib 'graphics.library': LibCfg(create_mode=vamos, force_version=0, expunge_mode=shutdown, num_fake_funcs=0)
12:34:13.988     libmgr:   INFO:    lib 'icon.library': LibCfg(create_mode=auto, force_version=0, expunge_mode=shutdown, num_fake_funcs=0)
12:34:13.988     libmgr:   INFO:    lib 'intuition.library': LibCfg(create_mode=vamos, force_version=0, expunge_mode=shutdown, num_fake_funcs=0)
12:34:13.988     libmgr:   INFO:    lib 'locale.library': LibCfg(create_mode=auto, force_version=0, expunge_mode=shutdown, num_fake_funcs=0)
12:34:13.988     libmgr:   INFO:    lib 'utility.library': LibCfg(create_mode=vamos, force_version=0, expunge_mode=shutdown, num_fake_funcs=0)
12:34:13.988     libmgr:   INFO:  devs config:
12:34:13.988     libmgr:   INFO:    default: LibCfg(create_mode=auto, force_version=0, expunge_mode=shutdown, num_fake_funcs=0)
12:34:13.988     libmgr:   INFO:  opening base libs...
12:34:13.988     libmgr:   INFO:  exec: force version: 0
12:34:13.994     libmgr:   INFO:  open_lib: 'exec.library' ver=0 -> base_name='exec.library'
12:34:13.994     libmgr:   INFO:  -> cfg: LibCfg(create_mode=auto, force_version=0, expunge_mode=shutdown, num_fake_funcs=0)
12:34:13.994     libmgr:   INFO:  vlib: version=0, fake=False
12:34:13.994     libmgr:   INFO:  got vlib: @00133c
12:34:13.995     libmgr:   INFO:  open base lib: exec: @00133c
12:34:13.995     libmgr:   INFO:  open_lib: 'dos.library' ver=0 -> base_name='dos.library'
12:34:13.995     libmgr:   INFO:  -> cfg: LibCfg(create_mode=auto, force_version=0, expunge_mode=shutdown, num_fake_funcs=0)
12:34:13.995     libmgr:   INFO:  vlib: version=0, fake=False
12:34:14.004     libmgr:   INFO:  got vlib: @001ae8
12:34:14.004     libmgr:   INFO:  open base lib: dos:  @001ae8
12:34:14.006     libmgr:   INFO:  current task: Task('CatComp', init_pc=00215c, stack=Stack(lower=0084b4, upper=0104b4, initial_sp=0104ac), start_regs={0: 57, 8: 66740, 2: 32768, 10: 4278312197, 13: 4278312197, 14: 4278312197}, return_regs=[0])
12:34:14.007     libmgr:   INFO:  open_lib: 'dos.library' ver=37 -> base_name='dos.library'
12:34:14.007     libmgr:   INFO:  -> cfg: LibCfg(create_mode=auto, force_version=0, expunge_mode=shutdown, num_fake_funcs=0)
12:34:14.007     libmgr:   INFO:  vlib: version=0, fake=False
12:34:14.007     libmgr:   INFO:  got vlib: @001ae8
12:34:14.007     libmgr:   INFO:  lib 'dos.library' version 40 ok for open version 37
12:34:14.007     libmgr:   INFO:  open_lib: 'utility.library' ver=37 -> base_name='utility.library'
12:34:14.007     libmgr:   INFO:  -> cfg: LibCfg(create_mode=vamos, force_version=0, expunge_mode=shutdown, num_fake_funcs=0)
12:34:14.007     libmgr:   INFO:  vlib: version=0, fake=False
12:34:14.009     libmgr:   INFO:  got vlib: @01116c
12:34:14.009     libmgr:   INFO:  lib 'utility.library' version 40 ok for open version 37
12:34:14.009     libmgr:   INFO:  open_lib: 'iffparse.library' ver=37 -> base_name='iffparse.library'
12:34:14.009     libmgr:   INFO:  -> cfg: LibCfg(create_mode=auto, force_version=0, expunge_mode=shutdown, num_fake_funcs=0)
12:34:14.009     libmgr:   INFO:  vlib: version=0, fake=False
12:34:14.009     libmgr:   INFO:  [native] +open_lib: lib_name='iffparse.library', cwd=Lock('vamos'(ami='root:opt/vamos',sys='/opt/vamos',key=10,ex=0, vol=7732)@002140=b@000850), progdir=Lock('C'(ami='SYS:C',sys='/opt/vamos/amiga-sys-3.2/C',key=11,ex=0, vol=7672)@0084a0=b@002128)
12:34:14.009     libmgr:   INFO:  find: 'iffparse.library' -> None
12:34:14.009     libmgr:   INFO:  loading native lib: 'iffparse.library'
12:34:14.011     libmgr:   INFO:  open_lib: 'dos.library' ver=37 -> base_name='dos.library'
12:34:14.011     libmgr:   INFO:  -> cfg: LibCfg(create_mode=auto, force_version=0, expunge_mode=shutdown, num_fake_funcs=0)
12:34:14.011     libmgr:   INFO:  vlib: version=0, fake=False
12:34:14.011     libmgr:   INFO:  got vlib: @001ae8
12:34:14.011     libmgr:   INFO:  lib 'dos.library' version 40 ok for open version 37
12:34:14.012     libmgr:   INFO:  open_lib: 'utility.library' ver=37 -> base_name='utility.library'
12:34:14.012     libmgr:   INFO:  -> cfg: LibCfg(create_mode=vamos, force_version=0, expunge_mode=shutdown, num_fake_funcs=0)
12:34:14.012     libmgr:   INFO:  vlib: version=0, fake=False
12:34:14.012     libmgr:   INFO:  got vlib: @01116c
12:34:14.012     libmgr:   INFO:  lib 'utility.library' version 40 ok for open version 37
12:34:14.015     libmgr:   INFO:  loaded: @012aa0  seglist: @004489
12:34:14.015     libmgr:   INFO:  loaded: [SegLoad:[SegList:baddr=004489,addr=011224,size=001764],sys=/opt/vamos/amiga-sys-3.2/Libs/iffparse.library,ami=LIBS:iffparse.library]
12:34:14.015     libmgr:   INFO:  loaded FD: 'iffparse.library' -> True
12:34:14.016     libmgr:   INFO:  [native] -open_lib: load_addr=@012aa0, lib_base=@012aa0, ['iffparse.library':load=@012aa0,seglist=004489,addrs=012aa0: 1]
12:34:14.016     libmgr:   INFO:  got alib: @012aa0
12:34:14.017     libmgr:   INFO:  lib 'iffparse.library' version 45 ok for open version 37
12:34:14.018        lib:WARNING:  ? CALL: (dos.library)  366 SetVBuf( fh[d1]=00005ac9, buff[d2]=00000000, type[d3]=00000001, size[d4]=00001000 ) from PC=00446c -> d0=0 (default)
12:34:14.032        lib:WARNING:  ? CALL: (dos.library)  366 SetVBuf( fh[d1]=00005ac9, buff[d2]=00000000, type[d3]=00000001, size[d4]=00001000 ) from PC=004fd2 -> d0=0 (default)
12:34:14.035    machine:  ERROR:  ----- ERROR in CPU Run #1 -----
12:34:14.035    machine:  ERROR:  Run: 'CatComp': Initial PC=00215c, SP=0104ac
12:34:14.035    machine:  ERROR:  PC=000111fe  SR=-----    USP=000103a0 ISP=00000700 MSP=00000780
12:34:14.035    machine:  ERROR:  D0=000000df  D1=000000df  D2=000000df  D3=00000001  D4=00000001  D5=00000000  D6=0000000b  D7=0000000c
12:34:14.035    machine:  ERROR:  A0=00010748  A1=00012b20  A2=00012ae0  A3=00000000  A4=00012b20  A5=00010748  A6=0001116c  A7=000103a0
12:34:14.035    machine:  ERROR:  SP-32=000000 SP-28=000000 SP-24=000000 SP-20=000000 SP-16=000000 SP-12=000000 SP-08=000000 SP-04=000000
12:34:14.035    machine:  ERROR:  SP+00=003672 SP+04=000000 SP+08=000001 SP+12=000000 SP+16=000001 SP+20=005ac9 SP+24=016b50 SP+28=012b20
12:34:14.036    machine:  ERROR:  Traceback (most recent call last):
12:34:14.036    machine:  ERROR:    File "src/pytraps.pyx", line 19, in machine68k.trap_wrapper
12:34:14.036    machine:  ERROR:    File "/py-venv/lib/python3.12/site-packages/amitools/vamos/libcore/stub.py", line 207, in base_func
12:34:14.036    machine:  ERROR:      res = method(ctx)
12:34:14.036    machine:  ERROR:            ^^^^^^^^^^^
12:34:14.036    machine:  ERROR:    File "/py-venv/lib/python3.12/site-packages/amitools/vamos/lib/UtilityLibrary.py", line 61, in ToUpper
12:34:14.036    machine:  ERROR:      return ord(chr(a).upper())
12:34:14.036    machine:  ERROR:             ^^^^^^^^^^^^^^^^^^^
12:34:14.036    machine:  ERROR:  TypeError: ord() expected a character, but string of length 2 found
12:34:14.036     libmgr:   INFO:  current task: None
12:34:14.036       main:  ERROR:  vamos failed!
12:34:14.036     libmgr:   INFO:  closing base libs...
12:34:14.036     libmgr:   INFO:  close_lib: @001ae8
12:34:14.036     libmgr:   INFO:  closed dos
12:34:14.036     libmgr:   INFO:  close_lib: @00133c
12:34:14.037     libmgr:   INFO:  closed exec
12:34:14.037     libmgr:   INFO:  +shutdown
12:34:14.037     libmgr:   INFO:  [native] +expunge_libs
12:34:14.037     libmgr:   INFO:  expunging: ['iffparse.library':load=@012aa0,seglist=004489,addrs=012aa0: 1]
12:34:14.037     libmgr:   INFO:  [native] +expunge_lib: load=@012aa0
12:34:14.037     libmgr:   INFO:  [native] -expunge_lib: seglist=000000, info=['iffparse.library':load=@012aa0,seglist=004489,addrs=]
12:34:14.037     libmgr:   INFO:  [native] -expunge_libs: 1 left
12:34:14.037     libmgr:WARNING:  shutdown: can't expunge 1 amiga libs/devs!
12:34:14.037     libmgr:   INFO:  [vamos] +shutdown
12:34:14.037     libmgr:WARNING:  can't expunge: 'dos.library' with open count 2
12:34:14.037     libmgr:WARNING:  can't expunge: 'utility.library' with open count 2
12:34:14.038     libmgr:   INFO:  [vamos] +shutdown: left libs=2, devs=0
12:34:14.038     libmgr:WARNING:  shutdown: can't expunge 2 vamos libs/devs!
12:34:14.038     libmgr:   INFO:  -shutdwon: aleft=1, vleft=2

Does anyone ever managed to have that working? Is there something I should do with the libraries?
Thank you in advance for your help.

@cnvogelg
Copy link
Owner

Hi,

could you give me an exact command line and the required files so I could reproduce this. I assume there is a small error in the toUpper implementation

@walkero-gr
Copy link
Author

You can find catcomp in the latest NDK3.2 (https://aminet.net/package/dev/misc/NDK3.2), under the tools folder. The command I used was like
catcomp .cd .ct CATALOG .catalog NOOPTIM
That creates a catalog file based on the .cd and .ct files.

@walkero-gr
Copy link
Author

Using the AmigaOS 3.2 utility.library by setting it to use the Amiga version seems to resolve the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants