pi-apps
pi-apps copied to clipboard
DroidCam
DroidCam on Raspberry Pi
I have created the install script, but can't find a way to make the uninstall script.
Here is the project link --> https://github.com/open-sorcerer64/Droid-Cam-RPi
@Itai-Nelken and @Botspot what do you think
BTW, Get well soon @Botspot
No update guys!
Sorry, I don't have time to review the scripts right now. But it's on my todo list.
Why do use && in every command, and also why do you install every dependency with one separate command, and instead of providing the tar.gz cant you provide the pre built deb, and what should the droidcam-raspberrypi-auto-install folder have ? Also aren't you installing/building in the droidcam-raspberrypi-auto-install directory so shouldn't removing that and uninstalling the dependencies be enough for uninstalling the app?
Hello
Why do use
&&in every command, and also why do you install every dependency with one separate command
I didn't knew that you can run the script even without using && which I will improve. I installed every dependency with a separate command because I was afraid of breaking the script, also this script will use pkg-install when it comes on Pi-Apps
and instead of providing the tar.gz cant you provide the pre built deb
I don't know how to make debs or make apt repos, so....... You can help me if you know, on my Discord
and what should the
droidcam-raspberrypi-auto-installfolder have
The script and the repository, I guess
I don't know how to make
debsor make apt repos, so......
Are you not making and installing a deb here
sudo make install
sudo make deb
sudo dpkg -i libjpeg-turbo_2.1.0_armhf.deb
Cant you just add that deb file to your repo so that your dont have to build it every time
Hello everyone
So, I have made the deb files as insisted by @techcoder20 you can see it at https://github.com/open-sorcerer64/Droid-Cam-RPi/tree/deb-testing I have not created the scripts as I am not sure if this will work or not, but it should be simple. I have done other things like adding the icon and stuff DroidCam.zip
@Itai-Nelken and @Botspot what do you think
Anyone who checked??
if the debs work than all that's left to do is to write the scripts. unfortunately we don't really have time for that... so can you write the scripts? if you need help just ask.
I can't make the script! Things aren't working and also I have exams. Can you do it @Botspot?
Anyone
we don't have the time to make the scripts...
we don't have the time to make the scripts...
Neither do I, so..... I think we should suspend this issue for now.
Hello
Guys, I have made the install and uninstall scripts for both 32 and 64 bit. Please check
Also, I know it isn't perfect as we need to add desktop icons and stuff but I'll do it after the scripts are approved by @Botspot
Not working for me, it shows the error:
Installing DroidCam...
Cloning into 'Droid-Cam-RPi'...
Running pkg-install...
Running sudo apt update...
Hit:1 https://packages.microsoft.com/ubuntu/21.04/prod hirsute InRelease
Hit:2 https://itai-nelken.github.io/weekly-box86-debs/debian InRelease
Hit:3 http://archive.raspberrypi.org/debian buster InRelease
Hit:4 http://raspbian.raspberrypi.org/raspbian buster InRelease
Hit:5 https://deb.oxen.io buster InRelease
Hit:6 http://download.opensuse.org/repositories/home:/SmartFinn:/hardcode-tray/Debian_10 InRelease
Hit:7 https://download.docker.com/linux/raspbian buster InRelease
All packages are up to date.
Installing local libjpeg-turbo package...
libjpeg-turbo is already the newest version (2.1.0-20210803).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
libjpeg-turbo set to automatically installed.
Creating dummy deb...
Installing dummy deb...
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
pi-apps-45c61c0c : Depends: gtk-3.0 but it is not installable
E: Unable to correct problems, you have held broken packages.
Apt finished.
Failed to install the packages!
APT reported these errors:
E: Unable to correct problems, you have held broken packages.
Cloning into 'droidcam'...
gcc -Wall -O2 src/droidcam-cli.c src/connection.c src/settings.c src/decoder.c src/decoder_snd.c src/decoder_v4l2.c src/av.c src/usb.c src/queue.c -o droidcam-cli -I/opt/libjpeg-turbo/include /opt/libjpeg-turbo/lib`getconf LONG_BIT`/libturbojpeg.a `pkg-config --libs --cflags libswscale libavutil` -lspeex -lasound -lpthread -lm -lusbmuxd
gcc -Wall -O2 src/droidcam.c src/resources.c src/connection.c src/settings.c src/decoder.c src/decoder_snd.c src/decoder_v4l2.c src/av.c src/usb.c src/queue.c -o droidcam `pkg-config --libs --cflags gtk+-3.0` `pkg-config --libs x11` `pkg-config --cflags --libs appindicator3-0.1` -I/opt/libjpeg-turbo/include /opt/libjpeg-turbo/lib`getconf LONG_BIT`/libturbojpeg.a `pkg-config --libs --cflags libswscale libavutil` -lspeex -lasound -lpthread -lm -lusbmuxd
src/droidcam.c: In function ‘the_callback’:
src/droidcam.c:276:4: warning: ‘gtk_menu_popup’ is deprecated: Use '(gtk_menu_popup_at_widget, gtk_menu_popup_at_pointer, gtk_menu_popup_at_rect)' instead [-Wdeprecated-declarations]
gtk_menu_popup(GTK_MENU(menu), NULL, NULL, NULL, NULL, 0, 0);
^~~~~~~~~~~~~~
In file included from /usr/include/gtk-3.0/gtk/gtklabel.h:34,
from /usr/include/gtk-3.0/gtk/gtkaccellabel.h:35,
from /usr/include/gtk-3.0/gtk/gtk.h:33,
from src/droidcam.c:9:
/usr/include/gtk-3.0/gtk/gtkmenu.h:138:9: note: declared here
void gtk_menu_popup (GtkMenu *menu,
^~~~~~~~~~~~~~
src/droidcam.c:281:4: warning: ‘gtk_menu_popup’ is deprecated: Use '(gtk_menu_popup_at_widget, gtk_menu_popup_at_pointer, gtk_menu_popup_at_rect)' instead [-Wdeprecated-declarations]
gtk_menu_popup(GTK_MENU(wbMenu), NULL, NULL, NULL, NULL, 0, 0);
^~~~~~~~~~~~~~
In file included from /usr/include/gtk-3.0/gtk/gtklabel.h:34,
from /usr/include/gtk-3.0/gtk/gtkaccellabel.h:35,
from /usr/include/gtk-3.0/gtk/gtk.h:33,
from src/droidcam.c:9:
/usr/include/gtk-3.0/gtk/gtkmenu.h:138:9: note: declared here
void gtk_menu_popup (GtkMenu *menu,
^~~~~~~~~~~~~~
Copying files
+ cp uninstall /opt/droidcam-uninstall
+ cp icon2.png /opt/droidcam-icon.png
+ cp droidcam /usr/local/bin/
+ cp droidcam-cli /usr/local/bin/
+ set +x
Done
Webcam parameters: '640' and '480'
Building v4l2loopback-dc.ko
make: Entering directory '/home/pi/droidcam/v4l2loopback'
make -C /lib/modules/5.10.63-v8+/build M=/home/pi/droidcam/v4l2loopback modules
make[1]: Entering directory '/home/pi/droidcam/v4l2loopback'
make[1]: *** /lib/modules/5.10.63-v8+/build: No such file or directory. Stop.
make[1]: Leaving directory '/home/pi/droidcam/v4l2loopback'
make: *** [Makefile:8: all] Error 2
make: Leaving directory '/home/pi/droidcam/v4l2loopback'
Failed to install DroidCam!
🔺Need help? Copy the ENTIRE terminal output or take a screenshot.
Please ask on Github: https://github.com/Botspot/pi-apps/issues/new/choose
Or on Discord: https://discord.gg/RXSTvaUvuu
@cycool29 your apt repos are PROBABLY corrupt. Can you please try to fix it. Also, for now you can install the dependencies from apt if pkg-install doesn't work.
@Botspot can you please check
That isn't a messed up apt. the package gtk-3.0 doesn't exist.
also the error that stopped the script is make[1]: *** /lib/modules/5.10.63-v8+/build: No such file or directory. Stop.
@cycool29 can you please install cmake and try again
@cycool29 can you please install
cmakeand try again
That's not the problem, the problem is this line: make[1]: *** /lib/modules/5.10.63-v8+/build: No such file or directory. Stop.
Specifically /lib/modules/5.10.63-v8+/build: No such file or directory..
@cycool29 can you please install
cmakeand try again
Sorry for the late reply.
Well I found I messed up my kernel and I reflashed my pi and the make[1]: *** /lib/modules/5.10.63-v8+/build: No such file or directory. Stop. problem solved.
I have improved your scripts in :
- Use
git_clone - Install
libjpeg-turbo_2.1.0_armhf.debwithpkg-install - Added
libasound2-devfor audio and removedgtk+-3.0as it is not a package but regex - Added
libplist-dev(from the dependencies list) - Added
sudo ./install-soundfor audio - Added few error messages
- Use sudo if make failed
- Use sudo for uninstallation
- Cleanup after installation (remove
Droid-Cam-RPifolder)
Tested on RPi OS armhf, works well with Google Meet, will test later with Zoom.
@cycool29 can you please install
cmakeand try againThat's not the problem, the problem is this line:
make[1]: *** /lib/modules/5.10.63-v8+/build: No such file or directory. Stop.Specifically/lib/modules/5.10.63-v8+/build: No such file or directory..
I didn't face this issue
@cycool29 can you please install
cmakeand try againSorry for the late reply.
Well I found I messed up my kernel and I reflashed my pi and the
make[1]: *** /lib/modules/5.10.63-v8+/build: No such file or directory. Stop.problem solved.I have improved your scripts in :
- Use
git_clone- Install
libjpeg-turbo_2.1.0_armhf.debwithpkg-install- Added
libasound2-devfor audio and removedgtk+-3.0as it is not a package but regex- Added
libplist-dev(from the dependencies list)- Added
sudo ./install-soundfor audio- Added few error messages
- Use sudo if make failed
- Use sudo for uninstallation
- Cleanup after installation (remove
Droid-Cam-RPifolder)Tested on RPi OS armhf, works well with Google Meet, will test later with Zoom.
Thanks 😊
It works with zoom. I am going to see if there's a new version of libjpeg-turbo that we can use
Also, can anyone test it on 64 bit? The process should be same except you'll have to install the arm64 version of libjpeg-turbo.
I just found a new version of libjpeg-turbo. I am adding it to the script and project file
@Botspot DroidCam.zip DroidCam is now completely ready for testing and merging it to Pi-Apps
Also, I think gtk+-3.0 is important but I am not sure
It gave me an error without it
Also, I think
gtk+-3.0is important but I am not sureIt gave me an error without it
The gtk+-3.0 is not a apt package, it is a regex.
The name for it on apt is libgtk-3-dev. I think libgtk-3-dev and build-essential should be added to the pkg-install
But sometimes pkg-config can't find the gtk+-3.0. This often occurs if the PKG_CONFIG_PATH variable is not set correctly. So I added these few lines on my improved script:
#unset PKG_CONFIG_PATH if pkg-config unable to find gtk+3.0
if ! pkg-config --modversion gtk+3.0 &>/dev/null; then
unset PKG_CONFIG_PATH
fi
This will check if pkg-config is able to find gtk+-3.0, if false, unset PKG_CONFIG_PATH .
This solution is from this stackoverflow answer.
However, from the stackoverflow link, unsetting PKG_CONFIG_PATH sometimes won't fix the problem. It needs further debug and check for the correct path for PKG_CONFIG_PATH, but this is a bit hard for the script to do so for the user. Maybe we can add these lines in the install script:
# Check again if pkg-config is able to find gtk+-3.0 module
if ! pkg-config --modversion gtk+3.0 &>/dev/null; then
error "pkg-config failed to find gtk+-3.0 module! \nPlease follow the instruction from https://stackoverflow.com/a/50038996 and run the script again."
fi
Any updates on this? I think it is ready to put on pi-apps. @Botspot
Except for the
gtk+-3.0problem. Everything works
You said you got an error without it, what is the error?
@Botspot DroidCam is ready to be added to Pi-Apps
@Botspot DroidCam is ready to be added to Pi-Apps
PR #1323 still has open suggestions to be made. Once all discussion is done I'd expect it can be merged.
https://github.com/Botspot/pi-apps/pull/1239