This is the mail archive of the mailing list for the newlib project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Compilation problem on m68k/memcpy.S

Thanks Vincent. I decided to make a new file: m68kasm.h which has the prelude found in setjmp.S. I then had the 3 .S files include "m68kasm.h" and use the SYM() macro as you have below.

Please try out the new code to make sure I didn't make any mistakes. I don't have a m68k build handy for testing.

2008-01-07 Jeff Johnston <>

        * libc/machine/m68k/m68kasm.h: New file.
        * libc/machine/m68k/setjmp.S: Remove common definitions and
        place in m68kasm.h.  Include "m68kasm.h".
        * libc/machine/m68k/memcpy.S: Include "m68kasm.h" and use
        SYM() macro when referencing function name.
        * libc/machine/m68k/memset.S: Ditto.

-- Jeff J.

Vincent Rivière wrote:

There is a compilation problem on these 2 files :
when compiling on a m68k target using symbols with leading underscores.

The attached patch fixes the problem.
It uses the well-known SYM() macro.
This patch works. However, it may be a good idea do centralize this macro somewhere for the whole library.

Note there is also:

#define __USER_LABEL_PREFIX__ _

I kept it like this, because this is the usual way to do.
However, when __USER_LABEL_PREFIX__ is not automatically defined, it might be better to define it to nothing to avoid regressions.

I hope this will help.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]