From: "Philippe Mathieu-Daudé" <philmd@linaro.org>
To: cauldwell.thomas@gmail.com
Cc: qemu-discuss@nongnu.org, QEMU Developers <qemu-devel@nongnu.org>
Subject: Re: sparc64 -- cannot get 'Hello World' to run
Date: Wed, 2 Aug 2023 23:02:12 +0200 [thread overview]
Message-ID: <fd0112a7-6fdd-fd5a-bd25-f9adfe2ee140@linaro.org> (raw)
In-Reply-To: <CALtZhhOwsquhcHK0aOEn89tu7DynEMeiDZ=aaropn8Hkiyy+qA@mail.gmail.com>
Hi Frederick,
On 2/8/23 22:36, Frederick Virchanza Gotham wrote:
> On Wed, Aug 2, 2023 at 11:04 AM Frederick Virchanza Gotham wrote:
>>
>> I can't get sparc64 to work at all though. Even I make a simple 'Hello
>> World' program in C using only "puts", if I try to use qemu-user to
>> run it, it crashes.
>
>
> You can try the following at the command line in Ubuntu 23.04:
>
> $ echo -e "#include <stdio.h> \n int main(void) { puts(\"Hello
> World\"); }" > test.cpp
> $ sparc64-linux-gnu-g++ -o test test.cpp -static
> $ qemu-sparc64-static ./test
> Segmentation fault (core dumped)
> $ qemu-sparc-static ./test
> qemu-sparc-static: ./test: Invalid ELF image for this architecture
> $ qemu-sparc32plus-static ./test
> qemu-sparc32plus-static: ./test: Invalid ELF image for this architecture
>
> Making static executables can be temperamental on a few different
> platforms, and so I tried to make a dynamically linked executable by
> providing ld-linux.so.2 as well as the libc files. Still it crashes.
>
> Has anyone been able to get use 'qemu' on the binaries produces by the
> cross-compiler 'sparc64-g++' ?
Can you create an issue on https://gitlab.com/qemu-project/qemu/-/issues
and attach the static binary you built, that way we can reproduce your
problem.
Thanks!
Phil.
next parent reply other threads:[~2023-08-02 21:03 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CALtZhhPmFfMpGoCPtdEMjYES2c3WrwPYq==sj+HbwBLZ8ZYTgw@mail.gmail.com>
[not found] ` <CALtZhhOwsquhcHK0aOEn89tu7DynEMeiDZ=aaropn8Hkiyy+qA@mail.gmail.com>
2023-08-02 21:02 ` Philippe Mathieu-Daudé [this message]
2023-08-03 7:35 ` sparc64 -- cannot get 'Hello World' to run Michael Tokarev
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=fd0112a7-6fdd-fd5a-bd25-f9adfe2ee140@linaro.org \
--to=philmd@linaro.org \
--cc=cauldwell.thomas@gmail.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-discuss@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).