Skip to content

Commit

Permalink
Fixed scripts for Raspbian
Browse files Browse the repository at this point in the history
  • Loading branch information
lelegard committed Jun 15, 2018
1 parent 0da1c31 commit 46d9327
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 2 deletions.
4 changes: 4 additions & 0 deletions linux-drivers/build-dkms.sh
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ tar czp -f "$SRCTARBALL" -C "$TMPDIR" --owner=0 --group=0 "hides-dkms-$VERSION"
FC_DISTRO=$(grep " release " /etc/fedora-release 2>/dev/null | sed -e 's/^.* release \([0-9\.]*\) .*$/\1/')
RH_DISTRO=$(grep " release " /etc/redhat-release 2>/dev/null | sed -e 's/^.* release \([0-9\.]*\) .*$/\1/')
UB_DISTRO=$([[ -f /etc/lsb-release ]] && source /etc/lsb-release 2>/dev/null && [[ "`tr A-Z a-z <<<$DISTRIB_ID`" = ubuntu ]] && echo $DISTRIB_RELEASE)
DB_DISTRO=$(head -1 /etc/debian_version 2>/dev/null)
DISTRO_PREFIX=
DISTRO_VERSION=
RPM_DISTRO=false
Expand All @@ -63,6 +64,9 @@ elif [[ -n "$RH_DISTRO" ]]; then
elif [[ -n "$UB_DISTRO" ]]; then
DISTRO_VERSION="$UB_DISTRO"
DEB_DISTRO=true
elif [[ -n "$DB_DISTRO" ]]; then
DISTRO_VERSION="$DEB_DISTRO"
DEB_DISTRO=true
fi
DISTRO="$DISTRO_PREFIX"$(sed <<<"$DISTRO_VERSION" -e 's/\..*//')
verbose "Linux distro: $DISTRO, full version: $DISTRO_VERSION"
Expand Down
2 changes: 1 addition & 1 deletion linux-drivers/config/control.template
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Architecture: all
Maintainer: ITE Technologies Inc.
Section: free/kernel
Priority: optional
Depends: dkms
Depends: dkms, raspberrypi-kernel-headers | linux-kernel-headers
Description: Source code and DKMS setup for the HiDes device drivers.
This package installs the source code and DKMS setup for the kernel modules
of the HiDes device drivers. Each time the kernel is upgraded, the HiDes
Expand Down
2 changes: 1 addition & 1 deletion linux-drivers/config/postinst.template
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

if [[ "$1" = "configure" ]]; then
# Fix file permissions and ownership.
chown -R root:root /usr/src/hides-{{VERSION}} /etc/udev/rules.d/51-dta.rules /etc/udev/rules.d/51-dtu.rules /usr/share/doc/hides-dkms
chown -R root:root /usr/src/hides-{{VERSION}}
find /usr/src/hides-{{VERSION}} -type f -print0 | xargs -0 chmod 644
find /usr/src/hides-{{VERSION}} -type d -print0 | xargs -0 chmod 755

Expand Down

0 comments on commit 46d9327

Please sign in to comment.