mirror of
https://github.com/ISpillMyDrink/OpenSuperClone.git
synced 2026-05-03 21:40:33 +00:00
Build system fixes
This commit is contained in:
+5
-1
@@ -16,4 +16,8 @@ pkg_check_modules(LIBCONFIG REQUIRED libconfig)
|
||||
add_subdirectory(opensuperclone)
|
||||
add_subdirectory(oscdriver)
|
||||
add_subdirectory(oscviewer)
|
||||
add_subdirectory(mininvme)
|
||||
add_subdirectory(mininvme)
|
||||
|
||||
# Configure the postinst and prerm scripts for the DEB package and put them in the root of the build directory
|
||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/postinst.in ${CMAKE_BINARY_DIR}/postinst)
|
||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/prerm.in ${CMAKE_BINARY_DIR}/prerm)
|
||||
@@ -1,16 +1,16 @@
|
||||
set(SOURCES
|
||||
driver.h
|
||||
ioctl.c
|
||||
ioctl.h
|
||||
main.c
|
||||
minipci.h
|
||||
nvme.c
|
||||
nvme.h
|
||||
)
|
||||
|
||||
# Configure the DKMS config file
|
||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/dkms.conf.in ${CMAKE_CURRENT_BINARY_DIR}/dkms.conf)
|
||||
|
||||
# Configure the postinst and prerm scripts for the DEB package and put them in the root of the build directory
|
||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/postinst.in ${CMAKE_BINARY_DIR}/postinst)
|
||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/prerm.in ${CMAKE_BINARY_DIR}/prerm)
|
||||
|
||||
# Install the driver to the source directory
|
||||
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/dkms.conf DESTINATION ${CMAKE_INSTALL_PREFIX}/src/mininvme-${OSC_DRIVER_VERSION})
|
||||
install(FILES ${SOURCES} DESTINATION ${CMAKE_INSTALL_PREFIX}/src/mininvme-${OSC_DRIVER_VERSION})
|
||||
|
||||
@@ -1,8 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
if command -v dkms >/dev/null; then
|
||||
dkms install mininvme/@MININVME_VERSION@
|
||||
else
|
||||
echo "WARNING: DKMS is not installed, skipping driver installation."
|
||||
echo "To use native NVMe support you will have to install the driver manually."
|
||||
fi
|
||||
@@ -1,8 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
if command -v dkms >/dev/null; then
|
||||
dkms remove mininvme/@MININVME_VERSION@ --all
|
||||
else
|
||||
echo "WARNING: DKMS is not installed, skipping driver removal."
|
||||
echo "If the driver was installed manually, it will not be removed."
|
||||
fi
|
||||
@@ -8,10 +8,6 @@ configure_file(${CMAKE_CURRENT_SOURCE_DIR}/config.h.in ${CMAKE_CURRENT_BINARY_DI
|
||||
# Configure the DKMS config file
|
||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/dkms.conf.in ${CMAKE_CURRENT_BINARY_DIR}/dkms.conf)
|
||||
|
||||
# Configure the postinst and prerm scripts for the DEB package and put them in the root of the build directory
|
||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/postinst.in ${CMAKE_BINARY_DIR}/postinst)
|
||||
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/prerm.in ${CMAKE_BINARY_DIR}/prerm)
|
||||
|
||||
# Install the driver to the source directory
|
||||
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/config.h DESTINATION ${CMAKE_INSTALL_PREFIX}/src/oscdriver-${OSC_DRIVER_VERSION})
|
||||
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/dkms.conf DESTINATION ${CMAKE_INSTALL_PREFIX}/src/oscdriver-${OSC_DRIVER_VERSION})
|
||||
|
||||
@@ -6,3 +6,10 @@ else
|
||||
echo "WARNING: DKMS is not installed, skipping driver installation."
|
||||
echo "To use the advanced features of OpenSuperClone you will have to install the driver manually."
|
||||
fi
|
||||
|
||||
if command -v dkms >/dev/null; then
|
||||
dkms install mininvme/@MININVME_VERSION@
|
||||
else
|
||||
echo "WARNING: DKMS is not installed, skipping driver installation."
|
||||
echo "To use native NVMe support you will have to install the driver manually."
|
||||
fi
|
||||
@@ -6,3 +6,10 @@ else
|
||||
echo "WARNING: DKMS is not installed, skipping driver removal."
|
||||
echo "If the driver was installed manually, it will not be removed."
|
||||
fi
|
||||
|
||||
if command -v dkms >/dev/null; then
|
||||
dkms remove mininvme/@MININVME_VERSION@ --all
|
||||
else
|
||||
echo "WARNING: DKMS is not installed, skipping driver removal."
|
||||
echo "If the driver was installed manually, it will not be removed."
|
||||
fi
|
||||
Reference in New Issue
Block a user