English Amiga Board


Go Back   English Amiga Board > Coders > Coders. General

 
 
Thread Tools
Old 09 July 2021, 15:55   #1
hjalfi
Registered User
 
Join Date: Feb 2019
Location: Zurich
Posts: 38
Looking for an open source cross assembler/linker

Hello,


I want to write some 68k Amiga software, cross-compiled from Linux (porting a compiler). It's a combination of C and asm using gcc.


Unfortunately it looks like GNU binutils doesn't support the Amiga, and Amiga binaries are rather hard to generate by hand. It looks like most people use vasm and vlink but I can't use those due to the restrictive licenses.


There's got to be others --- I just can't find any! Can anyone point me at anything? It doesn't need to complex as I only need a single code and data segment.


Thanks!
hjalfi is offline  
Old 09 July 2021, 15:57   #2
roondar
Registered User
 
Join Date: Jul 2015
Location: The Netherlands
Posts: 3,406
There is an GCC port for making Amiga software that is reasonably up to date and includes the binutils, maybe that can help?
See here: https://github.com/bebbo/amiga-gcc
roondar is offline  
Old 09 July 2021, 15:58   #3
Samurai_Crow
Total Chaos forever!
 
Samurai_Crow's Avatar
 
Join Date: Aug 2007
Location: Waterville, MN, USA
Age: 49
Posts: 2,186
https://github.com/bebbo/amiga-gcc has an Amiga Hunk-compatible binutils package.
Edit- ninja'd
Samurai_Crow is offline  
Old 09 July 2021, 16:05   #4
roondar
Registered User
 
Join Date: Jul 2015
Location: The Netherlands
Posts: 3,406
Quote:
Originally Posted by Samurai_Crow View Post
https://github.com/bebbo/amiga-gcc has an Amiga Hunk-compatible binutils package.
Edit- ninja'd
/flex
roondar is offline  
Old 09 July 2021, 16:05   #5
hjalfi
Registered User
 
Join Date: Feb 2019
Location: Zurich
Posts: 38
D'oh! I saw that, but as the list of software included vlink I thought binutils was just being used as an assembler. Building it now. Thanks!
hjalfi is offline  
Old 09 July 2021, 20:38   #6
phx
Natteravn
 
phx's Avatar
 
Join Date: Nov 2009
Location: Herford / Germany
Posts: 2,496
Quote:
Originally Posted by hjalfi View Post
It looks like most people use vasm and vlink but I can't use those due to the restrictive licenses.
What is restricting you exactly?
phx is offline  
Old 09 July 2021, 21:18   #7
hjalfi
Registered User
 
Join Date: Feb 2019
Location: Zurich
Posts: 38
The usage restrictions (no commercial use) will keep it out of nearly all Linux distributions, such as Debian. It prevents them from selling CDs or DVDs with the software on it. See 12.A.j or 34.A.0 here: https://people.debian.org/~bap/dfsg-faq.html The exemption clause for targeting Amiga binaries doesn't help because in source form the program isn't targeted at anything, which means it doesn't kick in.

In addition to that, distributing modifications is completely disallowed, which violates 34.A.1 and 34.A.3. (And also makes it useless for my purposes as I can't, e.g., integrate it into my build system.)
hjalfi is offline  
Old 10 July 2021, 01:33   #8
Bruce Abbott
Registered User
 
Bruce Abbott's Avatar
 
Join Date: Mar 2018
Location: Hastings, New Zealand
Posts: 2,543
Quote:
Originally Posted by hjalfi View Post
In addition to that, distributing modifications is completely disallowed, which violates 34.A.1 and 34.A.3. (And also makes it useless for my purposes as I can't, e.g., integrate it into my build system.)
So you're not just talking about using it, but distributing a modified version of the assembler and linker? Why would you need to do that?
Bruce Abbott is offline  
Old 10 July 2021, 02:30   #9
redblade
Zone Friend
 
redblade's Avatar
 
Join Date: Mar 2004
Location: Middle Earth
Age: 40
Posts: 2,127
Maybe www.aminet.net A68k by Charlie Gibbs and Pdc (Sozoban Compiler) will be ok for what you need?
redblade is offline  
Old 10 July 2021, 03:21   #10
Samurai_Crow
Total Chaos forever!
 
Samurai_Crow's Avatar
 
Join Date: Aug 2007
Location: Waterville, MN, USA
Age: 49
Posts: 2,186
Quote:
Originally Posted by redblade View Post
Maybe www.aminet.net A68k by Charlie Gibbs and Pdc (Sozoban Compiler) will be ok for what you need?
They both used a closed-source linker IIRC. BLink is closed source.
Samurai_Crow is offline  
Old 10 July 2021, 08:57   #11
alkis
Registered User
 
Join Date: Dec 2010
Location: Athens/Greece
Age: 53
Posts: 719
Quote:
Originally Posted by Samurai_Crow View Post
They both used a closed-source linker IIRC. BLink is closed source.
It's not that a68k is binded to blink. It produces standard amiga object files and you can use any linker. m68k-amigaos-ld from bebbo's toolchain should work (untested).
alkis is offline  
Old 10 July 2021, 10:54   #12
hjalfi
Registered User
 
Join Date: Feb 2019
Location: Zurich
Posts: 38
I've managed to build bebbo's toolchain, so I'll give that a try. Thanks very much.

Re not being able to distribute modifications: it means I can't check the source code into my VCS, edit the Makefile to preconfigure it, add a file to make it build with my non-Make-based build system, or fix any bugs. I'd have to distribute the original source archive, and add machinery to my build system to unpack it and apply an external patch in order to build it. And it still wouldn't be allowed in Debian.

I've actually done this before with vbcc (see https://cowlark.com/vbcc-z-compiler) and it just isn't worth it, especially if I can find a different toolchain.
hjalfi is offline  
Old 10 July 2021, 12:14   #13
phx
Natteravn
 
phx's Avatar
 
Join Date: Nov 2009
Location: Herford / Germany
Posts: 2,496
Quote:
Originally Posted by hjalfi View Post
The usage restrictions (no commercial use) will keep it out of nearly all Linux distributions, such as Debian.
Which is not really a problem. The source is downloaded and compiled in a few seconds. Pure ANSI-C. There are no dependencies, as in most bloated GNU tools.

Quote:
It prevents them from selling CDs or DVDs with the software on it.
Software? You're talking about the vasm source? Why should we allow anybody to make money from our hard work, which we already offer for free?

Quote:
The exemption clause for targeting Amiga binaries doesn't help because in source form the program isn't targeted at anything, which means it doesn't kick in.
This clause is dealing with binaries you are generating with our tools. The source is always free to distribute, when unmodified.

Quote:
In addition to that, distributing modifications is completely disallowed
For a good reason. We don't want forks. We are doing (pretty good) free support for our tools, and we certainly don't want to do that for a version which somebody else modified.

Quote:
Originally Posted by hjalfi View Post
it means I can't check the source code into my VCS, edit the Makefile to preconfigure it, add a file to make it build with my non-Make-based build system
You can always add files. This is no modification.

Quote:
or fix any bugs.
Bugs should be reported, so they will be fixed in all future versions.

Quote:
I'd have to distribute the original source archive, and add machinery to my build system to unpack it and apply an external patch in order to build it
Do you always include the full source of your tool chains in all your projects? If the only reason is to fix bugs, or to add new features, see above.
phx is offline  
Old 10 July 2021, 12:30   #14
hjalfi
Registered User
 
Join Date: Feb 2019
Location: Zurich
Posts: 38
That's fine --- it's your software, you can do what you like with it! It's just that those decisions mean that I can't use it.
hjalfi is offline  
Old 13 September 2021, 21:44   #15
hmn
Registered User
 
Join Date: Nov 2016
Location: DE
Posts: 20
A couple of years ago I was also doing some cross-development with A68k, and I was missing a cross-platform blink counterpart. So I wrote a little toy linker in Python called "hunky" that mimics blink. The idea was that I could use A68k/hunky for cross development and A68k/blink natively on KS1.3.

Reading this thread reminded me of that little project, so I decided to put it online.

Again, this is only a toy that just implements the bare minimum of functionality to link an executable. I am not actively working on it at the moment, but maybe it is of interest to someone.
hmn is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
Open Source GUI Library for Assembler AGS Coders. Asm / Hardware 102 05 August 2021 14:51
Open source cross assembler for the Amiga? hjalfi Coders. Asm / Hardware 0 29 December 2020 18:56
Source Debugging + Linker? wk_end Coders. Asm / Hardware 3 21 April 2016 13:40
Amiga Cross Assembler to code intros! - Help! W4r3DeV1L Amiga scene 6 30 May 2008 16:53

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 07:31.

Top

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Page generated in 0.17435 seconds with 13 queries