Forked from Stono/99-install-facetime-camera.sh
Last active
October 25, 2025 17:11
-
-
Save ukn/a2f85e3420ae7d0f64db2274a9bc106b to your computer and use it in GitHub Desktop.
Install the kernal module required for the facetimehd camera to work on Linux
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| set -e | |
| export CONFIG_MODULE_SIG=n | |
| export CONFIG_MODULE_SIG_ALL=n | |
| # For current kernel | |
| export KERNELRELEASE=$(cat /proc/version | awk '{print $3}') | |
| temp_dir=$(mktemp -d) | |
| echo "Installing FacetimeHD camera for $KERNELRELEASE" | |
| cd $temp_dir | |
| git clone https://github.com/patjak/facetimehd-firmware.git | |
| git clone https://github.com/patjak/bcwc_pcie.git | |
| cd $temp_dir/facetimehd-firmware | |
| pwd | |
| make | |
| make install | |
| cd $temp_dir/bcwc_pcie | |
| pwd | |
| make | |
| make install | |
| rm -rf $temp_dir | |
| if [ ! -d "/etc/modules-load.d" ]; then | |
| mkdir -p "/etc/modules-load.d" | |
| fi | |
| cat > "/etc/modules-load.d/facetimehd.conf" << EOL | |
| videobuf2-core | |
| videobuf2_v4l2 | |
| videobuf2-dma-sg | |
| facetimehd | |
| EOL | |
| # Workaround for depmod being skipped above with error: | |
| # Warning: modules_install: missing 'System.map' file. Skipping depmod | |
| echo "Generate modules.dep and map files" | |
| sudo depmod | |
| echo "Adding kernel modules" | |
| sudo modprobe -r bdc_pci | |
| sudo modprobe facetimehd | |
| echo "Install complete" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Wait it's fixed but I have encountered new error
Installing FacetimeHD camera for 6.8.0-1041-nvidia
Cloning into 'facetimehd-firmware'...
remote: Enumerating objects: 902, done.
remote: Counting objects: 100% (17/17), done.
remote: Compressing objects: 100% (12/12), done.
remote: Total 902 (delta 6), reused 14 (delta 5), pack-reused 885 (from 1)
Receiving objects: 100% (902/902), 301.25 KiB | 2.39 MiB/s, done.
Resolving deltas: 100% (591/591), done.
Cloning into 'bcwc_pcie'...
remote: Enumerating objects: 1183, done.
remote: Counting objects: 100% (56/56), done.
remote: Compressing objects: 100% (29/29), done.
remote: Total 1183 (delta 39), reused 28 (delta 27), pack-reused 1127 (from 3)
Receiving objects: 100% (1183/1183), 432.69 KiB | 870.00 KiB/s, done.
Resolving deltas: 100% (785/785), done.
/tmp/tmp.9W88Eeglrg/facetimehd-firmware
Checking dependencies for driver download...
/usr/bin/curl
/usr/bin/xzcat
/usr/bin/cpio
Downloading the driver, please wait...
Found matching hash from OS X, El Capitan 10.11.5
==> Extracting firmware...
--> Decompressing the firmware using gzip...
--> Deleting temporary files...
--> Extracted firmware version 1.43.0
Copying firmware into '//usr/lib/firmware/facetimehd'
/tmp/tmp.9W88Eeglrg/bcwc_pcie
make -C /lib/modules/6.8.0-1041-nvidia/build M=/tmp/tmp.9W88Eeglrg/bcwc_pcie modules
make[1]: Entering directory '/usr/src/linux-headers-6.8.0-1041-nvidia'
warning: the compiler differs from the one used to build the kernel
The kernel was built by: x86_64-linux-gnu-gcc-11 (Ubuntu 11.4.0-1ubuntu1
22.04.2) 11.4.022.04.2) 11.4.0You are using: gcc-11 (Ubuntu 11.4.0-1ubuntu1
CC [M] /tmp/tmp.9W88Eeglrg/bcwc_pcie/fthd_ddr.o
CC [M] /tmp/tmp.9W88Eeglrg/bcwc_pcie/fthd_hw.o
CC [M] /tmp/tmp.9W88Eeglrg/bcwc_pcie/fthd_drv.o
CC [M] /tmp/tmp.9W88Eeglrg/bcwc_pcie/fthd_ringbuf.o
CC [M] /tmp/tmp.9W88Eeglrg/bcwc_pcie/fthd_isp.o
CC [M] /tmp/tmp.9W88Eeglrg/bcwc_pcie/fthd_v4l2.o
CC [M] /tmp/tmp.9W88Eeglrg/bcwc_pcie/fthd_buffer.o
CC [M] /tmp/tmp.9W88Eeglrg/bcwc_pcie/fthd_debugfs.o
LD [M] /tmp/tmp.9W88Eeglrg/bcwc_pcie/facetimehd.o
MODPOST /tmp/tmp.9W88Eeglrg/bcwc_pcie/Module.symvers
CC [M] /tmp/tmp.9W88Eeglrg/bcwc_pcie/facetimehd.mod.o
LD [M] /tmp/tmp.9W88Eeglrg/bcwc_pcie/facetimehd.ko
BTF [M] /tmp/tmp.9W88Eeglrg/bcwc_pcie/facetimehd.ko
Skipping BTF generation for /tmp/tmp.9W88Eeglrg/bcwc_pcie/facetimehd.ko due to unavailability of vmlinux
make[1]: Leaving directory '/usr/src/linux-headers-6.8.0-1041-nvidia'
make -C /lib/modules/6.8.0-1041-nvidia/build M=/tmp/tmp.9W88Eeglrg/bcwc_pcie modules_install
make[1]: Entering directory '/usr/src/linux-headers-6.8.0-1041-nvidia'
INSTALL /lib/modules/6.8.0-1041-nvidia/updates/facetimehd.ko
SIGN /lib/modules/6.8.0-1041-nvidia/updates/facetimehd.ko
DEPMOD /lib/modules/6.8.0-1041-nvidia
Warning: modules_install: missing 'System.map' file. Skipping depmod.
make[1]: Leaving directory '/usr/src/linux-headers-6.8.0-1041-nvidia'
Generate modules.dep and map files
Adding kernel modules
modprobe: FATAL: Module bdc_pci not found.
Can anyone fix this? I'm using pop os