mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-11-18 22:54:00 +00:00
libbcm2835 1.42, RPi2 support
This commit is contained in:
parent
6a63f17131
commit
64dc558ed7
2 changed files with 49 additions and 4 deletions
|
@ -4,15 +4,21 @@ buildarch=16
|
|||
|
||||
_pkgbasename=bcm2835
|
||||
pkgname=libbcm2835
|
||||
pkgver=1.37
|
||||
pkgver=1.42
|
||||
pkgrel=1
|
||||
pkgdesc="C library for Broadcom BCM 2835 as used in Raspberry Pi"
|
||||
url="http://www.airspayce.com/mikem/bcm2835/"
|
||||
arch=('armv6h')
|
||||
arch=('armv6h' 'armv7h')
|
||||
license=('GPL')
|
||||
options=('staticlibs')
|
||||
source=(http://www.airspayce.com/mikem/${_pkgbasename}/${_pkgbasename}-${pkgver}.tar.gz)
|
||||
md5sums=('2314bcbd2e1c6a164dbeda58abfb9c04')
|
||||
source=(http://www.airspayce.com/mikem/${_pkgbasename}/${_pkgbasename}-${pkgver}.tar.gz bcm2835.patch)
|
||||
md5sums=('3f60ac30ada6b8f7036243f13da441ba'
|
||||
'62085703dbef25ed501002dec077c3d5')
|
||||
|
||||
prepare() {
|
||||
cd ${srcdir}/${_pkgbasename}-${pkgver}
|
||||
patch -p1 -i "$srcdir/bcm2835.patch"
|
||||
}
|
||||
|
||||
build() {
|
||||
cd ${srcdir}/${_pkgbasename}-${pkgver}
|
||||
|
|
39
alarm/libbcm2835/bcm2835.patch
Normal file
39
alarm/libbcm2835/bcm2835.patch
Normal file
|
@ -0,0 +1,39 @@
|
|||
Only in bcm2835-1.42: Makefile
|
||||
Only in bcm2835-1.42: config.h
|
||||
Only in bcm2835-1.42: config.log
|
||||
Only in bcm2835-1.42: config.status
|
||||
Only in bcm2835-1.42/doc: Makefile
|
||||
Only in bcm2835-1.42/src: .deps
|
||||
Only in bcm2835-1.42/src: Makefile
|
||||
diff -u -r bcm2835-1.42-orig/src/bcm2835.c bcm2835-1.42/src/bcm2835.c
|
||||
--- bcm2835-1.42-orig/src/bcm2835.c 2015-03-09 06:00:44.000000000 +0100
|
||||
+++ bcm2835-1.42/src/bcm2835.c 2015-03-22 19:29:37.531488655 +0100
|
||||
@@ -122,9 +122,9 @@
|
||||
uint32_t ret;
|
||||
#ifdef BCM2835_HAVE_DMB
|
||||
__asm__( "\
|
||||
- dmb \
|
||||
- ldr %[ret], [%[paddr]] \
|
||||
- dmb \
|
||||
+ dmb \n\
|
||||
+ ldr %[ret], [%[paddr]]\n\
|
||||
+ dmb \n\
|
||||
" : [ret] "=r" (ret) : [paddr] "r" (paddr) : "memory" );
|
||||
#else
|
||||
__asm__( "\
|
||||
@@ -176,9 +176,9 @@
|
||||
/* Following code provides memory barriers before and after the write */
|
||||
#ifdef BCM2835_HAVE_DMB
|
||||
__asm__( "\
|
||||
- dmb \
|
||||
- str %[value], [%[paddr]] \
|
||||
- dmb \
|
||||
+ dmb \n\
|
||||
+ str %[value], [%[paddr]]\n\
|
||||
+ dmb \n\
|
||||
" : : [paddr] "r" (paddr), [value] "r" (value) : "memory" );
|
||||
#else
|
||||
__asm__( "\
|
||||
Only in bcm2835-1.42/src: bcm2835.o
|
||||
Only in bcm2835-1.42/src: libbcm2835.a
|
||||
Only in bcm2835-1.42: stamp-h1
|
Loading…
Reference in a new issue