Bug 218221 - [patch] devel/arduino-core: Update avr, sam, samd cores, patches
Summary: [patch] devel/arduino-core: Update avr, sam, samd cores, patches
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Boris Samorodov
URL:
Keywords: patch
Depends on: 218235 218241
Blocks: 218282
  Show dependency treegraph
 
Reported: 2017-03-30 02:12 UTC by Kyle Evans
Modified: 2017-04-19 20:35 UTC (History)
1 user (show)

See Also:
bsam: maintainer-feedback+


Attachments
svn(1) diff of devel/arduino-core (16.14 KB, patch)
2017-03-30 02:12 UTC, Kyle Evans
no flags Details | Diff
svn(1) diff of devel/arduino-core (19.65 KB, patch)
2017-03-30 19:01 UTC, Kyle Evans
kevans: maintainer-approval+
Details | Diff
svn(1) diff of devel/arduino-core (20.69 KB, patch)
2017-03-30 23:47 UTC, Kyle Evans
kevans: maintainer-approval+
Details | Diff
svn(1) diff of devel/arduino-core (21.82 KB, patch)
2017-03-31 15:45 UTC, Kyle Evans
kevans: maintainer-approval+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Kyle Evans freebsd_committer 2017-03-30 02:12:46 UTC
Created attachment 181301 [details]
svn(1) diff of devel/arduino-core

Hello!

avr, sam, and samd cores have all seen a general update. The sam core has been split out into its own repository, so we reflect that here. Finally, update patches to reflect reality more closely so we don't get further and further out of sync with upstream. More boards have been added in the interim since the last update to include support for arduino.org boards.

Do note that we pull the core from the 1.8.2 tag, but it is actually avr core version 1.6.18.
Comment 1 Kyle Evans freebsd_committer 2017-03-30 17:44:28 UTC
They seem to have re-rolled the distfile sometime this morning, switched it to .xz and now sign all of their releases...this will need to be changed up a little bit.
Comment 2 Kyle Evans freebsd_committer 2017-03-30 19:01:43 UTC
Created attachment 181323 [details]
svn(1) diff of devel/arduino-core

Alright, updated version -- some bootloader stuff was also missed, so bring those into the pkg-plist and patch the different `platform.txt` to use devel/arduino-avrdude instead of devel/avrdude.

Looked over with: portlint -AC
Built with: poudriere (-HEAD, amd64)
Confirmed functional with: Uno on -HEAD, amd64
Comment 3 Kyle Evans freebsd_committer 2017-03-30 23:47:17 UTC
Created attachment 181335 [details]
svn(1) diff of devel/arduino-core

Alright, last goof up -- some conflicts arose because I was testing the new core against arduino18, where some things are a little bit different and incompatible in interesting ways. I also missed the SAM core version bump to 1.6.11, which causes the SAM core to no longer be detected.
Comment 4 Boris Samorodov freebsd_committer 2017-03-31 12:53:50 UTC
Take.
Comment 5 Kyle Evans freebsd_committer 2017-03-31 15:45:53 UTC
Created attachment 181353 [details]
svn(1) diff of devel/arduino-core

Updating this to go ahead and remove the hack for arduino16 compatibility, since I will be submitting the arduino18 update within a day or so.

I've also updated this to take advantage of the -a flag that devel/bossa is growing, this makes flashing SAM boards actually work.
Comment 6 commit-hook freebsd_committer 2017-04-19 20:28:37 UTC
A commit references this bug:

Author: bsam
Date: Wed Apr 19 20:28:06 UTC 2017
New revision: 438913
URL: https://svnweb.freebsd.org/changeset/ports/438913

Log:
  devel/arduino-core: avr, sam, and samd cores have all seen a general update.

  PR:		218221
  Submitted by:	Kyle Evans <bsdports@kyle-evans.net> (maintainer)

Changes:
  head/devel/arduino-core/Makefile
  head/devel/arduino-core/distinfo
  head/devel/arduino-core/files/extrapatch-hardware_arduino_samd_platform.txt
  head/devel/arduino-core/files/patch-hardware_arduino_avr_platform.txt
  head/devel/arduino-core/files/patch-hardware_arduino_sam_platform.txt
  head/devel/arduino-core/files/patch-hardware_package__index__bundled.json
  head/devel/arduino-core/pkg-plist
Comment 7 Boris Samorodov freebsd_committer 2017-04-19 20:30:39 UTC
Committed, thanks!

Kyle, you've made some changes to patches. If I messed something just ping me up.
Comment 8 Kyle Evans freebsd_committer 2017-04-19 20:35:36 UTC
(In reply to Boris Samorodov from comment #7)

Hi,

Oy! I messed up! Can you please apply the following change to devel/arduino-core's Makefile as soon as you're able? The patches look good, thanks!


Index: Makefile
===================================================================
--- Makefile    (revision 438913)
+++ Makefile    (working copy)
@@ -33,7 +33,7 @@
 .include <bsd.port.pre.mk>

 post-patch:
-       @${REINPLACE_CMD} -e 's|%%ARCH%%|${ARDUINO_ARCH}|g' -e 's|%%OSREL%%|${OSREL:R}|g' ${WRKSRC}/hardware/package_index_bundled.jso                                                                                                                                         n
+       @${REINPLACE_CMD} -e 's|%%ARCH%%|${ARCH}|g' -e 's|%%OSREL%%|${OSREL:R}|g' ${WRKSRC}/hardware/package_index_bundled.json

 do-install:
        (cd ${WRKSRC}/ && ${COPYTREE_SHARE} "hardware" ${STAGEDIR}${PREFIX}/arduino ${FIND_EXPR})