Skip to content

Commit

Permalink
Add scam+wicardd, aarch64 fixes
Browse files Browse the repository at this point in the history
Also reset some PR after versions increased
  • Loading branch information
Schimmelreiter committed Jun 30, 2019
1 parent 3791bb9 commit 21df36f
Show file tree
Hide file tree
Showing 20 changed files with 353 additions and 15 deletions.
14 changes: 9 additions & 5 deletions softcams/cccam-common.inc
Expand Up @@ -6,8 +6,6 @@ PR = "r1-de"

LICENSE = "CLOSED"
require conf/license/license-close.inc
require softcam.inc
require softcam-binary-32bit.inc

FILESEXTRAPATHS_prepend := "${THISDIR}/enigma2-plugin-softcams-cccam:"

Expand All @@ -17,6 +15,9 @@ SRC_URI = " \
file://CCcam.xml \
"

require softcam.inc
require softcam-binary-32bit.inc

CONFFILES_${PN} ?= "/etc/CCcam.cfg /etc/ppanels/CCcam.xml"

PACKAGE_ARCH = "${DEFAULTTUNE}"
Expand All @@ -30,11 +31,14 @@ do_install() {
install -m 0644 ${WORKDIR}/CCcam.xml ${D}/etc/ppanels/CCcam.xml
}

RDEPENDS_${PN}_aarch64 = "lib32-glibc lib32-libstdc++ lib32-libxcrypt softcam-support"
RDEPENDS_${PN} = "glibc libstdc++ softcam-support"
RDEPENDS_${PN}_aarch64 = "lib32-glibc lib32-libstdc++ softcam-support"

# libxcrypt

INHIBIT_PACKAGE_STRIP = "1"
INSANE_SKIP_${PN} = "already-stripped build-deps"
INSANE_SKIP_${PN}_aarch64 = "already-stripped arch build-deps"
INSANE_SKIP_${PN} = "already-stripped build-deps file-rdeps"
INSANE_SKIP_${PN}_aarch64 = "already-stripped arch build-deps file-rdeps"

RPROVIDES_${PN} += "enigma2-plugin-softcams-cccam-2.0.9 enigma2-plugin-softcams-cccam-2.0.11 enigma2-plugin-softcams-cccam-2.1.1 enigma2-plugin-softcams-cccam-2.2.1 enigma2-plugin-softcams-cccam-2.3.0 enigma2-plugin-softcams-cccam-2.3.2"
RREPLACES_${PN} += "enigma2-plugin-softcams-cccam-2.0.9 enigma2-plugin-softcams-cccam-2.0.11 enigma2-plugin-softcams-cccam-2.1.1 enigma2-plugin-softcams-cccam-2.2.1 enigma2-plugin-softcams-cccam-2.3.0 enigma2-plugin-softcams-cccam-2.3.2"
Expand Down
Binary file not shown.
3 changes: 3 additions & 0 deletions softcams/enigma2-plugin-softcams-scam_3.60.bb
@@ -0,0 +1,3 @@
CAMNAME="scam"

require scam-common.inc
94 changes: 94 additions & 0 deletions softcams/enigma2-plugin-softcams-wicardd/init.wicardd
@@ -0,0 +1,94 @@
#!/bin/sh
### BEGIN INIT INFO
# Provides: softcam
# Required-Start: $local_fs
# Required-Stop:
# Should-Start: $time $remote_fs cardserver
# Should-Stop:
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: wicardd
# Description: wicardd SoftCAM, card reader and server.
### END INIT INFO

readlink -f $0 >/dev/null 2>&1
if [ $? -eq 0 ]; then
CAM=$(basename $(readlink -f $0) | sed s#^softcam\.##)
else
CAM=$(basename $0 | sed s#^softcam\.##)
fi
[ -n "$CAM" ] || exit 1
[ -x /usr/bin/$CAM ] || exit 1
PIDFILE=/var/tmp/${CAM}.pid
DESC="Softcam service $CAM"
DAEMON="/usr/bin/${CAM}"
case "$1" in
start)
if [ -e $PIDFILE ]; then
PIDDIR=/proc/$(cat $PIDFILE)
if [ -d ${PIDDIR} ] && [[ $(readlink -f ${PIDDIR}/exe) == $DAEMON ]]; then
echo "$DESC already started; not starting."
exit 1
else
rm -f $PIDFILE
fi
fi
echo -n "Starting $DESC: "
rm -rf /tmp/.wicardd >/dev/null 2>&1
ulimit -s 1024
start-stop-daemon -S -x ${DAEMON} -- -d -c /etc/tuxbox/config/${CAM}/wicardd.conf >/dev/null
sleep 1
start-stop-daemon -K -t -x ${DAEMON} >/dev/null 2>&1
if [ "$?" -eq "0" ]; then
echo "OK"
else
echo "FAILED"
fi
exit $RETVAL
;;
stop)
echo -n "Stopping $DESC: "
start-stop-daemon -K -R 2 -x $DAEMON >/dev/null 2>&1
RETVAL=$?
if [ "$RETVAL" -eq "0" ]; then
echo "OK"
else
echo "FAILED"
fi
sleep 1
killall $CAM 2> /dev/null
rm -rf /tmp/.wicardd
exit $RETVAL
;;
restart|reload)
$0 stop
sleep 1
$0 start
exit $?
;;
status)
echo -n "$DESC: "
start-stop-daemon -K -t -x $DAEMON >/dev/null 2>&1
if [ "$?" -eq 0 ]; then
echo "Running."
exit 0
fi
echo "Stopped."
exit 1
;;
version)
${DAEMON} -h | head -n 1 | sed 's#.* version ##' | sed 's#(.*##'
;;
info)
${DAEMON} -h | head -n 1 | sed 's# http.*##'
;;
*)
echo "Usage: $0 start|stop|restart|status"
exit 1
;;
esac
exit 0
90 changes: 90 additions & 0 deletions softcams/enigma2-plugin-softcams-wicardd/wicardd.conf
@@ -0,0 +1,90 @@
[global]
#log = /tmp/wicardd.log
#log_size = 100
log_udp = 192.168.1.19:514
syslog = 1
debug = 1
color_mode = 0

[webif]
active = 1
port = 83
debug = 3

[dvb]
active = 1
type = DVBAPI3
filter = dvb,dvb1
ecm_info = 1
sdt = 1
auto_update = 1
debug = 1

[filter]
name = dvb
rule = caid=2600;accept=EMU
rule = caid=4ae0;ident=15;ident:=0;accept #3K
rule = caid=0500;ident=023800,030B00;accept=EMU
rule = caid=0500;ident=007400;accept=mezzo
rule = caid=0500;ident=040620,060A00,060C00;accept #NTV+
rule = caid=090F;ident=0;accept #Viasat_Baltic
rule = caid=093E;ident=0;accept #Viasat_Nordic
rule = caid=0602;ident=0;chid=0b,2f,11,26,27,4c,42,8d,8e,91,ffff,CA;accept #Kontinent
rule = caid=0100;ident=0068,006A,006C,3311,3315,3317;accept #Cyfra_Polska
rule = caid=1803;ident=0,7001,7101;accept #Cyfrowy_Polsat
rule = caid=09CD;ident=0;accept #Sky_Italian
rule = caid=183D;ident=0;accept #TivuSat
rule = caid=0B01;ident=0;accept #Satellite BG/Telekarta
rule = caid=0B0F;ident=000000;accept #Xtra TV
rule = caid=0500;ident=022E00,031000,040810,030A00,024F00,041200,041700,032830,032500,043800,042700,032000,042800,042810,042200,042400,023800,042300,074000;accept #All_Viaccess
rule = next

[filter]
name = dvb1
rule = caid=0B00;ident=0;accept #Canal Digital on Thor
rule = caid=0B02;ident=0;accept #Focus Sat Moldova
rule = caid=0BAA;ident=0;accept #Hello HD
rule = caid=1830;ident=000000;accept #HD plus 19E
rule = caid=1802;ident=0;accept #DigiTV
rule = caid=1810;ident=0;accept #Digital+ HD
rule = caid=1830;ident=0;accept #HD+
rule = caid=1880;ident=0,2011,2111;accept #DigiTV
rule = caid=098C;ident=0;accept #SKY_De
rule = caid=1702;ident=000000;accept #SKY Germany 19.2E
rule = caid=090D;ident=0;accept #Yes HD
rule = caid=0D00;ident=0;accept #DigiTurk
rule = caid=0D02;ident=0,00A0,00A4,00A8;accept #UPC Direct
rule = caid=0D95;ident=0,0004;accept #ORF Digital
rule = caid=0D96;ident=0,0004,0008,000C,0010,0024,0028;accept #HD Austriasat
rule = reject

[reader]
active = 0
name = sci0
type = tuxbox
device = /dev/sci0
debug = 1
filter = dvb

[reader]
active = 0
name = shara
type = newcamd525
account = login:passwd@server
multiport=8521
debug = 1

[reader]
active = 1
name = EMU
type = emu
file = /etc/tuxbox/config/wicardd/SoftCam.Key
recalc_cw_checksum=1
debug = 1

[reader]
active = 1
name=mezzo
type=emu
file= /etc/tuxbox/config/wicardd/SoftCam_mezzo.Key
recalc_cw_checksum=1
Binary file not shown.
Binary file not shown.
Binary file not shown.
5 changes: 5 additions & 0 deletions softcams/enigma2-plugin-softcams-wicardd_1.19.bb
@@ -0,0 +1,5 @@
CAMNAME="wicardd"

require wicardd-common.inc

SUMMARY_${PN}_append = " (beelive)"
4 changes: 2 additions & 2 deletions softcams/gbox-common.inc
Expand Up @@ -72,5 +72,5 @@ pkg_postinst_${PN}_prepend () {
RDEPENDS_${PN}_aarch64 = "lib32-glibc lib32-libgcc softcam-support"

INHIBIT_PACKAGE_STRIP = "1"
INSANE_SKIP_${PN} += "already-stripped"
INSANE_SKIP_${PN}_aarch64 += "already-stripped arch"
INSANE_SKIP_${PN} += "already-stripped ldflags"
INSANE_SKIP_${PN}_aarch64 += "already-stripped arch ldflags"
12 changes: 8 additions & 4 deletions softcams/mgcamd-common.inc
Expand Up @@ -6,8 +6,6 @@ PR="r4.0"

LICENSE = "CLOSED"
require conf/license/license-close.inc
require softcam.inc
require softcam-binary-32bit.inc

FILESEXTRAPATHS_prepend := "${THISDIR}/enigma2-plugin-softcams-mgcamd:"

Expand All @@ -16,17 +14,23 @@ SRC_URI = " \
file://init.mgcamd \
"

require softcam.inc
require softcam-binary-32bit.inc

#CONFFILES_${PN} ?= "/etc/CCcam.cfg"

PACKAGE_ARCH = "${DEFAULTTUNE}"
CAM_ARCH="arm"
CAM_ARCH_mipsel="mips32el"
CAM_ARCH_sh4="sh4"

do_compile_prepend() {
cp ${WORKDIR}/init.${CAMNAME} ${S}/init.${CAMNAME}
}

do_install() {
install -d ${D}/etc/init.d
cp ${S}/../init.mgcamd ${S}/init.mgcamd
install -d ${D}/usr/bin
install -m 0755 ${S}/../init.mgcamd ${D}/etc/init.d/init.${CAMNAME}
install -m 0755 ${S}/../mgcamd_${PV}_${CAM_ARCH} ${D}/usr/bin/${CAMNAME}
}

Expand Down
2 changes: 1 addition & 1 deletion softcams/ncam.inc
Expand Up @@ -20,6 +20,6 @@ SRCREV = "${AUTOREV}"

PV = "10.2+git${SRCPV}"
PKGV = "10.2+git${GITPKGV}"
PR="r1"
PR = "r0"

S = "${WORKDIR}/git"
2 changes: 1 addition & 1 deletion softcams/oscam-emu.inc
Expand Up @@ -19,7 +19,7 @@ SRCREV = "${AUTOREV}"

PV = "1.20+git${SRCPV}"
PKGV = "1.20+git${GITPKGV}"
PR = "r4.0"
#PR = "r0"

S = "${WORKDIR}/git"

Expand Down
2 changes: 1 addition & 1 deletion softcams/oscam-smod.inc
Expand Up @@ -24,7 +24,7 @@ SMODSVN := ""

PV = "1.20+git${SRCPV}"
PKGV = "1.20+git${GITPKGV}"
PR = "r2"
PR = "r0"

S = "${WORKDIR}/git"
F = "${WORKDIR}/git/files"
Expand Down
2 changes: 1 addition & 1 deletion softcams/oscam-trunk-latest.inc
Expand Up @@ -4,7 +4,7 @@ SUMMARY_${PN} = "OSCam-trunk ${PKGV}"
DESCRIPTION_${PN} = "OSCam Open Source Softcam\n \
- latest trunk"

PR = "r4.0"
#PR = "r0"

RPROVIDES_${PN} += "enigma2-plugin-softcams-oscam-atv"
RREPLACES_${PN} += "enigma2-plugin-softcams-oscam-atv"
Expand Down
34 changes: 34 additions & 0 deletions softcams/scam-common.inc
@@ -0,0 +1,34 @@
# Stuff applying to all scams on image
SUMMARY_${PN} = "scam ${PKGV}"
DESCRIPTION_${PN} = "An outdated binary only softcam"

PR = "r0"

LICENSE = "CLOSED"
require conf/license/license-close.inc

FILESEXTRAPATHS_prepend := "${THISDIR}/enigma2-plugin-softcams-scam:"

SRC_URI = " \
file://scam_${PV}_* \
"

require softcam.inc

#CONFFILES_${PN} ?= "/etc/CCcam.cfg /etc/ppanels/CCcam.xml"

PACKAGE_ARCH = "${DEFAULTTUNE}"

do_install() {
install -d ${D}/usr/bin
install -m 0755 ${WORKDIR}/scam_${PV}_${TARGET_ARCH} ${D}/usr/bin/${CAMNAME}
}

RDEPENDS_${PN} = "libcrypto-compat-0.9.7 glibc softcam-support"

INHIBIT_PACKAGE_STRIP = "1"
INSANE_SKIP_${PN} = "already-stripped build-deps"

RPROVIDES_${PN} += "enigma2-plugin-softcams-scam-3.60 enigma2-plugin-softcams-scam-3.59"
RREPLACES_${PN} += "enigma2-plugin-softcams-scam-3.60 enigma2-plugin-softcams-scam-3.59"
RCONFLICTS_${PN} += "enigma2-plugin-softcams-scam-3.60 enigma2-plugin-softcams-scam-3.59"
15 changes: 15 additions & 0 deletions softcams/softcam-binary-32bit.inc
Expand Up @@ -14,10 +14,25 @@ ASSUME_SHLIBS_aarch64 += "libz.so.1:lib32-zlib"
ASSUME_SHLIBS_aarch64 += "librt.so.1:lib32-glibc"
ASSUME_SHLIBS_aarch64 += "libm.so.6:lib32-glibc"

# Learned from wicardd
# RDEPENDS_${PN}_aarch64 = "lib32-glibc lib32-libgcc"
ASSUME_SHLIBS_aarch64 += "libdl.so.2:lib32-glibc"

# Heuristics
ASSUME_SHLIBS_aarch64 += "libcrypto.so.0.9.7:lib32-libcrypto0.9.7"
ASSUME_SHLIBS_aarch64 += "libssl.so.0.9.7:lib32-libssl0.9.7"
ASSUME_SHLIBS_aarch64 += "libcrypto.so.0.9.8:lib32-libcrypto0.9.8"
ASSUME_SHLIBS_aarch64 += "libssl.so.0.9.8:lib32-libssl0.9.8"
ASSUME_SHLIBS_aarch64 += "libcrypto.so.1.0.1:lib32-libcrypto1.0.1"
ASSUME_SHLIBS_aarch64 += "libssl.so.1.0.1:lib32-libssl1.0.1"

# Remaining libc6
ASSUME_SHLIBS_aarch64 += "libnsl.so.1:lib32-glibc"
ASSUME_SHLIBS_aarch64 += "libresolv.so.2:lib32-glibc"
ASSUME_SHLIBS_aarch64 += "libanl.so.1:lib32-glibc"
ASSUME_SHLIBS_aarch64 += "libBrokenLocale.so.1:lib32-glibc"
ASSUME_SHLIBS_aarch64 += "libutil.so.1:lib32-glibc"
ASSUME_SHLIBS_aarch64 += "libnss_dns.so.2:lib32-glibc"
ASSUME_SHLIBS_aarch64 += "libnss_compat.so.2:lib32-glibc"
ASSUME_SHLIBS_aarch64 += "libnss_files.so.2:lib32-glibc"
ASSUME_SHLIBS_aarch64 += "ld-linux-armhf.so.3:lib32-glibc"

1 comment on commit 21df36f

@norhap
Copy link

@norhap norhap commented on 21df36f Nov 12, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hi @Schimmelreiter

with wicardd.......
I have compiled based on your make with your recipe in openpli, the compilation is correct but there is no way to detect the binary (log "not found") with aarch64 box os mio+ 4k edision....link correct libdl.so.2-> libdl-2.25.so
Do you have any idea what to do to make wicardd work on PLi-based images?
Thank you.

Please sign in to comment.