Help trying to build Manic Miner RISC OS from sources
Pages: 1 2
SeñorNueces (1438) 162 posts |
Hi there, I have found this open source version of the great Manic Miner game for RISC OS: http://old-www.moreofthesa.me.uk/progs.source.html However, I am unable to build it. I installed GCC using PACKMAN, along with MAKE, but when trying to build I get: make: * No rule to make target “system.riscos.c.init”, needed by “o.init”. Stop Any help is appreciated, as this version of Manic Miner looks very good and a native 32-bit version would be great! |
Alan Buckley (167) 232 posts |
It looks like the Makefile.r is set up to use the Norcroft tools, not gcc.
type errors by undoing the suffix swapping in Makefile.r |
Steve Pampling (1551) 8170 posts |
the assembler in systems.riscos needs altering to remove the 26bit style function exits as well. First visible item is the “HAT” references in the macros. Moving on there’s some cleanup of the GameModes module and TimPlayer module, unless you have a location for a 32 bit version. At first glance GameModes looks like a simple cleanup. |
Chris Mahoney (1684) 2165 posts |
The makefile also tries to run a tool called “datatoaof”. The only reference I can find to this is from 1992! |
Steve Pampling (1551) 8170 posts |
Doh! Memory span of a goldfish… of course there’s a newer version of TimPlayer Edit: |
SeñorNueces (1438) 162 posts |
@Steve: After replacing TimPlayer and commenting out GameModes, I get Internal error. Data abort at &00008B8C |
Steve Pampling (1551) 8170 posts |
I did say:
and I’m going to guess you’re using a Pi so the following applies:
So a recompile is required, after cleaning up the source. I suspect the only file needing work is ROSupport.s |
SeñorNueces (1438) 162 posts |
@Steve: yes, I am using a Pi. However, ARM assembler is out of my knowledge. Do you know what the changes need to be exactly? I could try applying them and rebuilding for the Pi. |
Jon Abbott (1421) 2651 posts |
I can sort out the assembler for you, if someone knowledgeable on GCC can help you sort out on the C side. Once you’ve figured that one out, we should probably look at Jet Set Willy. |
SeñorNueces (1438) 162 posts |
@Jon: I am more or less familiar with GCC (compiler, linker, etc…) on GNU/Linux, so I may be up to the task with help on the RISC OS side of things (library paths etc). |
Jon Abbott (1421) 2651 posts |
As Steve pointed out previously, you need to edit system.riscos.rosupport/s and search/replace:
However, unless we can find a copy of “datatoaof” you won’t be able to compile it. This utility puts an AOF header around a data file. I’ve search the net for it to no avail, it was possibly on Hensa, but that site went years ago. |
David Pitt (102) 743 posts |
There is a ‘datatoaof’ in the new APDL Library site in b150.zip |
WPB (1391) 352 posts |
I also have something called datatoaof that might be what you’re looking for. Email me if the APDL library link above is no good – |
David Pitt (102) 743 posts |
Entertainingly there is mention of ‘datatoaof’ in DDE26, in DATA2AOF = datatoaof But a mention is all there is! Perhaps this was in the 26bit DDE if one goes back far enough. |
David Pitt (102) 743 posts |
The APDL zip contains |
Rick Murray (539) 13840 posts |
Yup. This is the same obstacle I’m hitting. Got Miner to build (I think) with the DDE – I just put all the files into c or h directories, then created the necessary o directories. Problem is, like you all, without datatoaof the data files aren’t available so the project won’t build. Hmm… I wonder if making the data files under emulation would be acceptable to the linker (as a temporary hack)? If it’s just data, there shouldn’t be any 32 bit issues to worry about. I’m going to bow out for now, new animé season starting so… ☺ |
Chris Mahoney (1684) 2165 posts |
Is a new 32-bit AOF header required, or have there been no changes there? |
Steve Pampling (1551) 8170 posts |
Ye Olde discussion of data in a C project: http://www.verycomputer.com/24_90b3705a7b41335e_1.htm Edit: |
Jeffrey Lee (213) 6048 posts |
There’s a binaof tool in CVS which probably does pretty much the same thing as datatoaof. https://www.riscosopen.org/viewer/view/mixed/RiscOS/Library/Build/binaof%2Cff8 (n.b. you may need to fetch it from a source archive or via CVS directly, I’m not sure if cvsweb has been fixed to not mangle binary files) However if you’re using a recent version of GCC you’ll almost certainly want a tool which produces elf output, or as Steve points out you may want to use the more portable solution of a tool that produces a C file containing a big array. |
David Pitt (102) 743 posts |
I got that on the Titanium, on the RPi3 all I got was a black screen. The game should run in mode 13 or 49 according to its help. They are both 256 colour modes which the Titanium will not handle. I am not too sure why the RPi3 failed. The build was done on OS4.39 VRPC where the game does run. The GameModes module is in ROM. As I recall Select moved legacy modes into a separate module. |
Steve Pampling (1551) 8170 posts |
As Steve pointed out previously, you need to edit system.riscos.rosupport/s and search/replace: Second item addressed by information from Jeffrey, or the Bin2C option if you want to leave your compiler options open. First item: How those are done probably depends on whether people are aiming for a pure 32 bit or a bit agnostic version.
There’s also some machine type detection in there and if you check the warnings from ObjAsm there’s a nice collection of deprecated instructions in the ROSupport assembler. |
Jon Abbott (1421) 2651 posts |
That’s the one..thanks.
The TEQP’s can be ignored, the machine type detection is using OS_PlatformFeatures, so hopefully works. I can’t get it to compile to check though, as my DDE doesn’t seem to contain several includes, namely osargs.h, osfind.h, osgbpb.h, taskmanager.h The deprecated instructions can probably be ignored, it’s the APCS style entry/exits its complaining about which stack R13. There’s also a few deprecated STM’s with PC in them and R14,PC combined. If you really wanted to fix them, you could recode to use LDR/STR for the deprecated registers.
I’m attempting to compile on DDE24 which (going by Elite) may not be fully AAsm32/ARMv7 compatible, so I’m not expecting it to run on Pi3. |
Steve Pampling (1551) 8170 posts |
OSLib |
Rick Murray (539) 13840 posts |
Hmmm… Removed the obvious 26 bit stuff in ROSupport. Also removed most of the findMachineType routine and hardwired it to think that a StrongARM RiscPC was connected (it doesn’t understand anything more recent than that). Now starts, displays the bouncing title. But upon clicking anything it begins to draw the game screen and then bombs out. The backtrace goes back to UpdatePianoKeys, but there’s nothing that looks obvious there. Commenting out the entire function just triggers a cascading error that requires a machine restart; so something is still very wrong. So, for now, I’m going to give up on this. :-( |
Jon Abbott (1421) 2651 posts |
To recompile for ARMv7 compatibility, you need OSLib from SourceForge and make the following changes in MakeFile/r: “Cflags =” needs “-APCS 3/32bit -L22-S22-L41” adding to the end Changes to make within ROsupport: Search/Replace:
Fix the Page Zero access bugs by moving line 841:
Moving down to line 844:
Line 746:
Should read:
Prevent it from corrupting the LinearHandler Workspace pointer: Change lines 1022..1028 from:
to:
Change lines 1218..1220 from:
to:
|
Pages: 1 2