VASM - Makefile

Posts about Z80 programming that do not relate to a particular computer
Post Reply
Limonadd
Posts: 6
Joined: Sat May 04, 2019 12:46 am

VASM - Makefile

Post by Limonadd » Sat May 04, 2019 11:49 am

I don't know if it is the right place to post that, sorry.
Anyways, so I wanted to learn gbz80 assembly, and I wanted to use VASM to assemble my programs.

I learnt a bit of z80/ez80 assembly before, and I used spasm64 to assemble.
It was pretty easy, I had a notpad with the source, spasm64 exe and .bat file with the command:
"spasm64 -E "code.asm" "TEST.8xp pause"
to create a TEXT.8xp file from my code.asm file, for my calculator.

But for vasm, you have to compile the executable yourself, for the cpu you want to assemble on, and I never did that :(
And even after compiling, in the .bat file there is sooo many commands to put in, i'm totally lost with that.

I saw your article on the differences between winape and vasm. Actually, VASM syntax seems to be more similar to what i'm used to. And i'm used to the simple notepad for the source, and the emulator and the assembler apart.

But I didnt understand how to make the executable file (with the Makefile) from the source.

Actually, I took the exec that you built, with your command and it works! Ty!
But i'm confused on how to compile vasm, I never did that.
I tried a few things but I got an error every time haha.

Maybe you have a tutorial video, or you could explain me how to do it?
I know i suk haha

User avatar
akuyou
Posts: 563
Joined: Mon Apr 22, 2019 3:19 am
Contact:

Re: VASM - Makefile

Post by akuyou » Sat May 04, 2019 12:08 pm

I take it you have my Devtools with the precompiled EXE from:
http://www.chibiakumas.com/z80/Z80DevTools.php

As for how I compiled VASM? well the answer was it was a great pain, so it's certainly not that you suck... and what I did no longer seems to work for the latest makefile... I'd suggest you try using CYGWin... it's not ideal, as it adds some dependencies to DLL's, but as I say, the tools I used no longer work with the latest Makefile in the source download (I used CodeBlocks C++ DevCPP on windows to build it)

Out of curiosity, why do you want to rebuild it yourself, is there something 'wrong' with the versions in my download?

Here's the batch file I used to achieve make... as I said, it does not work with the latest downloads:

Code: Select all

@echo off
set path=%path%;C:\Documents and Settings\Administrator\Local Settings\Temp\Dev-Cpp\MinGW32\bin
set maker=C:\Documents and Settings\Administrator\Local Settings\Temp\CodeBlocks\MinGW\bin\mingw32-make.exe

"%maker%" -f "Makefile.Win32FromLinux" CPU=%1 SYNTAX=std
"%maker%" -f "Makefile.Win32FromLinux" CPU=%1 SYNTAX=madmac
"%maker%" -f "Makefile.Win32FromLinux" CPU=%1 SYNTAX=mot
"%maker%" -f "Makefile.Win32FromLinux" CPU=%1 SYNTAX=oldstyle
"%maker%" -f "Makefile.Win32FromLinux" CPU=%1 SYNTAX=test
Chibi Akuma(s) Comedy-Horror 8-bit Bullet Hell shooter! // 「チビ悪魔」可笑しいゴシックSTG ! // Work in Progress: ChibiAliens

Interested in CPU's :Z80,6502,68000,6809,ARM,8086,RISC-V
Learning: 65816,ARM,8086,6809

Limonadd
Posts: 6
Joined: Sat May 04, 2019 12:46 am

Re: VASM - Makefile

Post by Limonadd » Sat May 04, 2019 12:20 pm

Oh ok, I see, thank you!

No the version that you built is perfectly fine!
Actually I just wanted to learn how you did to compile it, because I was lost with that haha

But your file works perfectly, thanks a lot for all your work! :D

User avatar
akuyou
Posts: 563
Joined: Mon Apr 22, 2019 3:19 am
Contact:

Re: VASM - Makefile

Post by akuyou » Sat May 04, 2019 12:23 pm

It was a totally fair question, to be honest, frustrations over how hard it is to compile open source C++ software seems to be is what pushes me to focus on ASM...

this may help you... here is the LATEST version of VASM, which I use in my current Z80/GB development - this contains some updates that the author did to correct some bugs I found (that are currently only in the nightly sources)

www.chibiakumas.com/download/vasm.7z

These are newer than the ones in the Devtools package - the reason is that before releasing a new 'devtools' I have to do a lot of testing on different machines with all the emulators, and remove ROM sets and whatnot, which takes more time than I have so the devtools vasm is a little older.
Chibi Akuma(s) Comedy-Horror 8-bit Bullet Hell shooter! // 「チビ悪魔」可笑しいゴシックSTG ! // Work in Progress: ChibiAliens

Interested in CPU's :Z80,6502,68000,6809,ARM,8086,RISC-V
Learning: 65816,ARM,8086,6809

Limonadd
Posts: 6
Joined: Sat May 04, 2019 12:46 am

Re: VASM - Makefile

Post by Limonadd » Sat May 04, 2019 12:28 pm

Actually that is the package I downloaded from you! The Z80 oldstyle executable works perfectly, thanks a lot!! :D

Post Reply

Return to “General Z80 Programming”