diff --git a/modem/samsungipcd/90-ttywc.rules b/modem/samsungipcd/90-ttywc.rules new file mode 100644 index 000000000..b45afd93b --- /dev/null +++ b/modem/samsungipcd/90-ttywc.rules @@ -0,0 +1,2 @@ +KERNEL=="ttywc", ENV{ID_MM_DEVICE_PROCESS}="1" +KERNEL=="ttywd", ENV{ID_MM_DEVICE_PROCESS}="1" diff --git a/modem/samsungipcd/APKBUILD b/modem/samsungipcd/APKBUILD new file mode 100644 index 000000000..776e4a65a --- /dev/null +++ b/modem/samsungipcd/APKBUILD @@ -0,0 +1,40 @@ +# Maintainer: sleirsgoevy +pkgname=samsungipcd +pkgver=0.1 +pkgrel=0 +pkgdesc="AT modem emulation using libsamsung-ipc" +url="https://gitlab.com/sleirsgoevy/samsungipcd" +arch="all" +license="GPL-2.0-or-later" +depends="libsamsung-ipc" +makedepends="libsamsung-ipc gcc make" +subpackages="$pkgname-openrc" +source=" + samsungipcd-v$pkgver.tgz::$url/-/archive/v$pkgver/samsungipcd-v$pkgver.tar.gz + samsungipcd.sh + 90-ttywc.rules +" +builddir="$srcdir/samsungipcd-v$pkgver" + +options="!check" + +build() { + make +} + +package() { + make PREFIX="$pkgdir/usr" install +} + +openrc() { + install -Dm755 "$srcdir/samsungipcd.sh" "$subpkgdir/etc/init.d/samsungipcd" + install -Dm644 "$srcdir/90-ttywc.rules" "$subpkgdir/lib/udev/rules.d/90-ttywc.rules" + mkdir -p "$subpkgdir/etc/runlevels/sysinit" + ln -s /etc/init.d/samsungipcd "$subpkgdir/etc/runlevels/sysinit" +} + +sha512sums=" +7a10e382fcd8fd454a94f650d08f30b3e4a7356952cdc68b85ee08bd1bd7d2e2ed1ea0ac4e144d998702fcfc94a5b13add7b9894ba0d05870d441521ebbe1242 samsungipcd-v0.1.tgz +20434087be921586b9e695bdbac92eb20d2eb2cdef7c2d0e946c59d7eb7b44e4c988e44ce8d7649e90ab682845ffc9b343367529243a02b18b3ed88a819669c1 samsungipcd.sh +580cb6ea86e81f85e73259d1738c2d2376f3c215e5cdb6691df39a17fb665931738b35ce4af0f7d983e795a9ea03d9ff05109302d04726f3482cb31f0e229661 90-ttywc.rules +" diff --git a/modem/samsungipcd/samsungipcd.sh b/modem/samsungipcd/samsungipcd.sh new file mode 100644 index 000000000..f5350657f --- /dev/null +++ b/modem/samsungipcd/samsungipcd.sh @@ -0,0 +1,8 @@ +#!/sbin/openrc-run + +description="AT modem emulation using libsamsung-ipc" +depends="ppp" + +command="samsungipcd" +command_args="/dev/ptywc /dev/ptywd" +supervisor="supervise-daemon"