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

cdemu dont install on linux kubuntu with bullseye 11 #23

Open
estatistics opened this issue Apr 1, 2022 · 2 comments
Open

cdemu dont install on linux kubuntu with bullseye 11 #23

estatistics opened this issue Apr 1, 2022 · 2 comments

Comments

@estatistics
Copy link

cdemu dont install - see below.

uname -a
Linux eliasc 5.11.0-18-generic #19-Ubuntu SMP Fri May 7 14:22:03 UTC 2021 x86_64 GNU/Linux

lsb_release -a
LSB Version:  core-11.1.0ubuntu2-noarch:security-11.1.0ubuntu2-noarch
Distributor ID:    Debian
Description:    Debian GNU/Linux 11 (bullseye)
Release:    11
Codename:    bullseye

ls -la /lib/modules/`uname -r`/build
lrwxrwxrwx 1 root root 40 May  7  2021 /lib/modules/5.11.0-18-generic/build -> /usr/src/linux-headers-5.11.0-18-generic

sudo make
rm -f .cdemu*.{ko,mod.o,o}.cmd cdemu*.{ko,o,mod.{c,o}} *.pyc core *~
rm -rf .tmp_versions Modules.symvers
rm -f docs/cdemu.{dvi,pdf}
rm -f docs/cdemu.{info,txt,html}

BUG?

sudo make install
**** Installing files ****
install -D -m 644  /lib/modules/5.11.0-18-generic/misc/
install: missing destination file operand after '/lib/modules/5.11.0-18-generic/misc/'
Try 'install --help' for more information.
make: *** [Makefile:100: install] Error 1

@boltronics
Copy link

boltronics commented Jun 2, 2022

A Kubuntu kernel on a Debian 11 host? I can at least confirm it works fine using the stock Debian 11 kernel (5.10.113-1 from bullseye-security) with packages built using the documented dpkg-buildpackage -b -uc -tc command.

@alexanderbazhenoff
Copy link

alexanderbazhenoff commented Nov 13, 2023

@estatistics So Kubuntu virtual machine on Debian 11 host, right? Perhaps you didn't have kernel-headers installed on a target system (Debian 11). On my Debian 11 kernel module installed properly:

$ lsb_release -a                                                                                                                                                                                                                                                   
No LSB modules are available.
Distributor ID: Debian
Description:    Debian GNU/Linux 11 (bullseye)
Release:        11
Codename:       bullseye

$ uname -sr                                                                                                                                                                                                                                                        
Linux 5.10.0-26-amd64

$ lsmod | grep vhba                                                                                                                                                                                                                                                
vhba                   36864  0
scsi_mod              270336  7 vhba,sd_mod,usb_storage,uas,libata,sg,sr_mod

$ ls -la /lib/modules/`uname -r`/build                                                                                                                                                                                                                             
lrwxrwxrwx 1 root root 38 Sep 29 07:25 /lib/modules/5.10.0-26-amd64/build -> /usr/src/linux-headers-5.10.0-26-amd64

$ dpkg -l | grep linux-headers
ii  linux-headers-5.10.0-26-amd64                 5.10.197-1                                                      amd64        Header files for Linux 5.10.0-26-amd64
ii  linux-headers-5.10.0-26-common                5.10.197-1                                                      all          Common header files for Linux 5.10.0-26
ii  linux-headers-amd64                           5.10.197-1                                                      amd64        Header files for Linux amd64 configuration (meta-package)

So you can try:

cd vhba-module
make
sudo make install
cat /etc/group | grep cdrom
sudo reboot
sudo lsmod | grep vhba
# I have /lib/udev/rules.d/70-uaccess.rules already, so (check INSTALL file instructions):
sudo echo "KERNEL=="vhba_ctl", MODE="0660", OWNER="root", GROUP="cdrom"" > /lib/udev/rules.d/40-vhba.rules
# Then make it autoloadable:
sudo echo "vhba" > /etc/modules-load.d/vhba.conf

As @boltronics mentioned dpkg-buildpackage -b -uc -tc command can help you to see unmet dependencies. In my case I had an cmake error during libmirage build:

$ cd libmirage
$ mkdir build
$ cd build
$ cmake ..
CMake Error at /usr/share/cmake-3.18/Modules/FindPackageHandleStandardArgs.cmake:165 (message):
  Could NOT find IntlTool (missing: INTLTOOL_UPDATE_EXECUTABLE                                                                          
  INTLTOOL_EXTRACT_EXECUTABLE INTLTOOL_MERGE_EXECUTABLE                                                                                                                                                                                                                          
  INTLTOOL_PREPARE_EXECUTABLE) (Required is at least version "0.21")                                                                                                                                                                                                             
Call Stack (most recent call first):                                                                                                                                                                                                                                             
  /usr/share/cmake-3.18/Modules/FindPackageHandleStandardArgs.cmake:458 (_FPHSA_FAILURE_MESSAGE)
  cmake/FindIntlTool.cmake:30 (find_package_handle_standard_args)
  CMakeLists.txt:32 (find_package)

CMakeOutput.log on pastebin is also without an info. So running:

$ dpkg-buildpackage -b -uc -tc
dpkg-buildpackage: info: source package libmirage                                                                                                                                                                                                                                
dpkg-buildpackage: info: source version 3.2.6-1                                                                                                                                                                                                                                  
dpkg-buildpackage: info: source distribution debian                                                                                                                                                                                                                              
dpkg-buildpackage: info: source changed by Henrik Stokseth <hstokset@users.sourceforge.net>                                                                                                                                                                                      
dpkg-buildpackage: info: host architecture amd64                                                                                                                                                                                                                                 
 dpkg-source --before-build .                                                                                                                                                                                                                                                    
dpkg-checkbuilddeps: error: Unmet build dependencies: libsamplerate0-dev gtk-doc-tools gobject-introspection libgirepository1.0-dev intltool                                                                                                                                     

brought me a message with packages to install:

sudo apt install libsamplerate0-dev gtk-doc-tools gobject-introspection libgirepository1.0-dev intltool

You can also install cdemu packages without build from deb-multimedia:

sudo gpg --no-default-keyring --keyring /usr/share/keyrings/deb-multimedia.gpg --keyserver keyserver.ubuntu.com --recv-keys 5C808C2B65558117
echo "deb [signed-by=/usr/share/keyrings/deb-multimedia.gpg] \
https://www.deb-multimedia.org $(lsb_release -sc) main non-free" \
| sudo tee /etc/apt/sources.list.d/deb-multimedia.list
sudo apt update
apt install vhba-dkms cdemu-client cdemu-daemon gcdemu

But both ways (building from sources and install from packages) you could add systemd unit if you wish to enable autostart of cdemu-daemon:

# cat /.config/systemd/user/cdemu-daemon.service

[Unit]
Description=cdemu-daemon

[Service]
Type=simple
ExecStart=/usr/bin/cdemu-daemon
StandardOutput=syslog
StandardError=syslog
TimeoutStartSec=0

[Install]
WantedBy=default.target

then:

systemctl --user daemon-reload
systemctl --user enable cdemu-daemon --now

Hope it helps now.

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

No branches or pull requests

3 participants