diff --git a/asminc/zeropage.inc b/asminc/zeropage.inc index 2d4b144db..8d508fc5a 100644 --- a/asminc/zeropage.inc +++ b/asminc/zeropage.inc @@ -13,10 +13,18 @@ .globalzp tmp1, tmp2, tmp3, tmp4 .globalzp regbank +; FIXME: there must be a less ugly way to do this +.ifp4510 +.else +.ifp45GS02 +.else + ; The following symbol is supplied for compatibility reasons only, it ; will get removed in future versions. Using it will cause a linker ; warning. .globalzp sp +.endif +.endif ; The size of the register bank diff --git a/libsrc/runtime/sp-compat.s b/libsrc/runtime/sp-compat.s index 797fef47b..77972212f 100644 --- a/libsrc/runtime/sp-compat.s +++ b/libsrc/runtime/sp-compat.s @@ -5,7 +5,15 @@ ; linker warning if it is used. Added after renaming "sp" to "c_sp". ; +; FIXME: there must be a less ugly way to do this +.ifp4510 +.else +.ifp45GS02 +.else + .include "zeropage.inc" .export sp := c_sp .assert 0, ldwarning, "Symbol 'sp' is deprecated - please use 'c_sp' instead" +.endif +.endif