diff options
author | bsiegert <bsiegert> | 2016-05-23 05:13:13 +0000 |
---|---|---|
committer | bsiegert <bsiegert> | 2016-05-23 05:13:13 +0000 |
commit | 8839b7d7efb53af86e573183fb7cc1fa981076c6 (patch) | |
tree | 995847aabf284d5213184547a9d7d231877b4357 /cross/uisp/patches/patch-src_AvrDummy.C | |
parent | 3bd833f6e4212f596047a7740fcf4eb6948e9906 (diff) | |
download | pkgsrc-8839b7d7efb53af86e573183fb7cc1fa981076c6.tar.gz |
Pullup ticket #5021 - requested by joerg
cross/uisp: build fix
Revisions pulled up:
- cross/uisp/distinfo 1.7
- cross/uisp/patches/patch-src_AvrAtmel.C 1.1
- cross/uisp/patches/patch-src_AvrDummy.C 1.1
- cross/uisp/patches/patch-src_Stk500.C 1.2
---
Module Name: pkgsrc
Committed By: joerg
Date: Wed May 18 20:18:32 UTC 2016
Modified Files:
pkgsrc/cross/uisp: distinfo
pkgsrc/cross/uisp/patches: patch-src_Stk500.C
Added Files:
pkgsrc/cross/uisp/patches: patch-src_AvrAtmel.C patch-src_AvrDummy.C
Log Message:
Under C++11 it is invalid to implicitly cast from a larger type to a
smaller type in an initializer. Adjust various places accordingly.
Avoid set-but-not-used warnings in some other places for newer GCC.
Diffstat (limited to 'cross/uisp/patches/patch-src_AvrDummy.C')
-rw-r--r-- | cross/uisp/patches/patch-src_AvrDummy.C | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/cross/uisp/patches/patch-src_AvrDummy.C b/cross/uisp/patches/patch-src_AvrDummy.C new file mode 100644 index 00000000000..b6fd30dc9a5 --- /dev/null +++ b/cross/uisp/patches/patch-src_AvrDummy.C @@ -0,0 +1,37 @@ +$NetBSD: patch-src_AvrDummy.C,v 1.1.2.2 2016/05/23 05:13:13 bsiegert Exp $ + +--- src/AvrDummy.C.orig 2016-05-18 12:26:28.000000000 +0000 ++++ src/AvrDummy.C +@@ -81,12 +81,12 @@ TByte + TAvrDummy::GetPartInfo(TAddr addr) + { + if (at89) { +- TByte info [4] = { 0x28, addr & 0x1f, 0, 0 }; ++ TByte info [4] = { 0x28, TByte(addr & 0x1f), 0, 0 }; + Send(info, 4); + return info[3]; + } + +- TByte info [4] = { 0x30, 0, addr, 0 }; ++ TByte info [4] = { 0x30, 0, TByte(addr), 0 }; + Send(info, 4); + return info[3]; + } +@@ -289,7 +289,7 @@ TAvrDummy::ReadCalByte(TByte addr) + void + TAvrDummy::WriteOldFuseBits(TByte val) + { +- TByte oldfuse[4] = { 0xAC, (val & 0x1F) | 0xA0, 0, 0xD2 }; ++ TByte oldfuse[4] = { 0xAC, TByte((val & 0x1F) | 0xA0), 0, 0xD2 }; + Send(oldfuse, 4); + } + +@@ -532,7 +532,7 @@ TAvrDummy::WriteLockBits(TByte bits) + { + /* This handles both old (byte 2, bits 1-2) + and new (byte 4, bits 0-5) devices. */ +- TByte lock[4] = { 0xAC, 0xF9 | ((bits << 1) & 0x06), 0xFF, bits }; ++ TByte lock[4] = { 0xAC, TByte(0xF9 | ((bits << 1) & 0x06)), 0xFF, bits }; + TByte rbits; + + if (at89) |