From 73c1ed402391be9445b5ba84ef3f0a77e825be28 Mon Sep 17 00:00:00 2001 From: Bertrand Songis Date: Sun, 5 Aug 2018 19:55:59 +0200 Subject: [PATCH] VC++ compilation fix --- radio/src/definitions.h | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/radio/src/definitions.h b/radio/src/definitions.h index c7d01a3f3..a2c31c38a 100644 --- a/radio/src/definitions.h +++ b/radio/src/definitions.h @@ -27,11 +27,8 @@ #define UNUSED(x) ((void)(x)) /* to avoid warnings */ #endif -#if defined(SIMU) && __GNUC__ - #define __ALIGNED(x) __attribute__((aligned(x))) - #define __SECTION_USED(s) __attribute__((used)) -#elif defined(SIMU) - #define __ALIGNED(x) __declspec(align(x)) +#if defined(SIMU) + #define __ALIGNED(x) #define __SECTION_USED(s) #else #define __ALIGNED(x) __attribute__((aligned(x))) @@ -41,9 +38,9 @@ #if defined(SIMU) #define __DMA #elif (defined(STM32F4) && !defined(BOOT)) || defined(SDRAM) - #define __DMA __attribute__((section(".ram"), aligned(4))) + #define __DMA __attribute__((section(".ram"), aligned(4))) #else - #define __DMA __ALIGNED(4) + #define __DMA __ALIGNED(4) #endif #if defined(SDRAM) && !defined(SIMU)