<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="bbPress/1.0.2" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>LeafLabs Garden &#187; Topic: Compiling toolchain for libmaple in OpenBSD</title>
		<link>http://forums.leaflabs.com/topic.php?id=74409</link>
		<description>A place to share, learn, and grow...</description>
		<language>en-US</language>
		<pubDate>Fri, 22 Jan 2016 00:09:57 +0000</pubDate>
		<generator>http://bbpress.org/?v=1.0.2</generator>
		<textInput>
			<title><![CDATA[Search]]></title>
			<description><![CDATA[Search all topics from these forums.]]></description>
			<name>q</name>
			<link>http://forums.leaflabs.com/search.php</link>
		</textInput>
		<atom:link href="http://forums.leaflabs.com/rss.php?topic=74409" rel="self" type="application/rss+xml" />

		<item>
			<title>dbolgheroni on "Compiling toolchain for libmaple in OpenBSD"</title>
			<link>http://forums.leaflabs.com/topic.php?id=74409#post-105632</link>
			<pubDate>Mon, 19 Jan 2015 15:02:14 +0000</pubDate>
			<dc:creator>dbolgheroni</dc:creator>
			<guid isPermaLink="false">105632@http://forums.leaflabs.com/</guid>
			<description>&#60;p&#62;Time is missing for me these days, but pretty sure I'll look into that.&#60;/p&#62;
&#60;p&#62;Thank you.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>ventosus on "Compiling toolchain for libmaple in OpenBSD"</title>
			<link>http://forums.leaflabs.com/topic.php?id=74409#post-105631</link>
			<pubDate>Sun, 18 Jan 2015 13:22:23 +0000</pubDate>
			<dc:creator>ventosus</dc:creator>
			<guid isPermaLink="false">105631@http://forums.leaflabs.com/</guid>
			<description>&#60;p&#62;You may want to base your effort off a more up-to-date toolchain than the CodeSourcery one...&#60;br /&#62;
and on libmaple from git HEAD.&#60;/p&#62;
&#60;p&#62;This tool chain works flawlessly with libmaple from git HEAD.&#60;br /&#62;
&#60;a href=&#34;https://launchpad.net/gcc-arm-embedded&#34; rel=&#34;nofollow&#34;&#62;https://launchpad.net/gcc-arm-embedded&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;Apart from binaries for Linux/OSX/Windows, they provide a source package and build instructions.&#60;br /&#62;
&#60;a href=&#34;https://launchpad.net/gcc-arm-embedded/+download&#34; rel=&#34;nofollow&#34;&#62;https://launchpad.net/gcc-arm-embedded/+download&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;There is an existing port for FreeBSD also&#60;br /&#62;
&#60;a href=&#34;http://www.freshports.org/devel/gcc-arm-embedded/&#34; rel=&#34;nofollow&#34;&#62;http://www.freshports.org/devel/gcc-arm-embedded/&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;Update: I've just tested the gcc-arm-embedded toolchain in my FreeBSD VM and the code runs just as fine on the Maple as if compiled from Linux ;-)
&#60;/p&#62;</description>
		</item>
		<item>
			<title>dbolgheroni on "Compiling toolchain for libmaple in OpenBSD"</title>
			<link>http://forums.leaflabs.com/topic.php?id=74409#post-105628</link>
			<pubDate>Fri, 16 Jan 2015 07:57:51 +0000</pubDate>
			<dc:creator>dbolgheroni</dc:creator>
			<guid isPermaLink="false">105628@http://forums.leaflabs.com/</guid>
			<description>&#60;p&#62;No. I'm checking again because I'm concerned it's something related to libgloss, which I missed in my  previous attempts.&#60;/p&#62;
&#60;p&#62;Thank you.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>bobc on "Compiling toolchain for libmaple in OpenBSD"</title>
			<link>http://forums.leaflabs.com/topic.php?id=74409#post-105627</link>
			<pubDate>Thu, 15 Jan 2015 14:31:50 +0000</pubDate>
			<dc:creator>bobc</dc:creator>
			<guid isPermaLink="false">105627@http://forums.leaflabs.com/</guid>
			<description>&#60;p&#62;Does it run ok if you power cycle the board?
&#60;/p&#62;</description>
		</item>
		<item>
			<title>dbolgheroni on "Compiling toolchain for libmaple in OpenBSD"</title>
			<link>http://forums.leaflabs.com/topic.php?id=74409#post-105625</link>
			<pubDate>Wed, 14 Jan 2015 17:39:59 +0000</pubDate>
			<dc:creator>dbolgheroni</dc:creator>
			<guid isPermaLink="false">105625@http://forums.leaflabs.com/</guid>
			<description>&#60;p&#62;Just to note that despite the fact that it refers to OpenBSD, the steps taken are exactly the same as if it was a Linux system.&#60;/p&#62;
&#60;p&#62;Thank you.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>dbolgheroni on "Compiling toolchain for libmaple in OpenBSD"</title>
			<link>http://forums.leaflabs.com/topic.php?id=74409#post-105623</link>
			<pubDate>Tue, 13 Jan 2015 16:39:21 +0000</pubDate>
			<dc:creator>dbolgheroni</dc:creator>
			<guid isPermaLink="false">105623@http://forums.leaflabs.com/</guid>
			<description>&#60;p&#62;Hi,&#60;/p&#62;
&#60;p&#62;I'm building a port of libmaple for OpenBSD. I'll try to simplify the&#60;br /&#62;
steps I followed as much as possible.&#60;/p&#62;
&#60;p&#62;I have the Sourcery Unix toolchain available on LeafLabs website&#60;br /&#62;
(gcc-arm-none-eabi-latest-linux32.tar.gz) as a base for the new&#60;br /&#62;
toolchain. In Linux, I can compile and upload a binary for a Maple Mini&#60;br /&#62;
without problems (without the IDE).&#60;/p&#62;
&#60;p&#62;From Linux, I extracted the configure args of the Unix&#60;br /&#62;
toolchain with:&#60;/p&#62;
&#60;blockquote&#62;&#60;p&#62;$ arm-none-eabi-gcc -v&#60;br /&#62;
Using built-in specs.&#60;br /&#62;
Target: arm-none-eabi&#60;br /&#62;
Configured with: /scratch/julian/2010q1-release-eabi-lite/src/gcc-4.4-2010q1/configure --build=i686-pc-linux-gnu --host=i686-pc-linux-gnu --target=arm-none-eabi --enable-threads --disable-libmudflap --disable-libssp --disable-libstdcxx-pch --enable-extra-sgxxlite-multilibs --with-gnu-as --with-gnu-ld --with-specs='%{O2:%{!fno-remove-local-statics: -fremove-local-statics}} %{O*:%{O&#124;O0&#124;O1&#124;O2&#124;Os:;:%{!fno-remove-local-statics: -fremove-local-statics}}}' --enable-languages=c,c++ --disable-shared --disable-lto --with-newlib --with-pkgversion='Sourcery G++ Lite 2010q1-188' --with-bugurl=https://support.codesourcery.com/GNUToolchain/ --disable-nls --prefix=/opt/codesourcery --with-headers=yes --with-sysroot=/opt/codesourcery/arm-none-eabi --with-build-sysroot=/scratch/julian/2010q1-release-eabi-lite/install/arm-none-eabi --with-gmp=/scratch/julian/2010q1-release-eabi-lite/obj/host-libs-2010q1-188-arm-none-eabi-i686-pc-linux-gnu/usr --with-mpfr=/scratch/julian/2010q1-release-eabi-lite/obj/host-libs-2010q1-188-arm-none-eabi-i686-pc-linux-gnu/usr --with-ppl=/scratch/julian/2010q1-release-eabi-lite/obj/host-libs-2010q1-188-arm-none-eabi-i686-pc-linux-gnu/usr --with-host-libstdcxx='-static-libgcc -Wl,-Bstatic,-lstdc++,-Bdynamic -lm' --with-cloog=/scratch/julian/2010q1-release-eabi-lite/obj/host-libs-2010q1-188-arm-none-eabi-i686-pc-linux-gnu/usr --disable-libgomp --enable-poison-system-directories --with-build-time-tools=/scratch/julian/2010q1-release-eabi-lite/install/arm-none-eabi/bin --with-build-time-tools=/scratch/julian/2010q1-release-eabi-lite/install/arm-none-eabi/bin&#60;br /&#62;
Thread model: single&#60;br /&#62;
gcc version 4.4.1 (Sourcery G++ Lite 2010q1-188)
&#60;/p&#62;&#60;/blockquote&#62;
&#60;p&#62;So I sorted this all to create a cross compiler toolchain based on the&#60;br /&#62;
toolchain above in OpenBSD. After compiling binutils, gcc, newlib and&#60;br /&#62;
libstdc++-v3, I succeeded compiling libmaple + a simple Blink.  Then&#60;br /&#62;
downloaded maple_mini.bin into the board with dfu-util 0.8.&#60;/p&#62;
&#60;p&#62;The problem: after downloading the .bin and resetting the board, the&#60;br /&#62;
program won't run after the bootloader stops. I've tried all sorts of&#60;br /&#62;
configure args possible for gcc, but somehow gcc isn't generating code&#60;br /&#62;
compatible with Cortex-M3/Maple or is something else I'm missing.&#60;/p&#62;
&#60;p&#62;Question: are there something obvious am I missing? Maybe some starting&#60;br /&#62;
point or something like alike.&#60;/p&#62;
&#60;p&#62;Also had to modify support/make/target-config.mk&#60;/p&#62;
&#60;blockquote&#62;&#60;p&#62;-TARGET_FLAGS += -mcpu=cortex-m3 -march=armv7-m&#60;br /&#62;
+TARGET_FLAGS += -mcpu=cortex-m3
&#60;/p&#62;&#60;/blockquote&#62;
&#60;p&#62;since this leads to:&#60;/p&#62;
&#60;blockquote&#62;&#60;p&#62;error: switch -mcpu=cortex-m3 conflicts with -march= switch
&#60;/p&#62;&#60;/blockquote&#62;
&#60;p&#62;Any help is appreciated.&#60;br /&#62;
Thank you.
&#60;/p&#62;</description>
		</item>

	</channel>
</rss>
