Package Details: cp210x 2019.7.12-3

Git Clone URL: https://aur.archlinux.org/cp210x.git (read-only, click to copy)
Package Base: cp210x
Description: Silicon Labs CP210x RS232 serial adaptor driver
Upstream URL: https://www.silabs.com/products/development-tools/software/usb-to-uart-bridge-vcp-drivers
Licenses: GPL
Submitter: amenzhinsky
Maintainer: amenzhinsky
Last Packager: amenzhinsky
Votes: 2
Popularity: 0.50
First Submitted: 2019-07-30 07:13
Last Updated: 2019-12-19 10:49

Latest Comments

amenzhinsky commented on 2020-01-20 19:13

@bbgun7 this is done on purpose, for example when you update the kernel but uname -r still reports the current version that makes it build modules for an outdated kernel.

pacman -Qo /usr/src/linux/version
/usr/lib/modules/5.4.13-arch1-1/build/version is owned by linux-headers 5.4.13.arch1-1

PKGBUILD has it as a dependency: https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=cp210x#n12

How do you build the package?

bbgun7 commented on 2020-01-20 18:18

The PKGBUILD uses /usr/src/linux/version to get the KVERSION, however I don't seem to have anything in /usr/src so the build fails since that file doesn't exist. Would it be possible to use something like uname -r instead? Thanks!

amenzhinsky commented on 2019-12-19 10:40

@lennart thanks for the catch, extramodules have been removed from the kernel package recently, I'll update PKGBUILD soon.

lennart commented on 2019-12-18 22:08

In order to build, I needed to adjust the contained Makefile (via sed) and the build/package procedure like this:

diff --git a/PKGBUILD b/PKGBUILD
index 42e1099..f4fc8b5 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -10,18 +10,18 @@ arch=('any')
 license=('GPL')
 depends=('linux')
 makedepends=('linux-headers')
-_extramodules=extramodules-ARCH
+_basekernelver=$(uname -r)
 source=("https://www.silabs.com/documents/login/software/Linux_3.x.x_4.x.x_VCP_Driver_Source.zip"
         dkms.conf)
 sha256sums=('7d624cd66ee610fd9c6598793534ed593ac1309b3d3b3699c101d921ad9ccd7c'
             '62da72a3f8f9566326168a759cb5cc54b8c39aeb6594e1b4229774868c7eb3d2')

 build() {
-  make KVERSION="$(cat /usr/lib/modules/$_extramodules/version)"
+  make KVERSION="$(cat /usr/lib/modules/$_basekernelver/version)"
 }

 package_cp210x() {
-  install -Dt "$pkgdir/usr/lib/modules/$_extramodules" -m644 *.ko
+  install -Dt "$pkgdir/usr/lib/modules/$_basekernelver" -m644 *.ko
   find "$pkgdir" -name '*.ko' -exec xz {} +

   echo cp210x | install -Dm644 /dev/stdin "$pkgdir/usr/lib/modules-load.d/cp210x.conf"
@@ -34,6 +34,7 @@ package_cp210x-dkms() {
   provides=("cp210x=$pkgver-$pkgrel")
   conflicts=(cp210x)

+  sed -i 's/`uname -r`/$(KVERSION)/' Makefile
   install -Dt "$pkgdir/usr/src/$pkgbase-$pkgver" -m644 Makefile cp210x.c dkms.conf

   echo cp210x | install -Dm644 /dev/stdin "$pkgdir/usr/lib/modules-load.d/cp210x.conf"

amenzhinsky commented on 2019-11-19 13:50

@gabriel-del You should rebuild the package after every kernel update or use the dkms version.

gabriel-del commented on 2019-11-19 13:31

It wasn't compiling but:

ln -s 5.3.11-arch1-1/ 5.3.8-arch1-1

resolved.