Re: Developer environment setup problem

[email protected] Mon, 16 Jun 2025 20:36:28 +0000
Newsgroups gmane.os.hurd.bugs,gmane.os.hurd.general
Message-ID <[email protected]>
June 16, 2025 at 11:10 AM, "Milos Nikic" <[email protected] mailto:ni=
[email protected]?to=3D%22Milos%20Nikic%22%20%3Cnikic.milos%40gmail.com=
%3E > wrote:



>=20
>=20Hello,=C2=A0
>=20
>=20Thanks for the email.
> The thing is I am not cross compiling. I am instead compiling from insi=
de Hurd (in Qemu).
> Yet cannot seem to get it quite right (even though it compiles successf=
ully=C2=A0inside Hurd, when I copy it to /boot it panics on the next rebo=
ot).
>=20
>=20Is a cross compiling=C2=A0route recommended instead?

If you are running Debian GNU/Hurd in qemu, then you can use the "Debian"=
 way
to compile GNU Mach & the Hurd.  I think that way is fairly easy-ish.  An=
d it
makes it easy to apply the Debian specific patches, which you WILL WANT t=
o do.

https://www.gnu.org/software/hurd/contributing.html#index4h2

After you clone the repos, you can move into GNU Mach directory for insta=
nce.

And apply the Debian specific patches.  These are patches that mostly wor=
k,
but are NOT quite polished enough=20

=20via ... I forget the command it's something like

COMMAND_NAME -a

That applies all of the debian specific commands.  Make your changes, the=
n=20
just=20running make will make GNU Mach.   I think 'make install' should
install your changed kernel.  Ask in #hurd what is the command name to=20
apply=20the Debian Specific patches.

There are also Debian specific patches for the Hurd repo.
=20
>=20On Mon, Jun 16, 2025 at 2:41 AM Almudena Garcia <liberamenso10000@gma=
il.com mailto:[email protected] > wrote:
>=20
>=20>=20
>=20> Hi:
> >=20
>=20> To cross-compile gnumach from Linux you have to specify some flags =
in configure, to indicate the hurd architecture.
> >=20
>=20> You can find the flag list here:
> > https://www.gnu.org/software/hurd/microkernel/mach/gnumach/building.h=
tml
> >=20
>=20> Read the instructions for non-Debian systems and 64-bit, and try ag=
ain
> >=20
>=20> P.S.: I redirect this mail to bug-hurd, which is the main maillist =
now
> >=20
>=20> El lunes 16 de junio de 2025, Milos Nikic escribi=C3=B3:
> > > Hello there,
> > >=20
>=20> > I am Milos, I am interested in writing code for Hurd.
> > > I am developing inside qemu (on Arch linux) with debian
> > > image debian-hurd-20230608.img.
> > > It loads, boots and looks good! I can use it!
> > > However, since I want to contribute code I need more than just that=
.
> > >=20
>=20> > I git pulled mig, gnumach and hurd.
> > > I have installed MIG.
> > >=20
>=20> > $ mig --version
> > > mig (GNU MIG) 1.8
> > >=20
>=20> > When i ".configure" and then make gnumach it passes.
> > > However when i copy it to my /boot/ and then point GRUB to it, i ge=
t kernel
> > > panic on next reboot:.
> > >=20
>=20> > "Kernel page fault at address 0xc1000000, eip =3D 0xc10a73f6
> > > Kernel Page fault trap, eip 0xc10a73f6
> > > kernel trap, type 14, code =3D 3
> > > Dump of i386_saved_state c11dbe98:
> > > EAX fffffffc EBX c008993c ECX 3fc22677 EDX 00008000
> > > ESI c0ff6e28 EDI c0fffffe EBP c07a3010 ESP 00000004
> > > CS 0008 SS 0000 DS 0010 ES 0010 FS 0010 GS 0010
> > > v86:=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 DS 000c ES 0000 FS c0=
37 GS c037
> > > EIP c10a73f6 EFLAGS 00010016
> > > trapno 14: Page fault, error 00000003
> > > panic i386/i386/trap.c:347: kernel_trap: trap"
> > >=20
>=20> > I tried on the current HEAD, I also tried with the tag v1.8+git20=
230526
> > > which is the code that is, I believe, pushed to debian repositories=
.
> > >=20
>=20> > I get the same kernel panic, no matter what commit I try.
> > >=20
>=20> > I would like to contribute, but I need a way to test my changes l=
ocally
> > > before sending in patches.
> > >=20
>=20> > Is there a recommended way to develop and test? Or if you can hel=
p me what
> > > exactly am i doing or, what am i missing.
> > >=20
>=20> > Thanks in advance,
> > > Milos
> > >
> >=20
>=20> --=20
>=20> Enviado desde mi dispositivo Sailfish
> >
>