]> Shamusworld >> Repos - rmac/blobdiff - object.c
Version bump for last commit. :-)
[rmac] / object.c
index f7ac8a79cda5cfde83d6bbced6cb0c27cbfa9a46..6dbf9c525aac300a44cf4127536c99f9c9f044db 100644 (file)
--- a/object.c
+++ b/object.c
@@ -864,9 +864,18 @@ for(int j=0; j<i; j++)
        }
        else if (obj_format == RAW)
        {
-               if (!org68k_active)
+               if (!org68k_active && used_architectures & (!(M6502 | M56001P | M56001X | M56001Y | M56001L)))
                        return error("cannot output absolute binary without a starting address (.org or command line)");
 
+               if (used_architectures & M6502)
+               {
+                       // Okay, this is not the best. But it'll have to do until we revamp things a bit with sections.
+                       // Basically we assume that if raw output is requested and 6502 mode was switched on, nobody
+                       // switched to other architectures. The combination doesn't make much sense anyway for now.
+                       m6502raw(fd);
+                       return 0;
+               }
+
                // Alloc memory for text + data construction.
                tds = sect[TEXT].sloc + sect[DATA].sloc;
                buf = malloc(tds);