Fix stage Q/A.

This commit is contained in:
Lev A. Serebryakov 2014-06-07 16:53:01 +00:00
parent bf065d28df
commit a4d809f4c9
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=356928
2 changed files with 42 additions and 3 deletions

View file

@ -3,7 +3,7 @@
PORTNAME= ${MCUTARGET}mcu
PORTVERSION= 1.0.${MCUVERSION}
PORTREVISION= 1
PORTREVISION= 2
CATEGORIES= devel
MASTER_SITES= SF/mspgcc/${PORTNAME}
DISTNAME= ${PORTNAME}-${MCUVERSION}
@ -24,7 +24,8 @@ MCUTARGET= msp430
BUGS_FIXED= 3522088
LTS_PATCHES!= for bugid in ${BUGS_FIXED} ; do echo ${PORTNAME}-${MCUVERSION}-sf$${bugid}.patch ; done
USE_BZIP2= yes
USES= tar:bzip2
NO_BUILD= yes
WRKSRC= ${WRKDIR}/${PORTNAME}-${MCUVERSION}
@ -46,6 +47,6 @@ pre-install:
@${ECHO} "@dirrmtry ${MCUTARGET}" >> ${PLIST}
do-install:
@cd ${WRKSRC} && MSP430MCU_ROOT=${WRKSRC} ${SH} scripts/install.sh ${STAGEDIR}${PREFIX}
@cd ${WRKSRC} && MSP430MCU_ROOT=${WRKSRC} ${SH} scripts/install.sh ${PREFIX} ${STAGEDIR}${PREFIX}
.include <bsd.port.mk>

View file

@ -0,0 +1,38 @@
--- scripts/install.sh.orig 2014-06-07 20:49:35.000000000 +0400
+++ scripts/install.sh 2014-06-07 20:50:51.000000000 +0400
@@ -4,6 +4,7 @@
# This file is part of msp430mcu (http://sourceforge.net/projects/mspgcc/)
PREFIX=${1:-/msp430/install/dev}
+DISTDIR=${2:-${PREFIX}}
MSP430MCU_ROOT=${MSP430MCU_ROOT:-${MSP430_ROOT:-/msp430}/msp430mcu}
UPSTREAM=${MSP430MCU_ROOT}/upstream
ANALYSIS=${MSP430MCU_ROOT}/analysis
@@ -11,9 +12,13 @@
VERSION=`cat ${MSP430MCU_ROOT}/.version`
UPSTREAM_VERSION=`cat ${MSP430MCU_ROOT}/upstream/.version`
-BINPATH=${PREFIX}/bin
-INCPATH=${PREFIX}/msp430/include
-LIBPATH=${PREFIX}/msp430/lib
+PBINPATH=${PREFIX}/bin
+PINCPATH=${PREFIX}/msp430/include
+PLIBPATH=${PREFIX}/msp430/lib
+
+BINPATH=${DISTDIR}/bin
+INCPATH=${DISTDIR}/msp430/include
+LIBPATH=${DISTDIR}/msp430/lib
mkdir -p ${INCPATH} ${LIBPATH} ${BINPATH}
@@ -37,8 +42,8 @@
cat bin/msp430mcu-config.in \
| sed \
-e 's!@PREFIX@!'"${PREFIX}"'!g' \
- -e 's!@SCRIPTPATH@!'"${LIBPATH}/ldscripts"'!g' \
- -e 's!@INCPATH@!'"${INCPATH}"'!g' \
+ -e 's!@SCRIPTPATH@!'"${PLIBPATH}/ldscripts"'!g' \
+ -e 's!@INCPATH@!'"${PINCPATH}"'!g' \
-e 's!@VERSION@!'"${VERSION}"'!g' \
-e 's!@UPSTREAM_VERSION@!'"${UPSTREAM_VERSION}"'!g' \
> ${BINPATH}/msp430mcu-config \