SHARE
TWEET

oss521fix

sea2wright Oct 10th, 2019 (edited) 63 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. diff -ru setup.orig/Linux/oss/build/install.sh setup/Linux/oss/build/install.sh
  2. --- setup.orig/Linux/oss/build/install.sh   2019-10-29 20:30:26.063402046 +0000
  3. +++ setup/Linux/oss/build/install.sh    2019-10-29 20:37:54.079713493 +0000
  4. @@ -179,6 +179,8 @@
  5.  fi
  6.  
  7.  cp -f ../objects/osscore.o osscore_mainline.o
  8. +rm -f osscore_lnk.c
  9. +ln -s osscore.c osscore_lnk.c
  10.  
  11.  rm -f Makefile
  12.  ln -s Makefile.osscore Makefile
  13. @@ -203,11 +205,8 @@
  14.     exit 3
  15.  fi
  16.  
  17. -if ! $LD -r osscore.ko osscore_mainline.o -o /lib/modules/$UNAME/kernel/oss/osscore.ko
  18. -then
  19. -   echo Linking the osscore module failed
  20. -   exit 5
  21. -fi
  22. +cp -f osscore.ko /lib/modules/$UNAME/kernel/oss/
  23. +rm -f osscore_lnk.c
  24.  
  25.  if test -f Module.symvers
  26.  then
  27. @@ -228,10 +227,11 @@
  28.     N=`basename $n .o`
  29.     echo Building module $N
  30.  
  31. -   rm -f $N_mainline.o Makefile
  32. +   rm -f $N\_mainline.o  $N\_lnk.c Makefile
  33.  
  34. -   sed "s/MODNAME/$N/" < Makefile.tmpl > Makefile
  35. -   ln -s $n $N_mainline.o
  36. +   sed "s/MODNAME/$N/g" < Makefile.tmpl > Makefile
  37. +   ln -s $N.c $N\_lnk.c
  38. +   ln -s $n $N\_mainline.o
  39.  
  40.     if ! make KERNELDIR=$KERNELDIR > build.list 2>&1
  41.     then
  42. @@ -240,13 +240,9 @@
  43.         exit 4
  44.     fi
  45.  
  46. -   if ! $LD -r $N.ko $N_mainline.o -o /lib/modules/$UNAME/kernel/oss/$N.ko
  47. -   then
  48. -       echo Linking $N module failed
  49. -       exit 6
  50. -   fi
  51. -
  52. -   rm -f $N_mainline.o
  53. +   cp -f $N.ko /lib/modules/$UNAME/kernel/oss/
  54. +   rm -f $N\_mainline.o
  55. +   rm -f $N\_lnk.c
  56.     make clean
  57.  done
  58.  
  59. diff -ru setup.orig/Linux/oss/build/Makefile.osscore setup/Linux/oss/build/Makefile.osscore
  60. --- setup.orig/Linux/oss/build/Makefile.osscore 2019-10-29 20:30:26.067401729 +0000
  61. +++ setup/Linux/oss/build/Makefile.osscore  2019-10-29 20:33:35.959631737 +0000
  62. @@ -5,6 +5,7 @@
  63.  ifneq ($(KERNELRELEASE),)
  64.  
  65.     obj-m := osscore.o
  66. +   osscore-objs := osscore_lnk.o osscore_mainline.o
  67.  
  68.  else
  69.  
  70. diff -ru setup.orig/Linux/oss/build/Makefile.tmpl setup/Linux/oss/build/Makefile.tmpl
  71. --- setup.orig/Linux/oss/build/Makefile.tmpl    2019-10-29 20:30:26.067401729 +0000
  72. +++ setup/Linux/oss/build/Makefile.tmpl 2019-10-29 20:33:35.959631737 +0000
  73. @@ -5,6 +5,7 @@
  74.  ifneq ($(KERNELRELEASE),)
  75.  
  76.     obj-m := MODNAME.o
  77. +   MODNAME-objs := MODNAME_lnk.o MODNAME_mainline.o
  78.  
  79.  else
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top