#assembly ARM64 Doom

367 messages · Page 1 of 1 (latest)

brave cape
#

Hello guys I have a tremendous task
I'm wanting to write in assembly,c,c++ I'm trying to get the videogame doom from 1996 to work on my phone which is arm64 aarch64 assembly I'm using termux as a Linux system on my phone recently I found a repo for doom Linux and I cloned it and it just doesn't want to work with the make file and also the games source code was not written in arm64 aarch64 assembly it was 16bit or x86 which doesn't work with ARM64 aarch64 I've done a bit of research and found that the architecture can be ported and an easier method using a cross compiler and my goals are to get the game assembled and compiled to run on my phone and test it out a bit then I'm wanting to make a WAD mod for the game and also add multiplayer and I found something using kubernetti to get it to work can someone help me please

rough micaBOT
#

When your question is answered use !solved to mark the question as resolved.

Remember to ask specific questions, provide necessary details, and reduce your question to its simplest form. For tips on how to ask a good question use !howto ask.

brave cape
brave cape
#

I'm not good at communicating

iron forum
brave cape
#

cross assembler x86 to Aarch64

#

Parts of it is assembly

#

Most of it is .c and .h

iron forum
#

you're doing this on a phone?

#

as in, you're going to write an entire cross assembler and interface with all the tools on a phone?

brave cape
#

What ever to do to get doom working compiled and assembled then ran

iron forum
#

I can't understand what you're saying

brave cape
#

Don't you understand

iron forum
#

very sorry

brave cape
#

I have to go-to hell

#

What don't u understand

#

@iron forum

#

Let's take it step by step

iron forum
brave cape
#

Git clone repo done
Trying to get it compile not working
Requires converting dooms source assembly into ARM64
Should compile and run maybe requires cross assembly to convert

brave cape
#

@iron forum

iron forum
brave cape
#

I have perfect English if not better

#

Chatgpt?

iron forum
#

GPT isn't going to write an entire x86->AArch64 cross assembler.

brave cape
#

Porting?

iron forum
brave cape
#

I'm using vim

iron forum
#

on a phone?

brave cape
#

Yes

iron forum
#

well good luck with that

brave cape
#

In termux

iron forum
#

a phone is an incredibly unfit environment to be writing code

brave cape
#

To some people that's more important

iron forum
#

no, it's not.

#

if you're on android why not build remotely in android studio?

#

you can debug remotely too

brave cape
#

Dude

#

You can do that on phone too

iron forum
#

android studio doesn't run on a phone

brave cape
#

Aka memory viewer

#

It can be done on phone

iron forum
#

what does viewing memory have to do with developing and debugging

brave cape
#

I'm not interested in android studio

iron forum
#

so why are you developing on a phone?

#

it's by no means better

brave cape
#

Bro just leave me alone if your not gonna help

iron forum
#

I am helping you, you're the one who keeps denying it and throwing bullshit comebacks at me.

#

I'm telling you that a phone is a very unfit environment to write, debug, and test code on.

#

And that since you're on android you can make use of tools to remotely compile and debug software on a desktop.

#

At this point you're trolling.

cinder pelican
#

not trolling, just unwilling or unable to change I would guess

#

but also baically any computer will better than a phone

iron forum
#

^^

brave cape
#

Phones are practically like computer

iron forum
#

Yeah, screw it

cinder pelican
#

the problem is screen real-estate

#

they're too small

brave cape
#

Dude I'm gonna block u

mossy moat
#

don't ping/mention me to help. i'm with Veelox and skull::king here

iron forum
#

All I'm gonna say is try to write, debug, and test a whole cross-assembler between two distinct architectures on a mobile phone.

brave cape
cinder pelican
# brave cape Phones are practically like computer

you can only see like 5 lines on a phone. On a computer you can see the entire lenght of the line and you can see more lines (like 20-40) and you keyboard doesn't take up half the screen and you have better control over where you are typing

Also there is better tooling for basically any computer (since at minimum you can run linux)

#

this is quite a complex task btw

iron forum
#

extremely

cinder pelican
#

it doesn't just port. They're completely different architectures

#

and especially games struggle

#

because they often rely on specific timings, which can be thrown off when changing

iron forum
#

and even the assembly has different semantics, what you do in x86 could be a mess to do in ARM and vice versa

cinder pelican
#

There is a reason we still use emulators for old games, and don't just port the assembly

iron forum
#

definitely sure doom is on android anyway

#

natively,

cinder pelican
#

doom is different. YOu have the source code, you could compile it for any architeecture you want, you don't need to go via the assembly

#

its written in c

iron forum
#

exactly^^, I don't see why this needs assembly it wasn't even written in assembly

brave cape
cinder pelican
#

yes this is the source code

brave cape
#

Specifically

cinder pelican
brave cape
#

Change doom from it's arch to arrch64

cinder pelican
#

its talking about something completely unrelated

brave cape
#

Read it

cinder pelican
#

doom doesn't run in the cloud like what

brave cape
#

Is doom x86 or 16bit

iron forum
#

this seems incredibly advanced and barely related

iron forum
brave cape
#

Yo man u don't know me

cinder pelican
iron forum
#

now obviously, doom is a cloud computing task split across multiple machines.

cinder pelican
#

pretty cross platform c I would guess

#

since its been running on machines for literally decades

iron forum
#

the barrier is pretty low

brave cape
#

I don't like adrenaline

cinder pelican
#

you can run doom on a fridge

#

it has been ported to a lot of embedded devices

#

which often are not x86

cinder pelican
#

regardless its definitely been ported to android already if thats what you want

brave cape
#

No

cinder pelican
#

what do you mean no?

iron forum
#

at this point I'd give up, the information is not getting across to the point of defiance

#

I'm bailing, good luck

brave cape
#

Aarch64 source code run on termux and compile and assemble and run

#

Mm yeah fuk off

cinder pelican
#

like

brave cape
#

Convert

cinder pelican
#

what do you actually want to do

#

lets start from the beginning

#

what is your aim

brave cape
#

I don't want to elaborate

cinder pelican
#

how can I help if I don't know what you want to do?

brave cape
#

But I'll tell u the steps

#

First clone doom and assemble and compile an run all in termux which is like linux

#

I write c and assembly

#

What to do with the README.asm

#

What's that

#

It's at the bottom of the repo

#

@cinder pelican

#

The later after the game works

#

I want to make WADS

#

like mods

cinder pelican
#

it tells you want it does

brave cape
#

I've read it

cinder pelican
#

what confuses you then?

brave cape
#

Do make o file

#

Of doomdef.c

#

Or use make

#

Make don't work

#

Make isn't working

#

Probably cuz it's different arch

cinder pelican
#

make would likely work if that folder existed

#

does the linux folder exist?

brave cape
#

Makefile

cinder pelican
#

try making that folder

brave cape
#

Bro I want to hurry up and go-to hell

#

To take over hell

#

He's a Duke in hell

#

@cinder pelican

cinder pelican
#

do you own doom btw?

#

because you can't actually run this without a doom copy anyway

#

it doesn't have any of the assets

#

its just the code

brave cape
#

Oh

cinder pelican
# brave cape

you should try making a linux folder wherever you are calling make from

brave cape
#

Thought that

#

Um

cinder pelican
#

its in the readme

brave cape
#

I want final doom for PlayStation version

#

Can use anything for the data

#

Like custom made

#

?

cinder pelican
#

make inside the linux source folder wants a relative folder called linux for it to write the output files into

#

which would not be here

cinder pelican
brave cape
#

5down far left

cinder pelican
#

also suggest you check out https://zdoom.org/index which is an existing port of doom to modern hardware, maybe they already have a playstation version

brave cape
#

Is make

#

Move Makefile to Linux directory

cinder pelican
#

no thats not what I said

#

you know how you said you write c and assembly, Im starting to think thats not true

#

Since you don't seem to understand build systems

brave cape
#

I have cancer

#

As and ls

#

There what I want

#

In compilation

#

@cinder pelican

cinder pelican
#

im very confused

brave cape
#

Mm

cinder pelican
#

but you need to put the linux folder as a relative folder to the makefile

#

you don't move the make file

brave cape
#

In here

#

What is the label for make

cinder pelican
#

there isn't a label for make im not entirely sure what you mean

#

literally just do what you were doing originally

#

but make a folder first

brave cape
#

Hey?

#

Idk what you mean

#

Okay

#

@cinder pelican

cinder pelican
brave cape
cinder pelican
#

aha well at least now its actually building

#

its just got a compile error

brave cape
#

Mm

#

Values.h

#

Maybe that file isn't included

cinder pelican
#

apparently its an only linux file that isn't used anymore

brave cape
#

What's that mean

cinder pelican
#

Im not really sure you have the know-how to be doing this btw

#

like

#

you kinda need to understand these things

#

and its fine if you don't

brave cape
cinder pelican
#

but you might want to start with an easier project

brave cape
#

No

#

I want to go to hell

cinder pelican
#

well there are ways to find compatibility versions of this header

#

idk if it was fully removed, but it appears you don't have it

brave cape
#

Like

brave cape
#

It's not

#

In the repo

cinder pelican
#

yes

#

its not part of the repo

#

its part of linux

#

old linux

#

and it got replaced by different things

brave cape
#

Ok

cinder pelican
#

so it no longer exists anymore

#

again. This is just something someone trying to do this should probably know

brave cape
#

Mm

#

What to do

#

To fix it

#

@cinder pelican

cinder pelican
#

make your own, or replace all the uses with more modern versions

brave cape
#

Like

#

Idk

#

How to get data from

#

Doomstat

mossy moat
brave cape
#

And make a values file

#

Wdym

cinder pelican
#

yes that is the link I sent with an example values.h file

#

you could put that in the project and it might help

brave cape
#

What to do

#

Ok

#

In the Linux folder

cinder pelican
#

not in the linux folder

#

in the same folder as everything else

#

its a source file not a binary file

brave cape
#

And look for a doom bin file

#

?

#

Values.h not working

#

A cluster

#

?

cinder pelican
#

ah okay well the problem is that gcc is expecting it to be a library file

#

hence why its telling you to replace <> with ""

#

and you should probably do that, since its no longer a library file

brave cape
#

Mm

#

Add a _

#

Or what do you mean

#

Vim "values.h"

cinder pelican
#

okay man like there is only so much I can spoonfeed before Im just doing it all for you

brave cape
#

Mm

cinder pelican
#

the error message basically tells you exactly what to do in a very clear manner

brave cape
#

I have cancer and I want to go-to hell

mossy moat
cinder pelican
#

if you want someone to do something for you, maybe you could pay someone to do it idk

#

or just buy a copy of doom

brave cape
#

I'm on a pension and public trustee

#

I gat barley enough

#

Header guards

#

Or #include some file

#

With ""

mossy moat
#

so that error tells you exactly what the problem is

#

and where it is

#

and even how to fix it

brave cape
#

Line 42

#

Of values.h

cinder pelican
#

no

#

line 42 of doomtype.h

#

./doomtype.h:42:10 means line 42, column 10 in file doomtype.h

mossy moat
#

please read

brave cape
#

<sys/shm.h>

#

Where do fine this

#

Like the white website

#

@cinder pelican

cinder pelican
#

all I did was google for it

#

although

#

I feel like you should have this

mossy moat
#

is sys/shm.h in the kernel headers?

brave cape
#

There isn't that file

cinder pelican
#

I could understand value.h missing

brave cape
#

Mm

cinder pelican
#

not sure about this one

brave cape
#

Shared mem

mossy moat
#

let me check and see if shm is in the linux headers package

brave cape
#

Ok

#

Ty

mossy moat
#

or, conversely, you could open google

brave cape
#

Idk

cinder pelican
#

thats a description of the file yes

#

the difficult thing is that you probably can't just find a copy of this somewhere

brave cape
#

Mm

cinder pelican
#

its going to need to be specific to the linux distrubution

mossy moat
#

install linux-headers-generic

#

through apt

brave cape
#

What's the grep

mossy moat
#

also, have you installed the build-essential packages?

brave cape
#

The second one doesn't work

mossy moat
#

define "doesn't work"

brave cape
#

sudo apt-get install linux-generic

#

Even with out sudo

mossy moat
#

because it's linux-headers-generic

#

not linux-generic

brave cape
mossy moat
#

you're on ubuntu, right?

#

if so, try linux-headers-$(uname -r) instead of generic

brave cape
#

@cinder pelican

#

Hello?

mossy moat
#

dude, don't randomly ping

#

people here are volunteering time

brave cape
#

Mm

#

Volunteering is good

mossy moat
brave cape
#

Termux app

mossy moat
#

what are you actually building on though

brave cape
#

Pardon?

#

Idk

mossy moat
#

That's important to know

#

We have no clue what type of machine you're connected to

brave cape
cinder pelican
#

they're not connected to a machine afaik

#

its just their phone

mossy moat
#

wait, they're building directly on android???

#

the fuck

cinder pelican
#

I think so

mossy moat
#

It's 9 am, can I start drinking?

brave cape
#

Kernal header files plz

#

Lol

#

Imma get some sleep

rough micaBOT
#

@brave cape Has your question been resolved? If so, type !solved :)

brave cape
#

Sup guys

spark wigeon
#

literally compile to arm

#

ah its this doom

#

well you are fucked

brave cape
#

No

mossy moat
#

@rigid ledge can i use this thread to shitpost now? KEKW

rigid ledge
#

let's just move on

mossy moat
#

fair