View | Details | Raw Unified | Return to bug 200177 | Differences between
and this patch

Collapse All | Expand All

(-)Makefile (-6 / +32 lines)
Lines 8-22 Link Here
8
MASTER_SITES=	http://arduino.cc/download.php?f=/
8
MASTER_SITES=	http://arduino.cc/download.php?f=/
9
DISTNAME=	${PORTNAME}-${PORTVERSION}-linux32
9
DISTNAME=	${PORTNAME}-${PORTVERSION}-linux32
10
10
11
MAINTAINER=	leres@ee.lbl.gov
11
MAINTAINER=	james@elstone.net
12
COMMENT=	Open-source electronics prototyping platform
12
COMMENT=	Open-source electronics prototyping platform
13
13
14
LICENSE=	GPLv2 LGPL21
15
LICENSE_COMB=	multi
16
14
RUN_DEPENDS=	${JAVA_HOME}/jre/lib/ext/RXTXcomm.jar:comms/rxtx \
17
RUN_DEPENDS=	${JAVA_HOME}/jre/lib/ext/RXTXcomm.jar:comms/rxtx \
15
		${LOCALBASE}/bin/avrdude:devel/avrdude \
18
		${LOCALBASE}/bin/avrdude:devel/avrdude \
16
		${LOCALBASE}/avr/include/avr/io.h:devel/avr-libc
19
		${LOCALBASE}/avr/include/avr/io.h:devel/avr-libc
17
20
18
WRKSRC=		${WRKDIR}/${PORTNAME}-${PORTVERSION}
21
WRKSRC=		${WRKDIR}/${PORTNAME}-${PORTVERSION}
19
USES=		dos2unix tar:tgz
22
USES=		dos2unix tar:tgz kmod
20
DOS2UNIX_REGEX=	.*\(\.\(c|cpp|h|hex|html|ino|lst|txt\)|Makefile\)
23
DOS2UNIX_REGEX=	.*\(\.\(c|cpp|h|hex|html|ino|lst|txt\)|Makefile\)
21
24
22
USE_JAVA=	yes
25
USE_JAVA=	yes
Lines 28-47 Link Here
28
USE_LDCONFIG=	${PREFIX}/arduino/lib
31
USE_LDCONFIG=	${PREFIX}/arduino/lib
29
32
30
SUB_FILES=	arduino pkg-message
33
SUB_FILES=	arduino pkg-message
31
SUB_LIST=	PORTNAME=${PORTNAME} LINUXBASE=${LINUXBASE}
34
SUB_LIST=	PORTNAME=${PORTNAME} LINUXBASE=${PREFIX}
32
35
36
# Confirmed for ARCHS below. Arm, PowerPC and Sparc untested. (Feedback welcome)
37
ONLY_FOR_ARCHS=	i386 amd64
38
33
REINPLACE_ARGS=	-i ""
39
REINPLACE_ARGS=	-i ""
34
40
35
DESKTOP_ENTRIES=	"Arduino" "Arduino IDE" \
41
DESKTOP_ENTRIES=	"Arduino" "Arduino IDE" \
36
			${PREFIX}/${PORTNAME}/logo.png \
42
			${PREFIX}/${PORTNAME}/logo.png \
37
			"arduino" "Development;IDE;" "false"
43
			"arduino" "Development;IDE;" false
38
44
39
OPTIONS_DEFINE=		ATMEGA644P DOCS EXAMPLES
45
OPTIONS_DEFINE=		ATMEGA644P DOCS EXAMPLES UARDUNO
40
ATMEGA644P_DESC=	ATmega644p patches
46
ATMEGA644P_DESC=	ATmega644p patches
41
DOCS_DESC=		Install the reference documents
47
DOCS_DESC=		Install the reference documents
48
UARDUNO_DESC=		Kernel module for Arduino Uno USB interface
42
49
43
INSLIST=	arduino hardware lib libraries logo.png revisions.txt tools
50
INSLIST=	arduino hardware lib libraries logo.png revisions.txt tools
44
51
52
# Add serial drivers for those who are new to this.
53
UARDUNO_RUN_DEPENDS+=	${KMODDIR}/uarduno.ko:comms/uarduno
54
45
.include <bsd.port.options.mk>
55
.include <bsd.port.options.mk>
46
56
47
.if ${PORT_OPTIONS:MATMEGA644P}
57
.if ${PORT_OPTIONS:MATMEGA644P}
Lines 87-95 Link Here
87
	@${LN} -s ${PREFIX}/bin ${WRKSRC}/hardware/tools/avr/bin
97
	@${LN} -s ${PREFIX}/bin ${WRKSRC}/hardware/tools/avr/bin
88
	@${LN} -s ${PREFIX}/etc ${WRKSRC}/hardware/tools/avr/etc
98
	@${LN} -s ${PREFIX}/etc ${WRKSRC}/hardware/tools/avr/etc
89
99
100
	# Remove broken jar, and Linux C6 based libraries.
90
	@${RM} ${WRKSRC}/lib/RXTXcomm.jar
101
	@${RM} ${WRKSRC}/lib/RXTXcomm.jar
102
103
	# This port relys on comms/RXTX working without Linux C6 compatibility.
104
	@${RM} ${WRKSRC}/lib/librxtxSerial.so
105
	@${RM} ${WRKSRC}/lib/librxtxSerial64.so
106
	
107
	# Map the RXTX port for our use
91
	@${LN} -s ${JAVA_HOME}/jre/lib/ext/RXTXcomm.jar ${WRKSRC}/lib/RXTXcomm.jar
108
	@${LN} -s ${JAVA_HOME}/jre/lib/ext/RXTXcomm.jar ${WRKSRC}/lib/RXTXcomm.jar
92
109
110
111
# Add in links to the libraries compiled in RXTX for the above jar to use based on architecture.
112
.if ${MACHTYPE} == i386
113
	@${LN} -s ${JAVA_HOME}/jre/lib/i386/librxtxSerial.so ${WRKSRC}/lib/librxtxSerial.so
114
.endif
115
116
.if ${MACHTYPE} == x86_64
117
	@${LN} -s ${JAVA_HOME}/jre/lib/amd64/librxtxSerial.so ${WRKSRC}/lib/librxtxSerial64.so
118
.endif
119
93
	@${MV} ${WRKSRC}/reference/img/logo.png ${WRKSRC}/
120
	@${MV} ${WRKSRC}/reference/img/logo.png ${WRKSRC}/
94
	@${RM} -r ${WRKSRC}/reference/img/
121
	@${RM} -r ${WRKSRC}/reference/img/
95
122
Lines 96-102 Link Here
96
do-install:
123
do-install:
97
	${MKDIR} ${STAGEDIR}${PREFIX}/${PORTNAME}
124
	${MKDIR} ${STAGEDIR}${PREFIX}/${PORTNAME}
98
	(cd ${WRKSRC}/ && ${COPYTREE_SHARE} "${INSLIST}" ${STAGEDIR}${PREFIX}/${PORTNAME} ${FIND_EXPR})
125
	(cd ${WRKSRC}/ && ${COPYTREE_SHARE} "${INSLIST}" ${STAGEDIR}${PREFIX}/${PORTNAME} ${FIND_EXPR})
99
	${CHMOD} +x ${STAGEDIR}${PREFIX}/${PORTNAME}/arduino
100
	${INSTALL_SCRIPT} ${WRKDIR}/arduino ${STAGEDIR}${PREFIX}/bin/
126
	${INSTALL_SCRIPT} ${WRKDIR}/arduino ${STAGEDIR}${PREFIX}/bin/
101
127
102
.include <bsd.port.mk>
128
.include <bsd.port.mk>
(-)files/arduino.in (-1 / +1 lines)
Lines 5-8 Link Here
5
PATH="%%LINUXBASE%%/usr/bin:${PATH}"
5
PATH="%%LINUXBASE%%/usr/bin:${PATH}"
6
export PATH
6
export PATH
7
7
8
exec %%PREFIX%%/%%PORTNAME%%/arduino %%PREFIX%%/%%PORTNAME%%
8
exec '%%PREFIX%%/%%PORTNAME%%/arduino' $@
(-)files/patch-hardware-arduino-cores-arduino-HardwareSerial.cpp (-9 / +9 lines)
Lines 1-6 Link Here
1
--- hardware/arduino/cores/arduino/HardwareSerial.cpp.orig	2013-05-17 12:48:38.000000000 -0700
1
--- hardware/arduino/cores/arduino/HardwareSerial.cpp.orig	2014-09-16 13:45:33 UTC
2
+++ hardware/arduino/cores/arduino/HardwareSerial.cpp	2013-06-30 12:21:21.000000000 -0700
2
+++ hardware/arduino/cores/arduino/HardwareSerial.cpp
3
@@ -89,7 +89,7 @@
3
@@ -89,7 +89,7 @@ struct ring_buffer
4
 
4
 
5
 inline void store_char(unsigned char c, ring_buffer *buffer)
5
 inline void store_char(unsigned char c, ring_buffer *buffer)
6
 {
6
 {
Lines 9-15 Link Here
9
 
9
 
10
   // if we should be storing the received character into the location
10
   // if we should be storing the received character into the location
11
   // just before the tail (meaning that the head would advance to the
11
   // just before the tail (meaning that the head would advance to the
12
@@ -124,14 +124,14 @@
12
@@ -124,14 +124,14 @@ inline void store_char(unsigned char c, 
13
       unsigned char c = UDR0;
13
       unsigned char c = UDR0;
14
       store_char(c, &rx_buffer);
14
       store_char(c, &rx_buffer);
15
     } else {
15
     } else {
Lines 26-32 Link Here
26
     };
26
     };
27
   #else
27
   #else
28
     #error UDR not defined
28
     #error UDR not defined
29
@@ -150,7 +150,7 @@
29
@@ -150,7 +150,7 @@ inline void store_char(unsigned char c, 
30
       unsigned char c = UDR1;
30
       unsigned char c = UDR1;
31
       store_char(c, &rx_buffer1);
31
       store_char(c, &rx_buffer1);
32
     } else {
32
     } else {
Lines 35-41 Link Here
35
     };
35
     };
36
   }
36
   }
37
 #endif
37
 #endif
38
@@ -165,7 +165,7 @@
38
@@ -165,7 +165,7 @@ inline void store_char(unsigned char c, 
39
       unsigned char c = UDR2;
39
       unsigned char c = UDR2;
40
       store_char(c, &rx_buffer2);
40
       store_char(c, &rx_buffer2);
41
     } else {
41
     } else {
Lines 44-50 Link Here
44
     };
44
     };
45
   }
45
   }
46
 #endif
46
 #endif
47
@@ -180,7 +180,7 @@
47
@@ -180,7 +180,7 @@ inline void store_char(unsigned char c, 
48
       unsigned char c = UDR3;
48
       unsigned char c = UDR3;
49
       store_char(c, &rx_buffer3);
49
       store_char(c, &rx_buffer3);
50
     } else {
50
     } else {
Lines 53-59 Link Here
53
     };
53
     };
54
   }
54
   }
55
 #endif
55
 #endif
56
@@ -365,7 +365,6 @@
56
@@ -365,7 +365,6 @@ try_again:
57
 void HardwareSerial::begin(unsigned long baud, byte config)
57
 void HardwareSerial::begin(unsigned long baud, byte config)
58
 {
58
 {
59
   uint16_t baud_setting;
59
   uint16_t baud_setting;
Lines 61-67 Link Here
61
   bool use_u2x = true;
61
   bool use_u2x = true;
62
 
62
 
63
 #if F_CPU == 16000000UL
63
 #if F_CPU == 16000000UL
64
@@ -459,7 +458,7 @@
64
@@ -459,7 +458,7 @@ void HardwareSerial::flush()
65
 
65
 
66
 size_t HardwareSerial::write(uint8_t c)
66
 size_t HardwareSerial::write(uint8_t c)
67
 {
67
 {
(-)pkg-plist (-3 / +3 lines)
Lines 1-4 Link Here
1
@mode 755
1
arduino/arduino
2
arduino/arduino
3
bin/arduino
4
@mode
2
%%EXAMPLES%%arduino/examples/01.Basics/AnalogReadSerial/AnalogReadSerial.ino
5
%%EXAMPLES%%arduino/examples/01.Basics/AnalogReadSerial/AnalogReadSerial.ino
3
%%EXAMPLES%%arduino/examples/01.Basics/BareMinimum/BareMinimum.ino
6
%%EXAMPLES%%arduino/examples/01.Basics/BareMinimum/BareMinimum.ino
4
%%EXAMPLES%%arduino/examples/01.Basics/Blink/Blink.ino
7
%%EXAMPLES%%arduino/examples/01.Basics/Blink/Blink.ino
Lines 565-572 Link Here
565
arduino/lib/ecj.jar
568
arduino/lib/ecj.jar
566
arduino/lib/jna.jar
569
arduino/lib/jna.jar
567
arduino/lib/keywords.txt
570
arduino/lib/keywords.txt
568
arduino/lib/librxtxSerial.so
569
arduino/lib/librxtxSerial64.so
570
arduino/lib/pde.jar
571
arduino/lib/pde.jar
571
arduino/lib/preferences.txt
572
arduino/lib/preferences.txt
572
arduino/lib/theme/buttons.gif
573
arduino/lib/theme/buttons.gif
Lines 1265-1268 Link Here
1265
arduino/tools/Mangler/make.sh
1266
arduino/tools/Mangler/make.sh
1266
arduino/tools/Mangler/src/Mangler.java
1267
arduino/tools/Mangler/src/Mangler.java
1267
arduino/tools/howto.txt
1268
arduino/tools/howto.txt
1268
bin/arduino

Return to bug 200177