SDL_rtf: cmake: fix macho {compatibility,current} version (3c686)

From 3c686734a6139ac3b4ef6209e1dd62c0654d602a Mon Sep 17 00:00:00 2001
From: Ozkan Sezer <[EMAIL REDACTED]>
Date: Wed, 1 May 2024 00:23:50 +0300
Subject: [PATCH] cmake: fix macho {compatibility,current} version

---
 CMakeLists.txt | 12 +++++-------
 1 file changed, 5 insertions(+), 7 deletions(-)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index f0a6322..95967f8 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -131,18 +131,16 @@ set_target_properties(${sdl3_rtf_target_name} PROPERTIES
     C_VISIBILITY_PRESET "hidden"
 )
 if(NOT ANDROID)
+    set_target_properties(${sdl3_rtf_target_name} PROPERTIES
+        SOVERSION "${SO_VERSION_MAJOR}"
+        VERSION "${SO_VERSION}"
+    )
     if(APPLE)
-        # the SOVERSION property corresponds to the compatibility version and VERSION corresponds to the current version
-        # https://cmake.org/cmake/help/latest/prop_tgt/SOVERSION.html#mach-o-versions
+        cmake_minimum_required(VERSION 3.17)
         set_target_properties(${sdl3_rtf_target_name} PROPERTIES
             SOVERSION "${DYLIB_COMPAT_VERSION}"
             VERSION "${DYLIB_CURRENT_VERSION}"
         )
-    else()
-        set_target_properties(${sdl3_rtf_target_name} PROPERTIES
-            SOVERSION "${SO_VERSION_MAJOR}"
-            VERSION "${SO_VERSION}"
-        )
     endif()
 endif()
 if(SDL3RTF_BUILD_SHARED_LIBS)