* include/grub/dl.h: Switch from APPLE_CC to __APPLE__.

(GRUB_MOD_LICENSE) [ASM_FILE]: Make into macro. All users updated.
This commit is contained in:
Vladimir 'phcoder' Serbinenko 2012-02-29 14:51:09 +01:00
parent 5982495738
commit c4b7e58882
8 changed files with 27 additions and 12 deletions

View File

@ -1,3 +1,8 @@
2012-02-29 Vladimir Serbinenko <phcoder@gmail.com>
* include/grub/dl.h: Switch from APPLE_CC to __APPLE__.
(GRUB_MOD_LICENSE) [ASM_FILE]: Make into macro. All users updated.
2012-02-29 Vladimir Serbinenko <phcoder@gmail.com>
* include/grub/symbol.h (EXT_C) [!ASM_FILE]: Redefine with strings.

View File

@ -21,7 +21,7 @@
.file "setjmp.S"
GRUB_MOD_LICENSE ("GPLv3+")
GRUB_MOD_LICENSE "GPLv3+"
.text

View File

@ -69,7 +69,7 @@
.file "setjmp.S"
GRUB_MOD_LICENSE ("GPLv2+")
GRUB_MOD_LICENSE "GPLv2+"
/* The following two entry points are the traditional entry points: */

View File

@ -21,7 +21,7 @@
.file "setjmp.S"
GRUB_MOD_LICENSE ("GPLv3+")
GRUB_MOD_LICENSE "GPLv3+"
.text

View File

@ -21,7 +21,7 @@
.file "setjmp.S"
GRUB_MOD_LICENSE ("GPLv3+")
GRUB_MOD_LICENSE "GPLv3+"
.text

View File

@ -21,7 +21,7 @@
.file "setjmp.S"
GRUB_MOD_LICENSE ("GPLv3+")
GRUB_MOD_LICENSE "GPLv3+"
.text

View File

@ -21,7 +21,7 @@
.file "setjmp.S"
GRUB_MOD_LICENSE ("GPLv3+")
GRUB_MOD_LICENSE "GPLv3+"
.text

View File

@ -77,13 +77,13 @@ grub_mod_fini (void)
#endif
#ifndef ASM_FILE
#ifdef APPLE_CC
#ifdef __APPLE__
#define GRUB_MOD_SECTION(x) "_" #x ", _" #x ""
#else
#define GRUB_MOD_SECTION(x) "." #x
#endif
#else
#ifdef APPLE_CC
#ifdef __APPLE__
#define GRUB_MOD_SECTION(x) _ ## x , _ ##x
#else
#define GRUB_MOD_SECTION(x) . ## x
@ -114,11 +114,21 @@ static const char grub_module_name_##name[] \
static const char grub_module_depend_##name[] \
__attribute__((section(GRUB_MOD_SECTION(moddeps)), __used__)) = #name
#else
#define GRUB_MOD_LICENSE(license) \
.section GRUB_MOD_SECTION(module_license), "a"; \
.ascii "LICENSE="; \
.ascii license; \
#ifdef __APPLE__
.macro GRUB_MOD_LICENSE
.section GRUB_MOD_SECTION(module_license)
.ascii "LICENSE="
.ascii $0
.byte 0
.endm
#else
.macro GRUB_MOD_LICENSE license
.section GRUB_MOD_SECTION(module_license), "a"
.ascii "LICENSE="
.ascii "\license"
.byte 0
.endm
#endif
#endif
/* Under GPL license obligations you have to distribute your module