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

Collapse All | Expand All

(-)devel/simavr/Makefile (-11 / +15 lines)
Lines 2-18 Link Here
2
# $FreeBSD$
2
# $FreeBSD$
3
3
4
PORTNAME=	simavr
4
PORTNAME=	simavr
5
PORTVERSION=	1.6
5
PORTVERSION=	1.7
6
PORTREVISION=	2
7
DISTVERSIONPREFIX=	v
6
DISTVERSIONPREFIX=	v
8
CATEGORIES=	devel emulators
7
CATEGORIES=	devel emulators
9
DIST_SUBDIR=	${PORTNAME}
10
11
PATCH_DIST_STRIP=	-p1
12
PATCH_SITES=	https://github.com/buserror/simavr/commit/
13
PATCHFILES=	86264ad6d0b6b921130e293769d8ebaec512eecd.diff \
14
		e5ea627259daae64ddbe67402b6d121e0143cd21.diff \
15
		082939e64e1632d8ea0b1d6ebea93ca832c9e762.diff
16
8
17
MAINTAINER=	felix@palmen-it.de
9
MAINTAINER=	felix@palmen-it.de
18
COMMENT=	Simulator for several Atmel AVR chips
10
COMMENT=	Simulator for several Atmel AVR chips
Lines 32-38 GH_ACCOUNT= buserror Link Here
32
USE_LDCONFIG=	yes
24
USE_LDCONFIG=	yes
33
25
34
ALL_TARGET=	build-parts
26
ALL_TARGET=	build-parts
35
MAKE_ARGS=	"RELEASE=1 PREFIX=${PREFIX} DESTDIR=${STAGEDIR}${PREFIX}"
27
DESTDIRNAME=	DUMMYDESTDIR
28
		# Avoid default DESTDIR handling, so we can set a custom
29
		# one that includes PREFIX, as required by broken upstream
30
		# install targets
31
MAKE_ARGS=	RELEASE=1 PREFIX=${PREFIX} DESTDIR=${STAGEDIR}${PREFIX}
32
MAKE_ENV=	SIMAVR_VERSION=v${PORTVERSION}
36
33
37
OPTIONS_DEFINE=		DOCS EXAMPLES
34
OPTIONS_DEFINE=		DOCS EXAMPLES
38
35
Lines 43-48 AVR_STRIP_CMD?= avr-strip Link Here
43
DUMPMACHINE=	${CC} -dumpmachine
40
DUMPMACHINE=	${CC} -dumpmachine
44
OBJDIRNAME=	obj-$$(${DUMPMACHINE})
41
OBJDIRNAME=	obj-$$(${DUMPMACHINE})
45
42
43
post-patch:
44
	${REINPLACE_CMD} -e 's:Linux:FreeBSD:' \
45
		-e 's:unknown:v${PORTVERSION}:' \
46
		${WRKSRC}/simavr/Makefile \
47
		${WRKSRC}/examples/parts/Makefile
48
46
post-install:
49
post-install:
47
	${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/simavr
50
	${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/simavr
48
	${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libsimavr.so.1
51
	${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libsimavr.so.1
Lines 54-60 post-install-DOCS-on: Link Here
54
	${INSTALL_DATA} ${WRKSRC}/doc/simavr_callgraph.pdf ${STAGEDIR}${DOCSDIR}
57
	${INSTALL_DATA} ${WRKSRC}/doc/simavr_callgraph.pdf ${STAGEDIR}${DOCSDIR}
55
58
56
post-install-EXAMPLES-on:
59
post-install-EXAMPLES-on:
57
.for BOARDELF in ds1338,ds1338demo hd44780,charlcd i2ctest ledramp simduino ssd1306,ssd1306demo timer_64led
60
.for BOARDELF in ds1338,ds1338demo hd44780,charlcd i2ctest ledramp rotenc,rotenc_test simduino ssd1306,ssd1306demo timer_64led
58
	BOARDELF=${BOARDELF}; \
61
	BOARDELF=${BOARDELF}; \
59
	BOARD=$${BOARDELF%%,*}; \
62
	BOARD=$${BOARDELF%%,*}; \
60
	ELF=$${BOARDELF##*,}; \
63
	ELF=$${BOARDELF##*,}; \
Lines 74-79 post-install-EXAMPLES-on: Link Here
74
		hd44780/atmega48_charlcd \
77
		hd44780/atmega48_charlcd \
75
		i2ctest/atmega1280_i2ctest \
78
		i2ctest/atmega1280_i2ctest \
76
		ledramp/atmega48_ledramp \
79
		ledramp/atmega48_ledramp \
80
		rotenc/atmega32_rotenc_test \
77
		ssd1306/atmega32_ssd1306 \
81
		ssd1306/atmega32_ssd1306 \
78
		timer_64led/atmega168_timer_64led
82
		timer_64led/atmega168_timer_64led
79
	${AVR_STRIP_CMD} ${STAGEDIR}${EXAMPLESDIR}/board_${AXF}.axf
83
	${AVR_STRIP_CMD} ${STAGEDIR}${EXAMPLESDIR}/board_${AXF}.axf
(-)devel/simavr/distinfo (-9 / +3 lines)
Lines 1-9 Link Here
1
TIMESTAMP = 1587070720
1
TIMESTAMP = 1617458891
2
SHA256 (simavr/buserror-simavr-v1.6_GH0.tar.gz) = a55ad04d055eef5656c49f78bc089968b059c6efb6a831618b8d7e67a840936d
2
SHA256 (buserror-simavr-v1.7_GH0.tar.gz) = e7b3d5f0946e84fbe76a37519d0f146d162bbf88641ee91883b3970b02c77093
3
SIZE (simavr/buserror-simavr-v1.6_GH0.tar.gz) = 3317397
3
SIZE (buserror-simavr-v1.7_GH0.tar.gz) = 3322387
4
SHA256 (simavr/86264ad6d0b6b921130e293769d8ebaec512eecd.diff) = cc0b23d08f713bc450013f68df3e7cf2d329aa6eee6d66458e6101349aa10255
5
SIZE (simavr/86264ad6d0b6b921130e293769d8ebaec512eecd.diff) = 313
6
SHA256 (simavr/e5ea627259daae64ddbe67402b6d121e0143cd21.diff) = fef6af9400ad4abd5ad8f0272fb4d656815e289b42e8906476e6e0b0560ab25e
7
SIZE (simavr/e5ea627259daae64ddbe67402b6d121e0143cd21.diff) = 976
8
SHA256 (simavr/082939e64e1632d8ea0b1d6ebea93ca832c9e762.diff) = 70a0d68aa4768062d38e5b816d55506745ea2336b253ce4c275c263cc6ab4634
9
SIZE (simavr/082939e64e1632d8ea0b1d6ebea93ca832c9e762.diff) = 394
(-)devel/simavr/files/patch-Makefile (-12 lines)
Removed Link Here
1
--- Makefile.orig	2020-04-16 22:04:43 UTC
2
+++ Makefile
3
@@ -29,9 +29,6 @@ install:
4
 doc:
5
 	$(MAKE) -C doc RELEASE=$(RELEASE)
6
 
7
-install:
8
-	$(MAKE) -C simavr install
9
-
10
 clean:
11
 	$(MAKE) -C simavr clean
12
 	$(MAKE) -C tests clean
(-)devel/simavr/files/patch-examples_parts_Makefile (-12 lines)
Removed Link Here
1
--- examples/parts/Makefile.orig	2020-04-16 21:45:08 UTC
2
+++ examples/parts/Makefile
3
@@ -44,9 +44,7 @@ ${target}: ${OBJ}/${target}.a
4
 #
5
 # Shared library (Linux only)
6
 #
7
-ifeq (${shell uname}, Linux)
8
 ${target}: ${OBJ}/${target}.so
9
-endif
10
 
11
 clean: clean-${OBJ}
12
 	rm -rf *.hex *.a *.axf *.vcd .*.swo .*.swp .*.swm .*.swn *.so *.o
(-)devel/simavr/files/patch-simavr_Makefile (-34 lines)
Removed Link Here
1
--- simavr/Makefile.orig	2020-04-16 21:45:08 UTC
2
+++ simavr/Makefile
3
@@ -19,7 +19,7 @@
4
 SHELL 			:= ${shell which bash}
5
 SIMAVR_VERSION	:= ${shell \
6
 	git describe --abbrev=0 --tags || \
7
-	echo "unknown" }
8
+	echo "v1.6" }
9
 SIMAVR_REVISION	= 2
10
 
11
 target	= run_avr
12
@@ -54,9 +54,7 @@ ${OBJ}/libsimavr.a	:	${sim_o}
13
 
14
 libsimavr	: config ${OBJ}/libsimavr.a
15
 # shared library won't work that easily on non-linux
16
-ifeq (${shell uname}, Linux)
17
 libsimavr	: ${OBJ}/libsimavr.so
18
-endif
19
 
20
 ${OBJ}/${target}.elf	: libsimavr
21
 ${OBJ}/${target}.elf	: ${OBJ}/${target}.o
22
@@ -94,12 +92,10 @@ install : all
23
 		simavr.pc >$(DESTDIR)/libdata/pkgconfig/simavr.pc
24
 	sed -e "s|PREFIX|${PREFIX}|g" -e "s|VERSION|${SIMAVR_VERSION}|g" \
25
 		simavrparts.pc >$(DESTDIR)/libdata/pkgconfig/simavrparts.pc
26
-ifeq (${shell uname}, Linux)
27
 	$(INSTALL) ${OBJ}/libsimavr.so.1 $(DESTDIR)/lib/
28
 	$(INSTALL) ../examples/parts/${OBJ}/libsimavrparts.so.1 $(DESTDIR)/lib/
29
 	ln -sf libsimavr.so.1 $(DESTDIR)/lib/libsimavr.so
30
 	ln -sf libsimavrparts.so.1 $(DESTDIR)/lib/libsimavrparts.so
31
-endif
32
 	$(MKDIR) $(DESTDIR)/bin
33
 	$(INSTALL) ${OBJ}/${target}.elf $(DESTDIR)/bin/simavr
34
 
(-)devel/simavr/files/patch-simavr_sim_run__avr.c (-11 lines)
Removed Link Here
1
--- simavr/sim/run_avr.c.orig	2018-01-10 10:05:15 UTC
2
+++ simavr/sim/run_avr.c
3
@@ -106,7 +106,7 @@ main(
4
 			display_usage(basename(argv[0]));
5
 		} else if (!strcmp(argv[pi], "-m") || !strcmp(argv[pi], "--mcu")) {
6
 			if (pi < argc-1)
7
-				strncpy(name, argv[++pi], sizeof(name));
8
+				snprintf(name, sizeof(name), "%s", argv[++pi]);
9
 			else
10
 				display_usage(basename(argv[0]));
11
 		} else if (!strcmp(argv[pi], "-f") || !strcmp(argv[pi], "--freq")) {
(-)devel/simavr/pkg-plist (+9 lines)
Lines 23-28 include/simavr/parts/hd44780.h Link Here
23
include/simavr/parts/hd44780_glut.h
23
include/simavr/parts/hd44780_glut.h
24
include/simavr/parts/i2c_eeprom.h
24
include/simavr/parts/i2c_eeprom.h
25
include/simavr/parts/lcd_font.h
25
include/simavr/parts/lcd_font.h
26
include/simavr/parts/rotenc.h
26
include/simavr/parts/ssd1306_glut.h
27
include/simavr/parts/ssd1306_glut.h
27
include/simavr/parts/ssd1306_virt.h
28
include/simavr/parts/ssd1306_virt.h
28
include/simavr/parts/uart_pty.h
29
include/simavr/parts/uart_pty.h
Lines 90-95 libdata/pkgconfig/simavrparts.pc Link Here
90
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/board_ledramp/atmega48_ledramp.c
91
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/board_ledramp/atmega48_ledramp.c
91
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/board_ledramp/ledramp
92
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/board_ledramp/ledramp
92
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/board_ledramp/ledramp.c
93
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/board_ledramp/ledramp.c
94
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/board_rotenc/Makefile
95
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/board_rotenc/README
96
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/board_rotenc/atmega32_rotenc_test.axf
97
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/board_rotenc/atmega32_rotenc_test.c
98
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/board_rotenc/rotenc_test
99
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/board_rotenc/rotenc_test.c
93
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/board_simduino/ATmegaBOOT_168_atmega328.ihex
100
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/board_simduino/ATmegaBOOT_168_atmega328.ihex
94
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/board_simduino/Makefile
101
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/board_simduino/Makefile
95
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/board_simduino/README
102
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/board_simduino/README
Lines 129-134 libdata/pkgconfig/simavrparts.pc Link Here
129
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/parts/i2c_eeprom.c
136
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/parts/i2c_eeprom.c
130
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/parts/i2c_eeprom.h
137
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/parts/i2c_eeprom.h
131
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/parts/lcd_font.h
138
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/parts/lcd_font.h
139
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/parts/rotenc.c
140
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/parts/rotenc.h
132
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/parts/ssd1306_glut.c
141
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/parts/ssd1306_glut.c
133
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/parts/ssd1306_glut.h
142
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/parts/ssd1306_glut.h
134
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/parts/ssd1306_virt.c
143
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/parts/ssd1306_virt.c

Return to bug 254761