Skip to content

Conversation

@trixirt
Copy link
Contributor

@trixirt trixirt commented Jan 20, 2024

On Fedora the install location is dependent on the arch ex/ for x86_64 libraries install to /usr/lib64

So copy how llama-cpp does its install, replacing 'llama' with 'whisper' in the cmake variables.

On Fedora the install location is dependent on the arch
ex/ for x86_64 libraries install to /usr/lib64

So copy how llama-cpp does its install, replacing 'llama' with 'whisper'
in the cmake variables.

Signed-off-by: Tom Rix <[email protected]>
@petterreinholdtsen
Copy link
Contributor

The change seem to break Windows builds. Any hope to fix it?

Comment on lines +552 to +557
set(WHISPER_INCLUDE_INSTALL_DIR ${CMAKE_INSTALL_INCLUDEDIR}
CACHE PATH "Location of header files")
set(WHISPER_LIB_INSTALL_DIR ${CMAKE_INSTALL_LIBDIR}
CACHE PATH "Location of library files")
set(WHISPER_BIN_INSTALL_DIR ${CMAKE_INSTALL_BINDIR}
CACHE PATH "Location of binary files")

Choose a reason for hiding this comment

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

Any reason for exposing these as variables?

Comment on lines +560 to +564
LIBRARY DESTINATION "${WHISPER_LIB_INSTALL_DIR}"
ARCHIVE DESTINATION "${WHISPER_LIB_INSTALL_DIR}/static"
RUNTIME DESTINATION "${WHISPER_BIN_INSTALL_DIR}"
RESOURCE DESTINATION "${WHISPER_BIN_INSTALL_DIR}"
PUBLIC_HEADER DESTINATION "${WHISPER_INCLUDE_INSTALL_DIR}"

Choose a reason for hiding this comment

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

Suggested change
LIBRARY DESTINATION "${WHISPER_LIB_INSTALL_DIR}"
ARCHIVE DESTINATION "${WHISPER_LIB_INSTALL_DIR}/static"
RUNTIME DESTINATION "${WHISPER_BIN_INSTALL_DIR}"
RESOURCE DESTINATION "${WHISPER_BIN_INSTALL_DIR}"
PUBLIC_HEADER DESTINATION "${WHISPER_INCLUDE_INSTALL_DIR}"

If the custom directories are removed, you can use the defaults, which are already compatible with windows (at least through vcpkg)

@petterreinholdtsen
Copy link
Contributor

This patch is now in conflict with the latest master branch.

@ggerganov Is there any hope to get install rules included in the cmake setup? I guess Windows compatibility is required?

@ggerganov
Copy link
Member

Is there any hope to get install rules included in the cmake setup? I guess Windows compatibility is required?

@petterreinholdtsen I thought they are already included. If it does not work on Windows, please propose a patch to fix it.

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.

4 participants