| 1 | #!/bin/sh
|
|---|
| 2 | INSTDIR="$1"
|
|---|
| 3 |
|
|---|
| 4 | sed s#_path_#"$INSTDIR"#g -i "$INSTDIR/etc/oscam_6089_swap.emu"
|
|---|
| 5 |
|
|---|
| 6 | if [ ! -e "$INSTDIR/keys/oscam.conf" ]; then
|
|---|
| 7 | echo "use ipk config file: oscam.conf"
|
|---|
| 8 | echo "rename $INSTDIR/keys/oscam.conf.oscam > $INSTDIR/keys/oscam.conf"
|
|---|
| 9 | mv "$INSTDIR/keys/oscam.conf.oscam" "$INSTDIR/keys/oscam.conf"
|
|---|
| 10 | else
|
|---|
| 11 | echo "found user config file: oscam.conf"
|
|---|
| 12 | echo "skip ipk config file: oscam.conf.oscam"
|
|---|
| 13 | fi
|
|---|
| 14 |
|
|---|
| 15 | if [ ! -e "$INSTDIR/keys/oscam.provid" ]; then
|
|---|
| 16 | echo "use ipk config file: oscam.provid"
|
|---|
| 17 | echo "rename $INSTDIR/keys/oscam.provid.oscam > $INSTDIR/keys/oscam.provid"
|
|---|
| 18 | mv "$INSTDIR/keys/oscam.provid.oscam" "$INSTDIR/keys/oscam.provid"
|
|---|
| 19 | else
|
|---|
| 20 | echo "found user config file: oscam.provid"
|
|---|
| 21 | echo "skip ipk config file: oscam.provid.oscam"
|
|---|
| 22 | fi
|
|---|
| 23 |
|
|---|
| 24 | if [ ! -e "$INSTDIR/keys/oscam.srvid" ]; then
|
|---|
| 25 | echo "use ipk config file: oscam.srvid"
|
|---|
| 26 | echo "rename $INSTDIR/keys/oscam.srvid.oscam > $INSTDIR/keys/oscam.srvid"
|
|---|
| 27 | mv "$INSTDIR/keys/oscam.srvid.oscam" "$INSTDIR/keys/oscam.srvid"
|
|---|
| 28 | else
|
|---|
| 29 | echo "found user config file: oscam.srvid"
|
|---|
| 30 | echo "skip ipk config file: oscam.srvid.oscam"
|
|---|
| 31 | fi
|
|---|
| 32 |
|
|---|
| 33 | if [ ! -e "$INSTDIR/keys/oscam.server" ]; then
|
|---|
| 34 | echo "use ipk config file: oscam.server"
|
|---|
| 35 | echo "rename $INSTDIR/keys/oscam.server.oscam > $INSTDIR/keys/oscam.server"
|
|---|
| 36 | mv "$INSTDIR/keys/oscam.server.oscam" "$INSTDIR/keys/oscam.server"
|
|---|
| 37 | else
|
|---|
| 38 | echo "found user config file: oscam.server"
|
|---|
| 39 | echo "skip ipk config file: oscam.server.oscam"
|
|---|
| 40 | fi
|
|---|
| 41 |
|
|---|
| 42 | if [ ! -e "$INSTDIR/keys/oscam.user" ]; then
|
|---|
| 43 | echo "use ipk config file: oscam.user"
|
|---|
| 44 | echo "rename $INSTDIR/keys/oscam.user.oscam > $INSTDIR/keys/oscam.user"
|
|---|
| 45 | mv "$INSTDIR/keys/oscam.user.oscam" "$INSTDIR/keys/oscam.user"
|
|---|
| 46 | else
|
|---|
| 47 | echo "found user config file: oscam.user"
|
|---|
| 48 | echo "skip ipk config file: oscam.user.oscam"
|
|---|
| 49 | fi
|
|---|
| 50 |
|
|---|
| 51 | if [ ! -e "$INSTDIR/keys/oscam.services" ]; then
|
|---|
| 52 | echo "use ipk config file: oscam.services"
|
|---|
| 53 | echo "rename $INSTDIR/keys/oscam.services.oscam > $INSTDIR/keys/oscam.services"
|
|---|
| 54 | mv "$INSTDIR/keys/oscam.services.oscam" "$INSTDIR/keys/oscam.services"
|
|---|
| 55 | else
|
|---|
| 56 | echo "found user config file: oscam.services"
|
|---|
| 57 | echo "skip ipk config file: oscam.services.oscam"
|
|---|
| 58 | fi
|
|---|
| 59 |
|
|---|
| 60 | if [ ! -e "$INSTDIR/keys/oscam.dvbapi" ]; then
|
|---|
| 61 | echo "use ipk config file: oscam.dvbapi"
|
|---|
| 62 | echo "rename $INSTDIR/keys/oscam.dvbapi.oscam > $INSTDIR/keys/oscam.dvbapi"
|
|---|
| 63 | mv "$INSTDIR/keys/oscam.dvbapi.oscam" "$INSTDIR/keys/oscam.dvbapi"
|
|---|
| 64 | else
|
|---|
| 65 | echo "found user config file: oscam.dvbapi"
|
|---|
| 66 | echo "skip ipk config file: oscam.dvbapi.oscam"
|
|---|
| 67 | fi
|
|---|
| 68 |
|
|---|
| 69 | if [ ! -e "$INSTDIR/keys/oscam.stat" ]; then
|
|---|
| 70 | echo "use ipk config file: oscam.stat"
|
|---|
| 71 | echo "rename $INSTDIR/keys/oscam.stat.oscam > $INSTDIR/keys/oscam.stat"
|
|---|
| 72 | mv "$INSTDIR/keys/oscam.stat.oscam" "$INSTDIR/keys/oscam.stat"
|
|---|
| 73 | else
|
|---|
| 74 | echo "found user config file: oscam.stat"
|
|---|
| 75 | echo "skip ipk config file: oscam.stat.oscam"
|
|---|
| 76 | fi
|
|---|
| 77 |
|
|---|
| 78 | echo "successfully installed"
|
|---|
| 79 | exit 0
|
|---|