Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix prefix for FreeBSD, OpenBSD #916

Merged
merged 1 commit into from
Aug 17, 2024
Merged

Fix prefix for FreeBSD, OpenBSD #916

merged 1 commit into from
Aug 17, 2024

Conversation

hodong-kim
Copy link
Contributor

FreeBSD and OpenBSD typically use /usr/local as the prefix. This patch modifies the prefix.

Copy link
Member

@ksqsf ksqsf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved. Actually, I believe the best approach is to change Linux's prefix to /usr/local, too. But I'm not sure if there is anyone relying on the old behavior.

@ksqsf
Copy link
Member

ksqsf commented Jul 17, 2024

BTW, does NetBSD need it?

@hodong-kim
Copy link
Contributor Author

BTW, does NetBSD need it?

I haven't tried it on NetBSD, so I don't know.

@hodong-kim
Copy link
Contributor Author

Approved. Actually, I believe the best approach is to change Linux's prefix to /usr/local, too. But I'm not sure if there is anyone relying on the old behavior.

This also needs to be fixed to take effect.

diff --git a/CMakeLists.txt b/CMakeLists.txt
index e167e228..ce22fc41 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -204,7 +204,7 @@ configure_file(
 add_custom_target(remove
   COMMAND ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake)
 
-if(${CMAKE_SYSTEM_NAME} MATCHES "Linux|FreeBSD|DragonFly|GNU|Darwin" OR MINGW)
+if(${CMAKE_SYSTEM_NAME} MATCHES "Linux|FreeBSD|OpenBSD|DragonFly|GNU|Darwin" OR MINGW)
   set(prefix "${CMAKE_INSTALL_PREFIX}")
   set(exec_prefix "${CMAKE_INSTALL_PREFIX}")
   set(bindir "${CMAKE_INSTALL_FULL_BINDIR}")

FreeBSD and OpenBSD typically use /usr/local as the prefix.
This patch modifies the prefix.
@ksqsf
Copy link
Member

ksqsf commented Aug 17, 2024

Tested manually on FreeBSD, and looks fine. I‘m merging it. Thanks!

@ksqsf ksqsf merged commit 9e08470 into rime:master Aug 17, 2024
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants