Advertisement
Guest User

hdjmod mirror pkgbuild

a guest
Nov 17th, 2013
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.68 KB | None | 0 0
  1. # Contributor: Ali H. Caliskan <ali.h.caliskan AT gmail DOT com>
  2. # Contributor: sergeantspoon <sergeantspoon@archlinux.us>
  3. # Contributor: Speedboy <theknight696.linux AT gmail DOT com>
  4. # Maintainer: Gimmeapill <gimmeapill at gmail DOT com>
  5.  
  6. pkgname=hdjmod
  7. pkgver=1.28
  8. pkgrel=7
  9. pkgdesc="Hercules DJ kernel module"
  10. arch=('i686' 'x86_64')
  11. url="http://ts.hercules.com/eng/"
  12. license=('GPL2')
  13. depends=('linux>=3.6')
  14. makedepends=('rpmextract' 'linux-headers')
  15. optdepends=('hdjcpl: Control Panel for the Hercules DJ series hardware settings')
  16. install=hdjmod.install
  17.  
  18. source=('http://exislandproject.free.fr/Hercules_DJSeries_Linux.tgz'
  19. 'hdjmod.diff'
  20. 'kernel_2.6.31_fix.patch'
  21. 'kernel_2.6.35_fix.diff'
  22. 'dj_console_mp3_e2.patch'
  23. 'kernel_2.6.37_fix.patch'
  24. 'kernel_2.6.39_fix.patch'
  25. 'kernel_3.6_fix.patch'
  26. 'kernel_3.7_fix.patch')
  27.  
  28. md5sums=('498cf0ff144f20106718932ab22571ce'
  29. '464f8a8eda9d4c2ec83cf1c43e5dbee3'
  30. '405a57365935fa003514ac2370325de1'
  31. '359c33f8e21a7ce5425d5409919f8252'
  32. 'f9e6f12c5f59c7bdb44d813cd42c9b27'
  33. '132528f078a26775ca8c7c4c3ebfe748'
  34. '9cc3e1cb4c7877ebf09e389e67b19182'
  35. '8bf580fcfe06f48ce8247272b55633ce'
  36. 'f40801f32abc47088a54c8893aa27e75')
  37.  
  38. build() {
  39. # Obtain source files
  40. cd $srcdir/kernel\ module
  41. /usr/bin/rpmextract.sh hdjmod-dkms-1.28-1.noarch.rpm
  42.  
  43. # Delete the old source folder
  44. rm -rf $srcdir/hdjmod-1.28
  45.  
  46. # Move the source
  47. mv usr/src/hdjmod-1.28 $srcdir
  48. cd $srcdir/hdjmod-1.28
  49.  
  50. # First patch makes installing easier
  51. patch -p0 < $srcdir/hdjmod.diff
  52.  
  53. # Second patch fixes APIs that were changed in kernel >= 2.6.31
  54. patch -p0 < $srcdir/kernel_2.6.31_fix.patch
  55.  
  56. # Third patch fixes Build errors with a kernel >= 2.6.35
  57. patch -p0 < $srcdir/kernel_2.6.35_fix.diff
  58.  
  59. # Fix the path to the linux headers in bulk.h (this was hardcoded by kernel_2.6.35_fix.diff)
  60. sed -i s/2.6.35-ARCH/$(uname -r)/ bulk.h
  61.  
  62. # Fourth patch adds supports for the DJ Console MP3 e2
  63. patch -p0 < $srcdir/dj_console_mp3_e2.patch
  64.  
  65. # Fifth patch fixes build errors with kernel 2.6.37
  66. patch -p0 < $srcdir/kernel_2.6.37_fix.patch
  67.  
  68. # Sixth patch fixes build errors with kernel 2.6.39 (from OpenSUSE Factory)
  69. patch -p0 < $srcdir/kernel_2.6.39_fix.patch
  70.  
  71. # Seventh patch fixes build errors with kernel 3.6.x (from OpenSUSE Factory)
  72. patch -p0 < $srcdir/kernel_3.6_fix.patch
  73.  
  74. # Eighth patch fixes build errors with kernel 3.7.x (from OpenSUSE Factory)
  75. patch -p0 < $srcdir/kernel_3.7_fix.patch
  76.  
  77. # Patches 5->8 by Matthias Bach <marix@marix.org>
  78. # http://download.opensuse.org/repositories/hardware/openSUSE_Factory/src/
  79.  
  80. # Compile...
  81. make
  82. make DESTDIR="$pkgdir" install
  83. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement