Idioma

Compilar Mads en Linux

Para compilar en Linux el ensamblador más famoso y más actualizado, solo debes tener instalado el Free Pascal y la fuente del Mads.


Partimos agregando el paquete del Free Pascal Compiler llamado fpc desde el terminal :

sudo apt install fpc	

Ahora vamos al repositorio oficial del fuente del Mads lo descargamos y descomprimimos.
A continuación procedemos a compilarlo :

cd Mad-Assembler-2.1.5
fpc -Mdelphi -vh -O3 mads.pas	

En el proceso verás los siguiente en el terminal :

Hint: Start of reading config file /etc/fpc.cfg
Hint: End of reading config file /etc/fpc.cfg
Free Pascal Compiler version 3.2.0+dfsg-12 [2021/01/25] for x86_64
Copyright (c) 1993-2020 by Florian Klaempfl and others
Target OS: Linux for x86-64
Compiling mads.pas
mads.pas(1131,5) Note: Local variable "i" is assigned but never used
mads.pas(3733,29) Hint: Local variable "par" of a managed type does not seem to be initialized
mads.pas(4702,28) Warning: Local variable "tmp" of a managed type does not seem to be initialized
mads.pas(6940,35) Hint: Local variable "zm" of a managed type does not seem to be initialized
mads.pas(6291,10) Warning: Local variable "par" of a managed type does not seem to be initialized
mads.pas(8343,49) Warning: Local variable "str" of a managed type does not seem to be initialized
mads.pas(8944,46) Warning: Local variable "all" does not seem to be initialized
mads.pas(9853,26) Hint: Local variable "par" of a managed type does not seem to be initialized
mads.pas(12829,47) Hint: Local variable "txt" of a managed type does not seem to be initialized
mads.pas(10333,27) Hint: Local variable "par" of a managed type does not seem to be initialized
mads.pas(12829,51) Hint: Local variable "tmp" of a managed type does not seem to be initialized
mads.pas(11781,52) Warning: Local variable "idx" does not seem to be initialized
mads.pas(11781,51) Warning: Local variable "idx" does not seem to be initialized
mads.pas(12829,53) Hint: Local variable "v" does not seem to be initialized
mads.pas(12949,54) Hint: Local variable "r" does not seem to be initialized
mads.pas(13337,29) Hint: Local variable "tmpZM" of a managed type does not seem to be initialized
mads.pas(15421,5) Note: Local variable "s" not used
Linking mads
15896 lines compiled, 0.8 sec
6 warning(s) issued
11 hint(s) issued
2 note(s) issued	

Hay varios Hints y Warning es lo normal, ahora lo ejecutamos para ver si funciona :

./mads	

https://www.atariware.cl/archivos/mads/madslinux.png

Como se ve en la imagen esta todo ok. Lo ultimo por hacer es agregar al sistema para que sea reconocido desde cualquier directorio donde estemos trabajando para ello ejecutamos lo siguiente :

sudo cp mads /usr/bin/	

Por ultimo si no quieres compilarlo aquí está disponible el binario para Linux Debian 11.