1 # Maintainer: Matthew 'Zashi' Hiles <zashi at vay8 dot net>
3 # the uniarch packages for arch that build from git are just adapations
4 # of the excellent work done by Rick W. Chen <stuffcorpse at archlinux dot us>
6 pkgname=mspgcc-msp430mcu
9 pkgdesc="C headers and binutils linker scripts for MSP430 family microcontrollers."
10 arch=('i686' 'x86_64')
11 url="http://mspgcc.sf.net"
14 depends=('mspgcc-binutils' 'mspgcc-mspgcc')
20 options=('!emptydirs' '!libtool' '!strip')
23 source=("http://surfnet.dl.sourceforge.net/project/mspgcc/msp430mcu/msp430mcu-$pkgver.tar.bz2")
25 md5sums=('fd602abfb3cef26731a13038d24e1bc5')
28 true # no compilation needed
34 cd ${srcdir}/msp430mcu-${pkgver}
36 export PREFIX="${pkgdir}/usr/"
38 mkdir -p ${pkgdir}/usr/msp430
40 #I ganked the contents of scripts/install.sh and dropped them here
42 MSP430MCU_ROOT="${srcdir}/msp430mcu-${pkgver}"
43 UPSTREAM=${MSP430MCU_ROOT}/upstream
44 ANALYSIS=${MSP430MCU_ROOT}/analysis
45 SCRIPTS=${MSP430MCU_ROOT}/scripts
47 INCPATH=${PREFIX}/msp430/include
48 LIBPATH=${PREFIX}/msp430/lib
50 mkdir -p ${INCPATH} ${LIBPATH}
53 install -p ${UPSTREAM}/*.h ${INCPATH}
55 # Local override headers
56 install -p ${MSP430MCU_ROOT}/include/*.h ${INCPATH}
58 # Override msp430.h to accommodate legacy MSPGCC MCU identifiers
59 install -p ${ANALYSIS}/msp430.h ${INCPATH}
61 # MCU-specific data for GCC driver program
62 install -p ${ANALYSIS}/msp430mcu.spec ${LIBPATH}
64 # Install MCU-specific memory and periph maps
65 cp -pr ${ANALYSIS}/ldscripts ${LIBPATH}