From e3f8eb694f2d06cc9337bee7c349b53b7b05be25 Mon Sep 17 00:00:00 2001 From: Lior Spach <ls12@inf.ufpr.br> Date: Fri, 16 Aug 2013 14:08:22 -0300 Subject: [PATCH] le-pregao-712010: Refs #1280, Avoid adding duplicated entries (modules/blacklist) Signed-off-by: Lior Spach <ls12@inf.ufpr.br> --- le-pregao-712010/pacote/DEBIAN/postinst | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/le-pregao-712010/pacote/DEBIAN/postinst b/le-pregao-712010/pacote/DEBIAN/postinst index 446efc4d2..614263f8a 100755 --- a/le-pregao-712010/pacote/DEBIAN/postinst +++ b/le-pregao-712010/pacote/DEBIAN/postinst @@ -37,6 +37,18 @@ else echo "apt-get install linux-headers-$KERNEL_VERSION" fi +#If already added the entries in /etc/modules, dont do that again. +TEST_IF_IN_MODULES=$(grep "rt3562sta$" /etc/modules) +if [ "$TEST_IF_IN_MODULES" == "" ]; then + # Put conflicting modules at /etc/modprobe.d/blacklist.conf + echo "# replaced by rt3562sta" >> /etc/modprobe.d/blacklist.conf + echo "blacklist rt2800pci" >> /etc/modprobe.d/blacklist.conf + + # Put conflicting modules at /etc/modprobe.d/blacklist.conf + echo "# enable wireless for pregao 71/2010" >> /etc/modules + echo "rt3562sta" >> /etc/modules +fi + # Function to set selections setselections() { selfile=$1 -- GitLab