From b9d6bfe927c327dbfb197bb8e9e52ac2f07d7d48 Mon Sep 17 00:00:00 2001
From: Joel Challis <git@zvecr.com>
Date: Thu, 14 Sep 2023 08:23:06 +0100
Subject: Fix input_club/k_type when RGB Matrix disabled (#22021)

---
 keyboards/input_club/k_type/post_rules.mk | 5 +++++
 keyboards/input_club/k_type/rules.mk      | 5 -----
 2 files changed, 5 insertions(+), 5 deletions(-)
 create mode 100644 keyboards/input_club/k_type/post_rules.mk

diff --git a/keyboards/input_club/k_type/post_rules.mk b/keyboards/input_club/k_type/post_rules.mk
new file mode 100644
index 0000000000..897e422b05
--- /dev/null
+++ b/keyboards/input_club/k_type/post_rules.mk
@@ -0,0 +1,5 @@
+ifeq ($(strip $(RGB_MATRIX_ENABLE)), yes)
+	# Additional files for RGB lighting
+	SRC += k_type-rgbdriver.c
+	QUANTUM_LIB_SRC += i2c_master.c is31fl3733-dual.c
+endif
diff --git a/keyboards/input_club/k_type/rules.mk b/keyboards/input_club/k_type/rules.mk
index d7776bb755..684de50562 100644
--- a/keyboards/input_club/k_type/rules.mk
+++ b/keyboards/input_club/k_type/rules.mk
@@ -13,8 +13,3 @@ AUDIO_ENABLE = no           # Audio output
 
 # RGB options
 RGB_MATRIX_ENABLE = no
-
-# Additional files for RGB lighting
-SRC += k_type-rgbdriver.c
-QUANTUM_LIB_SRC += i2c_master.c is31fl3733-dual.c
-
-- 
cgit v1.2.3