WIP Atari ST ScummVM-lite

Our top picks of ST games!
Locked
User avatar
thorsten.otto
Posts: 148
Joined: Mon Nov 04, 2019 2:20 am

Re: WIP Atari ST ScummVM-lite

Post by thorsten.otto »

stephen_usher wrote: Tue Apr 21, 2020 11:54 am OK, weird... When I try to look at the flags using the CPX I usually use all the flag options are greyed out.
I would bet that is either because you are running a system that does not support Alt-Ram (unlikely since it is supported since tos 1.04 or so), or you just don't have Alt-RAM installed. I would consider that a bug of the CPX not being able to change the flags in this case. You should try a different program, there should be plenty of them.
User avatar
exxos
Site Admin
Site Admin
Posts: 23717
Joined: Wed Aug 16, 2017 11:19 pm
Location: UK
Contact:

Re: WIP Atari ST ScummVM-lite

Post by exxos »

thorsten.otto wrote: Tue Apr 21, 2020 12:19 pm
stephen_usher wrote: Tue Apr 21, 2020 11:54 am OK, weird... When I try to look at the flags using the CPX I usually use all the flag options are greyed out.
I would bet that is either because you are running a system that does not support Alt-Ram (unlikely since it is supported since tos 1.04 or so), or you just don't have Alt-RAM installed. I would consider that a bug of the CPX not being able to change the flags in this case. You should try a different program, there should be plenty of them.
This is how its normally done...

https://www.exxosforum.co.uk/forum/viewt ... t=54&p=106
https://www.exxosforum.co.uk/atari/ All my hardware guides - mods - games - STOS
https://www.exxosforum.co.uk/atari/store2/ - All my hardware mods for sale - Please help support by making a purchase.
viewtopic.php?f=17&t=1585 Have you done the Mandatory Fixes ?
Just because a lot of people agree on something, doesn't make it a fact. ~exxos ~
People should find solutions to problems, not find problems with solutions.
User avatar
stephen_usher
Posts: 5660
Joined: Mon Nov 13, 2017 7:19 pm
Location: Oxford, UK.
Contact:

Re: WIP Atari ST ScummVM-lite

Post by stephen_usher »

thorsten.otto wrote: Tue Apr 21, 2020 12:19 pm
stephen_usher wrote: Tue Apr 21, 2020 11:54 am OK, weird... When I try to look at the flags using the CPX I usually use all the flag options are greyed out.
I would bet that is either because you are running a system that does not support Alt-Ram (unlikely since it is supported since tos 1.04 or so), or you just don't have Alt-RAM installed. I would consider that a bug of the CPX not being able to change the flags in this case. You should try a different program, there should be plenty of them.
It works on all other programs other than those created before the flags were defined (i.e. after TOS 1.04 was released).

This is a TT with 64MB of TT-RAM.
Intro retro computers since before they were retro...
ZX81->Spectrum->Memotech MTX->Sinclair QL->520STM->BBC Micro->TT030->PCs & Sun Workstations.
Added code to the MiNT kernel (still there the last time I checked) + put together MiNTOS.
Collection now with added Macs, Amigas, Suns and Acorns.
User avatar
agranlund
Posts: 789
Joined: Sun Aug 18, 2019 10:43 pm
Location: Sweden
Contact:

Re: WIP Atari ST ScummVM-lite

Post by agranlund »

stephen_usher wrote: Tue Apr 21, 2020 1:04 pm
thorsten.otto wrote: Tue Apr 21, 2020 12:19 pm I would bet that is either because you are running a system that does not support Alt-Ram (unlikely since it is supported since tos 1.04 or so), or you just don't have Alt-RAM installed. I would consider that a bug of the CPX not being able to change the flags in this case. You should try a different program, there should be plenty of them.
It works on all other programs other than those created before the flags were defined (i.e. after TOS 1.04 was released).
This is a TT with 64MB of TT-RAM.
I think that perhaps that CPX is not able to understand the header of gcc binaries correctly?

I downloaded the same CPX you're using and get the same result on my machine - the flags are grayed out and cannot be changed.
However, I tried 3 other flag-setting programs and they all behave correctly and shows that the program is built to use TT-RAM by default (and they let me modify the flags to prevent usage of TTRAM if I want to).

It's probably trying to be clever and looks at something in the executable to determine if it should gray out these flags or not - it doesn't gray out those options for programs which I've built in Devpac3 on the Atari itself, I think its just relying on something it knows about from compilers that were around when that CPX was made back in 1992.
User avatar
thorsten.otto
Posts: 148
Joined: Mon Nov 04, 2019 2:20 am

Re: WIP Atari ST ScummVM-lite

Post by thorsten.otto »

agranlund wrote: Tue Apr 21, 2020 2:00 pm I think that perhaps that CPX is not able to understand the header of the gcc binaries correctly?
gcc binaries have a standard GEMDOS header, and the program flags are part of it. Otherwise, they would not be used by TOS when you run a program ;)
User avatar
agranlund
Posts: 789
Joined: Sun Aug 18, 2019 10:43 pm
Location: Sweden
Contact:

Re: WIP Atari ST ScummVM-lite

Post by agranlund »

thorsten.otto wrote: Tue Apr 21, 2020 2:07 pm
agranlund wrote: Tue Apr 21, 2020 2:00 pm I think that perhaps that CPX is not able to understand the header of the gcc binaries correctly?
gcc binaries have a standard GEMDOS header, and the program flags are part of it. Otherwise, they would not be used by TOS when you run a program ;)
Yeah, I think that CPX is probably just trying to be too clever for it's own good and probably looks at something it expects to be in executables, else it grays out those options. Based on its knowledge from compilers back in 1992 when the CPX was made.
That's my only guess. TOS appears to load the program into TTRAM though so I wouldn't worry about what that CPX does :)
User avatar
agranlund
Posts: 789
Joined: Sun Aug 18, 2019 10:43 pm
Location: Sweden
Contact:

Re: WIP Atari ST ScummVM-lite

Post by agranlund »

thorsten.otto wrote: Tue Apr 21, 2020 2:07 pm
agranlund wrote: Tue Apr 21, 2020 2:00 pm I think that perhaps that CPX is not able to understand the header of the gcc binaries correctly?
gcc binaries have a standard GEMDOS header, and the program flags are part of it. Otherwise, they would not be used by TOS when you run a program ;)
Mystery solved!
That gcc tacks on some extended header stuff for Mint and this was probably what threw it off. I found a utility to strip all that and now it displays the TTRAM settings correctly in that flag-setter CPX.

Managed to shrink the executable from 630Kb to 430Kb in the process as it got rid of some symbols(?) that were apparently still left in there.
Good find Stephen, thank you! :)

Edit: Ah I see that program was written by you Thorsten, thank you for stripx!
User avatar
stephen_usher
Posts: 5660
Joined: Mon Nov 13, 2017 7:19 pm
Location: Oxford, UK.
Contact:

Re: WIP Atari ST ScummVM-lite

Post by stephen_usher »

:)
I'm glad the mystery's solved (and the executable's smaller). :thumbup:
Intro retro computers since before they were retro...
ZX81->Spectrum->Memotech MTX->Sinclair QL->520STM->BBC Micro->TT030->PCs & Sun Workstations.
Added code to the MiNT kernel (still there the last time I checked) + put together MiNTOS.
Collection now with added Macs, Amigas, Suns and Acorns.
User avatar
thorsten.otto
Posts: 148
Joined: Mon Nov 04, 2019 2:20 am

Re: WIP Atari ST ScummVM-lite

Post by thorsten.otto »

agranlund wrote: Tue Apr 21, 2020 2:52 pm Edit: Ah I see that program was written by you Thorsten, thank you for stripx!
Yes, this was mainly intended to strip CPX modules and SLB libraries, the former to save a few bytes, the latter because SLBs require the SLB header information to be immediately after the GEMDOS header (at least in MagiC, MiNT has some extra code to recognize executable build by gcc).

Alas, that CPX module still seems to be broken if it can't handle gcc binaries.
User avatar
stephen_usher
Posts: 5660
Joined: Mon Nov 13, 2017 7:19 pm
Location: Oxford, UK.
Contact:

Re: WIP Atari ST ScummVM-lite

Post by stephen_usher »

thorsten.otto wrote: Tue Apr 21, 2020 4:30 pm [Alas, that CPX module still seems to be broken if it can't handle gcc binaries.
It was developed and released when GCC was still in its infancy. It works/ed fine with the early 90s versions of the linker GCC tool chain and the early MiNTlibs.

Anyway, this is getting *way* off topic.
Intro retro computers since before they were retro...
ZX81->Spectrum->Memotech MTX->Sinclair QL->520STM->BBC Micro->TT030->PCs & Sun Workstations.
Added code to the MiNT kernel (still there the last time I checked) + put together MiNTOS.
Collection now with added Macs, Amigas, Suns and Acorns.
Locked

Return to “GAME ZONE”