Re: Trouble Cross-compiling for hpcarm (seems related to lang/gcc2)

Ax0n <[email protected]> Wed, 1 Jun 2016 13:29:15 -0500
Newsgroups gmane.os.netbsd.devel.pkgsrc.user,gmane.os.netbsd.ports.hpcarm
Message-ID <CABmxVL0OSn7_dmXya5bvwJCs-8y6iv0Wpy5jf1vZvjHEDX-QPg@mail.gmail.com>
--001a1140717ec093f005343baaa8
Content-Type: text/plain; charset=UTF-8

Robert,
Using MACHINE=earmv4 worked. I was able to build cross/libtool-base
successfully and I've built bash and its dependencies as a simple test. All
seems well. I'll have to re-build the distribution with X11 enabled, but
that's probably just an hour or two on my build environment.

Should I happen to build a bunch of packages for NetBSD 7.0.1 hpcarm ,
would there be any interest in including those binary packages in the
pkgsrc mirror? Who maintains binary package repositories for individual
architectures?

On Tue, May 31, 2016 at 3:11 PM, Ax0n <[email protected]> wrote:

> I haven't gotten any packages to build yet. "./build.sh -m hpcarm
> kernel=JORNADA720 distribution" did render a nice sandbox of the hpcarm
> base userland in $DESTDIR. gcc2 is an early dependency of cross/libtool-base
> which I have to get up and running first. /usr/pkgsrc/packages.* doesn't
> exist yet.
>
> Thanks for the heads' up on MACHINE_ARCH. That also explains why packages
> I build on my RPi2 (earmv6hf NetBSD-7.0.0-PATCH) don't run on my lowly
> earmv4 H/PCs. I'm still a newbie. I'll give your suggestions a shot and let
> you know how it goes.
>
>
> On Tue, May 31, 2016 at 2:39 PM, Robert Swindells <[email protected]> wrote:
>
>>
>> Ax0n <[email protected]> wrote:
>> >I currently have three NetBSD/hpcarm systems stuck on NetBSD 6.1 due to
>> the
>> >lack of binary packages in pkgsrc. I'd love to move them over to 7.0.1. I
>> >am trying to build hpcarm binaries under NetBSD-7.0.1/amd64 and I've run
>> >into the same trouble as outlined at the bottom of this page by Silas
>> Cou:
>> >http://www.silas.net.br/tech/pkgsrc/pkgsrc-troubleshooting.html
>> >
>> >This is on a fresh install of NetBSD/amd64. I unpacked pkgsrc from inside
>> >the installer, then followed the instructions outlined here:
>> >
>> ftp://ftp.netbsd.org/pub/pkgsrc/current/pkgsrc/doc/HOWTO-use-crosscompile
>>
>> What have you got built so far ?
>>
>> [snip]
>>
>> >mk.conf is as follows (comments stripped for brevity)
>> >
>> >USE_CROSS_COMPILE?=  yes
>> >CROSSBASE=  ${LOCALBASE}/cross-${TARGET_ARCH:U${MACHINE_ARCH}}
>> >.if !empty(USE_CROSS_COMPILE:M[yY][eE][sS])
>> >MACHINE=hpcarm
>> >MACHINE_ARCH=  arm
>>
>> This line should be 'earmv4' not 'arm'.
>>
>> >TOOLDIR= /usr/obj/tooldir.NetBSD-7.0.1-amd64
>> >CROSS_DESTDIR= /usr/obj/destdir.hpcarm
>> >PACKAGES=${PKGSRCDIR}/packages.${MACHINE_ARCH}
>> >WRKDIR_BASENAME=  work.${MACHINE_ARCH}
>> >.endif
>>
>> I would delete your TOOLDIR and CROSS_DESTDIR and start again with
>> the new value for MACHINE_ARCH.
>>
>> Robert Swindells
>>
>
>

--001a1140717ec093f005343baaa8
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">Robert,<div>Using MACHINE=3Dearmv4 worked. I was able to b=
uild cross/libtool-base successfully and I&#39;ve built bash and its depend=
encies as a simple test. All seems well. I&#39;ll have to re-build the dist=
ribution with X11 enabled, but that&#39;s probably just an hour or two on m=
y build environment.=C2=A0</div><div><br></div><div>Should I happen to buil=
d a bunch of packages for NetBSD 7.0.1 hpcarm , would there be any interest=
 in including those binary packages in the pkgsrc mirror? Who maintains bin=
ary package repositories for individual architectures?</div></div><div clas=
s=3D"gmail_extra"><br><div class=3D"gmail_quote">On Tue, May 31, 2016 at 3:=
11 PM, Ax0n <span dir=3D"ltr">&lt;<a href=3D"mailto:[email protected]" target=
=3D"_blank">[email protected]</a>&gt;</span> wrote:<br><blockquote class=3D"gm=
ail_quote" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-le=
ft:1ex"><div dir=3D"ltr">I haven&#39;t gotten any packages to build yet. &q=
uot;./build.sh -m hpcarm kernel=3DJORNADA720 distribution&quot;<span style=
=3D"color:rgb(0,0,0);white-space:pre-wrap"> did render a nice sandbox of th=
e hpcarm base userland in $DESTDIR.</span>=C2=A0<font color=3D"#000000"><sp=
an style=3D"white-space:pre-wrap">gcc2 is</span></font>=C2=A0an early depen=
dency of=C2=A0<span style=3D"color:rgb(0,0,0);white-space:pre-wrap">cross/l=
ibtool-base which I have to get up and running first. /usr/pkgsrc/packages.=
* doesn&#39;t exist yet.=C2=A0                 </span><div><span style=3D"c=
olor:rgb(0,0,0);white-space:pre-wrap"><br></span></div><div><span style=3D"=
color:rgb(0,0,0);white-space:pre-wrap">Thanks for the heads&#39; up on MACH=
INE_ARCH. That also explains why packages I build on my RPi2 (earmv6hf NetB=
SD-7.0.0-PATCH) don&#39;t run on my lowly earmv4 H/PCs. I&#39;m still a new=
bie. I&#39;ll give your suggestions a shot and let you know how it goes.</s=
pan></div><div><div><div><div><span style=3D"color:rgb(0,0,0);white-space:p=
re-wrap"><br></span></div></div></div></div></div><div class=3D"HOEnZb"><di=
v class=3D"h5"><div class=3D"gmail_extra"><br><div class=3D"gmail_quote">On=
 Tue, May 31, 2016 at 2:39 PM, Robert Swindells <span dir=3D"ltr">&lt;<a hr=
ef=3D"mailto:[email protected]" target=3D"_blank">[email protected]</a>&gt;</span=
> wrote:<br><blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;bo=
rder-left:1px #ccc solid;padding-left:1ex"><span><br>
Ax0n &lt;<a href=3D"mailto:[email protected]" target=3D"_blank">[email protected]=
</a>&gt; wrote:<br>
&gt;I currently have three NetBSD/hpcarm systems stuck on NetBSD 6.1 due to=
 the<br>
&gt;lack of binary packages in pkgsrc. I&#39;d love to move them over to 7.=
0.1. I<br>
&gt;am trying to build hpcarm binaries under NetBSD-7.0.1/amd64 and I&#39;v=
e run<br>
&gt;into the same trouble as outlined at the bottom of this page by Silas C=
ou:<br>
&gt;<a href=3D"http://www.silas.net.br/tech/pkgsrc/pkgsrc-troubleshooting.h=
tml" rel=3D"noreferrer" target=3D"_blank">http://www.silas.net.br/tech/pkgs=
rc/pkgsrc-troubleshooting.html</a><br>
&gt;<br>
&gt;This is on a fresh install of NetBSD/amd64. I unpacked pkgsrc from insi=
de<br>
&gt;the installer, then followed the instructions outlined here:<br>
&gt;<a href=3D"ftp://ftp.netbsd.org/pub/pkgsrc/current/pkgsrc/doc/HOWTO-use=
-crosscompile" rel=3D"noreferrer" target=3D"_blank">ftp://ftp.netbsd.org/pu=
b/pkgsrc/current/pkgsrc/doc/HOWTO-use-crosscompile</a><br>
<br>
</span>What have you got built so far ?<br>
<br>
[snip]<br>
<span><br>
&gt;mk.conf is as follows (comments stripped for brevity)<br>
&gt;<br>
&gt;USE_CROSS_COMPILE?=3D=C2=A0 yes<br>
&gt;CROSSBASE=3D=C2=A0 ${LOCALBASE}/cross-${TARGET_ARCH:U${MACHINE_ARCH}}<b=
r>
&gt;.if !empty(USE_CROSS_COMPILE:M[yY][eE][sS])<br>
&gt;MACHINE=3Dhpcarm<br>
&gt;MACHINE_ARCH=3D=C2=A0 arm<br>
<br>
</span>This line should be &#39;earmv4&#39; not &#39;arm&#39;.<br>
<span><br>
&gt;TOOLDIR=3D /usr/obj/tooldir.NetBSD-7.0.1-amd64<br>
&gt;CROSS_DESTDIR=3D /usr/obj/destdir.hpcarm<br>
&gt;PACKAGES=3D${PKGSRCDIR}/packages.${MACHINE_ARCH}<br>
&gt;WRKDIR_BASENAME=3D=C2=A0 work.${MACHINE_ARCH}<br>
&gt;.endif<br>
<br>
</span>I would delete your TOOLDIR and CROSS_DESTDIR and start again with<b=
r>
the new value for MACHINE_ARCH.<br>
<span><font color=3D"#888888"><br>
Robert Swindells<br>
</font></span></blockquote></div><br></div>
</div></div></blockquote></div><br></div>

--001a1140717ec093f005343baaa8--