From 396c6adaa89468b47de7a930ae4037b9ce97210b Mon Sep 17 00:00:00 2001 From: Alec Geatches Date: Tue, 30 Apr 2019 08:44:36 +0800 Subject: Change lib8tion library to be usable in user keymaps (#5598) * Move lib8tion header-defined constant into implementation file, add to build * Move b_m16_interleave initializtion to lib8tion.c, change build to include lib8tion.c in QUANTUM_LIB_SRC * Remove left-over whitespace * Move lib8tion include by RGB_MATRIX_ENABLE code in makefile * Revert build changes and change lib8tion b_m16_interleave constant to static --- lib/lib8tion/trig8.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/lib8tion/trig8.h b/lib/lib8tion/trig8.h index 4907c6ff30..6ef3ce625f 100644 --- a/lib/lib8tion/trig8.h +++ b/lib/lib8tion/trig8.h @@ -147,7 +147,7 @@ LIB8STATIC int16_t cos16( uint16_t theta) #endif -const uint8_t b_m16_interleave[] = { 0, 49, 49, 41, 90, 27, 117, 10 }; +static const uint8_t b_m16_interleave[8] = { 0, 49, 49, 41, 90, 27, 117, 10 }; /// Fast 8-bit approximation of sin(x). This approximation never varies more than /// 2% from the floating point value you'd get by doing -- cgit v1.2.3 From 51b568a197415051dbf329c4cd429b2607bf8f0a Mon Sep 17 00:00:00 2001 From: XScorpion2 Date: Mon, 29 Apr 2019 19:45:42 -0500 Subject: Removed forced in lining for lib8tion functions (#5670) --- lib/lib8tion/lib8tion.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/lib8tion/lib8tion.h b/lib/lib8tion/lib8tion.h index d93c748e6a..4c770cbcb5 100644 --- a/lib/lib8tion/lib8tion.h +++ b/lib/lib8tion/lib8tion.h @@ -167,8 +167,8 @@ Lib8tion is pronounced like 'libation': lie-BAY-shun #include -#define LIB8STATIC __attribute__ ((unused)) static inline -#define LIB8STATIC_ALWAYS_INLINE __attribute__ ((always_inline)) static inline +#define LIB8STATIC static inline +#define LIB8STATIC_ALWAYS_INLINE static inline #if !defined(__AVR__) #include -- cgit v1.2.3