-
Notifications
You must be signed in to change notification settings - Fork 71
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
Debian package for liblsl depends on itself. #192
Comments
If I had to guess, I'd say it's due to this block of CMake script. If you are able, can you help narrow it down? |
I haven't encountered creation of the debian package structure directly through CMake before, which is interesting. I don't have time to set up build environment just now, but I'd hazard a guess the simplest solution: list(REMOVE_ITEM LSLDEPENDS ${component}) if it's winding up including itself in the list. |
Interesting problem. dpkg itself installs the problem without any warning, but other dpkg frontends can get confused. liblsl gets added to the dependencies by default because the automatic package dependency discovery doesn't work for libraries built in the same step. This should just need a single diff --git a/cmake/LSLCMake.cmake b/cmake/LSLCMake.cmake
index 665aeb4..f64b001 100644
--- a/cmake/LSLCMake.cmake
+++ b/cmake/LSLCMake.cmake
@@ -137,8 +137,9 @@ function(installLSLApp target)
install(CODE "file(INSTALL $<TARGET_FILE:${libdependency}> DESTINATION \${CMAKE_INSTALL_PREFIX}/$<IF:$<PLATFORM_ID:Windows>,${CMAKE_INSTALL_BINDIR},${CMAKE_INSTALL_LIBDIR}>)")
endforeach()
- set_property(GLOBAL APPEND PROPERTY
- "LSLDEPENDS_${PROJECT_NAME}" liblsl)
+ if(NOT PROJECT_NAME STREQUAL "liblsl")
+ set_property(GLOBAL APPEND PROPERTY "LSLDEPENDS_${PROJECT_NAME}" liblsl)
+ endif()
install(TARGETS ${target} COMPONENT ${PROJECT_NAME}
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} Result:
|
Yeah, I figured that might be why - other tools do depend on the library. Either an if statement or removing the current package name should work. Also, FYI, the reason dpkg works is it doesn't check or attempt to fetch dependencies. Installing breaks my system and it does tell me this, bit goes ahead and does it anyway, whilst gdebi refuses to continue with constraints it can't satisfy. I presume using apt would find the same, were the package in e.g. a PPA. |
I have downloaded the liblsl package for focal, and I cannot install it:
# gdebi /tmp/liblsl-1.16.1-focal_amd64.deb Reading package lists... Done Building dependency tree Reading state information... Done Reading state information... Done This package is uninstallable Dependency is not satisfiable: liblsl (= 1.16.1-focal)
If I look at the control file:
It seems likely the problem is caused by the issue that the package depends on itself. I had to forcibly install it using
dpkg
, and then go back again withgdebi
to get the dependencies installed, which was now able to complete because the same package it was trying to install was on the system already.The text was updated successfully, but these errors were encountered: