jackun / USBqemu-wheel

PCSX2 usb plugin for wheels and increasingly more stuff
The Unlicense
121 stars 21 forks source link

How compile without PulseAudio ? #70

Open inukaze opened 2 years ago

inukaze commented 2 years ago

Hi there, what is the argument / parameter to specify don't compile against PulseAudio ?

i try to do the follow :

wget -c 'https://github.com/jackun/USBqemu-wheel/archive/refs/tags/0.10.0.tar.gz' -O "USBqemu-wheel-0.10.0.tar.gz"
tar xfz USBqemu-wheel-0.10.0.tar.gz
cd USBqemu-wheel-0.10.0
mkdir -p build ; cd build
cmake ..
cd ..

and the output of cmake .. show this :

[ 46%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-mic/audiodev-pulse.cpp.o In file included from /tmp/USBqemu-wheel-0.10.0/src/usb-mic/audiodev-pulse.cpp:2:0: /tmp/USBqemu-wheel-0.10.0/src/usb-mic/audiodev-pulse.h:3:30: error fatal: pulse/pulseaudio.h: No existe el fichero o el directorio compilación terminada. CMakeFiles/USBqemu-wheel.dir/build.make:374: fallo en las instrucciones para el objetivo 'CMakeFiles/USBqemu-wheel.dir/src/usb-mic/audiodev-pulse.cpp.o' make[2]: [CMakeFiles/USBqemu-wheel.dir/src/usb-mic/audiodev-pulse.cpp.o] Error 1 CMakeFiles/Makefile2:75: fallo en las instrucciones para el objetivo 'CMakeFiles/USBqemu-wheel.dir/all' make[1]: [CMakeFiles/USBqemu-wheel.dir/all] Error 2 Makefile:129: fallo en las instrucciones para el objetivo 'all' make: *** [all] Error 2

the README i don't understand the part about pulseaudio, because don't tell nothing about variables, arguments / parameters for compile.

i try with :

cd build
cmake -DCMAKE-PLUGIN_BUILD_PULSE=FALSE -DCMAKE-PLUGIN_BUILD_DYNLINK_PULSE=FALSE

But i just got this message :

Manually-specified variables were not used by the project:

CMAKE-PLUGIN_BUILD_DYNLINK_PULSE
CMAKE-PLUGIN_BUILD_PULSE
jackun commented 2 years ago

It's just -DPLUGIN_BUILD_PULSE=OFF

inukaze commented 2 years ago

Ok thank you very much here i go again :

wget -c 'https://github.com/jackun/USBqemu-wheel/archive/refs/tags/0.10.0.tar.gz' -O "USBqemu-wheel-0.10.0.tar.gz"
tar xfz USBqemu-wheel-0.10.0.tar.gz
cd USBqemu-wheel-0.10.0
mkdir -p build ; cd build
cmake -DPLUGIN_BUILD_PULSE=OFF ..

-- The C compiler identification is GNU 5.5.0 -- The CXX compiler identification is GNU 5.5.0 -- Check for working C compiler: /usr/bin/cc -- Check for working C compiler: /usr/bin/cc -- works -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Detecting C compile features -- Detecting C compile features - done -- Check for working CXX compiler: /usr/bin/c++ -- Check for working CXX compiler: /usr/bin/c++ -- works -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Detecting CXX compile features -- Detecting CXX compile features - done -- Found PkgConfig: /usr/bin/pkg-config (found version "0.29.2") Define _DEBUG for debug print. -- Found GTK2_GTK: /usr/lib/libgtk-x11-2.0.so
-- Checking for module 'harfbuzz' -- Found harfbuzz, version 1.2.7 -- Configuring done -- Generating done -- Build files have been written to: /tmp/USBqemu-wheel-0.10.0/build

make

Scanning dependencies of target USBqemu-wheel [ 1%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/linux/config.cpp.o [ 3%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/linux/config-gtk.cpp.o [ 5%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/linux/util.cpp.o [ 7%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/USB.cpp.o [ 9%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/deviceproxy.cpp.o [ 11%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/configuration.cpp.o [ 13%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/osdebugout.cpp.o [ 15%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/device_init.cpp.o [ 17%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/icon_buzz_24.cpp.o [ 19%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/qemu-usb/glib.cpp.o [ 21%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/qemu-usb/vl.cpp.o [ 23%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/qemu-usb/iov.cpp.o [ 25%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/qemu-usb/desc.cpp.o [ 26%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/qemu-usb/core.cpp.o [ 28%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/qemu-usb/bus.cpp.o [ 30%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/qemu-usb/usb-ohci.cpp.o [ 32%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/qemu-usb/hid.cpp.o [ 34%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/qemu-usb/input-keymap-qcode-to-qnum.cpp.o [ 36%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/qemu-usb/input-keymap-linux-to-qcode.cpp.o [ 38%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-msd/usb-msd.cpp.o [ 40%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-msd/usb-msd-gtk.cpp.o [ 42%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-mic/usb-mic-singstar.cpp.o [ 44%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-mic/usb-mic-logitech.cpp.o [ 46%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-mic/usb-headset.cpp.o [ 48%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-pad/usb-pad.cpp.o [ 50%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-pad/usb-pad-ff.cpp.o [ 51%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-pad/lg/lg_ff.cpp.o [ 53%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-pad/joydev/joydev.cpp.o [ 55%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-pad/joydev/joydev-gtk.cpp.o [ 57%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-pad/evdev/shared-gtk.cpp.o [ 59%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-pad/evdev/evdev-ff.cpp.o [ 61%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-pad/evdev/evdev.cpp.o [ 63%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-pad/evdev/evdev-gtk.cpp.o [ 65%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-hid/usb-hid.cpp.o [ 67%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-hid/evdev/evdev.cpp.o [ 69%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-hid/evdev/evdev-gtk.cpp.o [ 71%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-eyetoy/jpgd/jpgd.cpp.o [ 73%] Building C object CMakeFiles/USBqemu-wheel.dir/src/usb-eyetoy/jo_mpeg.c.o [ 75%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-eyetoy/usb-eyetoy-webcam.cpp.o [ 76%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-eyetoy/cam-linux.cpp.o [ 78%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/shared/shared.cpp.o [ 80%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/shared/inifile.cpp.o [ 82%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/shared/ringbuffer.cpp.o [ 84%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-eyetoy/api_init_linux.cpp.o [ 86%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-hid/api_init_linux.cpp.o [ 88%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-mic/api_init_linux.cpp.o In file included from /tmp/USBqemu-wheel-0.10.0/src/usb-mic/api_init_linux.cpp:3:0:

/tmp/USBqemu-wheel-0.10.0/src/usb-mic/audiodev-pulse.h:3:30: error fatal: pulse/pulseaudio.h: No existe el fichero o el directorio

compilación terminada.

CMakeFiles/USBqemu-wheel.dir/build.make:647: fallo en las instrucciones para el objetivo 'CMakeFiles/USBqemu-wheel.dir/src/usb-mic/api_init_linux.cpp.o' make[2]: *** [CMakeFiles/USBqemu-wheel.dir/src/usb-mic/api_init_linux.cpp.o] Error 1 CMakeFiles/Makefile2:75: fallo en las instrucciones para el objetivo 'CMakeFiles/USBqemu-wheel.dir/all'

make[1]: [CMakeFiles/USBqemu-wheel.dir/all] Error 2 Makefile:129: fallo en las instrucciones para el objetivo 'all' make: [all] Error 2

cd ..

Well still need file "pulseaudio.h". what i should do for the compilation does not need any file related to pulseaudio ?

jackun commented 2 years ago

Ah crap, I guess i didn't #ifdef includes out too. Just delete or comment out (with //) every #include <pulseaudio.h> etc that appear in error log :P

inukaze commented 2 years ago

Hi there, i make it

first i edit the file /tmp/USBqemu-wheel-0.10.0/src/usb-mic/api_init_linux.cpp

and leave the file like this :

#include "audiodeviceproxy.h"
#include "audiodev-noop.h"
//#include "audiodev-pulse.h"

void usb_mic::RegisterAudioDevice::Register()
{
    auto& inst = RegisterAudioDevice::instance();
    inst.Add(audiodev_noop::APINAME, new AudioDeviceProxy<audiodev_noop::NoopAudioDevice>());
//  inst.Add(audiodev_pulse::APINAME, new AudioDeviceProxy<audiodev_pulse::PulseAudioDevice>());
}

make

Scanning dependencies of target USBqemu-wheel [ 1%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-mic/api_init_linux.cpp.o [ 3%] Building CXX object CMakeFiles/USBqemu-wheel.dir/src/usb-pad/api_init_linux.cpp.o [ 5%] Building C object CMakeFiles/USBqemu-wheel.dir/src/libsamplerate/samplerate.c.o [ 7%] Building C object CMakeFiles/USBqemu-wheel.dir/src/libsamplerate/src_linear.c.o [ 9%] Building C object CMakeFiles/USBqemu-wheel.dir/src/libsamplerate/src_sinc.c.o [ 11%] Building C object CMakeFiles/USBqemu-wheel.dir/src/libsamplerate/src_zoh.c.o [ 13%] Linking CXX shared library libUSBqemu-wheel-0.10.0.so

Well i already had the plugin :D pcsx2-usb0

Well the plugin not had « PSP Connection » / « PPSSPP Connection » pcsx2-usb

:'( like "Dolphin-Emu" + "mGBA"(-qt) or "VBAM". Well thanks you anyway :D