math/libfixmath: update g20220915 → 2023.08.08

This commit is contained in:
Yuri Victorovich 2025-01-26 10:01:14 -08:00
parent e6aab2d227
commit e1a2b43a9d
3 changed files with 29 additions and 28 deletions

View file

@ -1,5 +1,5 @@
PORTNAME= libfixmath PORTNAME= libfixmath
PORTVERSION= g20220915 PORTVERSION= 2023.08.08 # release unlikely, project is semi-deprecated, see https://github.com/PetteriAimonen/libfixmath/issues/51#issuecomment-2614311140
CATEGORIES= math CATEGORIES= math
MAINTAINER= yuri@FreeBSD.org MAINTAINER= yuri@FreeBSD.org
@ -13,7 +13,7 @@ USES= cmake:testing compiler:c++11-lang
USE_GITHUB= yes USE_GITHUB= yes
GH_ACCOUNT= PetteriAimonen GH_ACCOUNT= PetteriAimonen
GH_TAGNAME= 1416c99 GH_TAGNAME= d308e46
CMAKE_ON= BUILD_SHARED_LIBS CMAKE_ON= BUILD_SHARED_LIBS
@ -24,4 +24,6 @@ do-install:
# library # library
${INSTALL_LIB} ${BUILD_WRKSRC}/libfixmath.so ${STAGEDIR}${PREFIX}/lib ${INSTALL_LIB} ${BUILD_WRKSRC}/libfixmath.so ${STAGEDIR}${PREFIX}/lib
# tests are broken due to cmake issues
.include <bsd.port.mk> .include <bsd.port.mk>

View file

@ -1,3 +1,3 @@
TIMESTAMP = 1667802450 TIMESTAMP = 1737913417
SHA256 (PetteriAimonen-libfixmath-g20220915-1416c99_GH0.tar.gz) = 3e9ee9cb4c6aa06763c5be01ae24486ebc888fd51f8412f33424154e78c6eca3 SHA256 (PetteriAimonen-libfixmath-2023.08.08-d308e46_GH0.tar.gz) = f715c54f254eecfe7ba824adaa11724e478d51f5f9e60c0013d87f0c255f3034
SIZE (PetteriAimonen-libfixmath-g20220915-1416c99_GH0.tar.gz) = 267430 SIZE (PetteriAimonen-libfixmath-2023.08.08-d308e46_GH0.tar.gz) = 268645

View file

@ -1,28 +1,27 @@
--- CMakeLists.txt.orig 2022-09-15 10:24:31 UTC --- CMakeLists.txt.orig 2023-08-08 06:08:53 UTC
+++ CMakeLists.txt +++ CMakeLists.txt
@@ -11,17 +11,23 @@ set(CMAKE_CXX_STANDARD_REQUIRED ON) @@ -14,16 +14,22 @@ if(CMAKE_CURRENT_SOURCE_DIR STREQUAL CMAKE_SOURCE_DIR)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -pedantic -Wextra -Werror=return-type")
include(libfixmath/libfixmath.cmake) if(CMAKE_CURRENT_SOURCE_DIR STREQUAL CMAKE_SOURCE_DIR)
+if (BUILD_TESTING) # We're in the root, define additional targets for developers.
include(tests/tests.cmake) + if (BUILD_TESTING)
+endif() include(tests/tests.cmake)
+ endif()
file(GLOB fixsingen-srcs fixsingen/*.c) file(GLOB fixsingen-srcs fixsingen/*.c)
+if (BUILD_TESTING) + if (BUILD_TESTING)
file(GLOB fixtest-srcs fixtest/*.c fixtest/*.h) file(GLOB fixtest-srcs fixtest/*.c fixtest/*.h)
+endif() + endif()
+if (BUILD_TESTING)
add_executable(fixtest ${fixtest-srcs})
-target_link_libraries(fixtest PRIVATE libfixmath m)
+target_link_libraries(fixtest PRIVATE fixmath m)
target_include_directories(fixtest PRIVATE ${CMAKE_SOURCE_DIR})
+endif()
add_executable(fixsingen ${fixsingen-srcs})
-target_link_libraries(fixsingen PRIVATE libfixmath m)
+target_link_libraries(fixsingen PRIVATE fixmath m)
target_include_directories(fixsingen PRIVATE ${CMAKE_SOURCE_DIR})
+ if (BUILD_TESTING)
add_executable(fixtest ${fixtest-srcs})
- target_link_libraries(fixtest PRIVATE libfixmath m)
+ target_link_libraries(fixtest PRIVATE m)
target_include_directories(fixtest PRIVATE ${CMAKE_SOURCE_DIR})
+ endif()
add_executable(fixsingen ${fixsingen-srcs})
- target_link_libraries(fixsingen PRIVATE libfixmath m)
+ target_link_libraries(fixsingen PRIVATE m)
target_include_directories(fixsingen PRIVATE ${CMAKE_SOURCE_DIR})
endif()