diff mbox series

build: add hint for interpreter location fix

Message ID 20201221101809.913059-1-npiggin@gmail.com
State Accepted
Headers show
Series build: add hint for interpreter location fix | expand

Commit Message

Nicholas Piggin Dec. 21, 2020, 10:18 a.m. UTC
For some reason my environment requires this.

Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
---
 README.md | 6 ++++++
 1 file changed, 6 insertions(+)

Comments

Joel Stanley Jan. 11, 2021, 4:58 a.m. UTC | #1
On Mon, 21 Dec 2020 at 10:18, Nicholas Piggin <npiggin@gmail.com> wrote:
>
> For some reason my environment requires this.
>
> Signed-off-by: Nicholas Piggin <npiggin@gmail.com>



> ---
>  README.md | 6 ++++++
>  1 file changed, 6 insertions(+)
>
> diff --git a/README.md b/README.md
> index abc2088..7892a8d 100644
> --- a/README.md
> +++ b/README.md
> @@ -25,6 +25,12 @@ make
>  rsync pdbg root@bmc:/usr/local/bin
>  ```
>
> +Depending on your cross compile environment, you may get a message like
> +`pdbg: No such file or directory` when execting the binary on the BMC,
> +which may be fixable by correcting loader location:
> +
> +`patchelf --set-interpreter /lib/ld-linux-armhf.so.3 pdbg`

Interesting. What toolchain do you use?

What does patchelf --print-interpreter tell you before you patch it?

Regardless:

Reviewed-by: Joel Stanley <joel@jms.id.au>

> +
>  ## Usage
>
>  Several backends are supported depending on which system you are using and are
> --
> 2.23.0
>
> --
> Pdbg mailing list
> Pdbg@lists.ozlabs.org
> https://lists.ozlabs.org/listinfo/pdbg
Nicholas Piggin Jan. 13, 2021, 5:06 a.m. UTC | #2
Excerpts from Joel Stanley's message of January 11, 2021 2:58 pm:
> On Mon, 21 Dec 2020 at 10:18, Nicholas Piggin <npiggin@gmail.com> wrote:
>>
>> For some reason my environment requires this.
>>
>> Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
> 
> 
> 
>> ---
>>  README.md | 6 ++++++
>>  1 file changed, 6 insertions(+)
>>
>> diff --git a/README.md b/README.md
>> index abc2088..7892a8d 100644
>> --- a/README.md
>> +++ b/README.md
>> @@ -25,6 +25,12 @@ make
>>  rsync pdbg root@bmc:/usr/local/bin
>>  ```
>>
>> +Depending on your cross compile environment, you may get a message like
>> +`pdbg: No such file or directory` when execting the binary on the BMC,
>> +which may be fixable by correcting loader location:
>> +
>> +`patchelf --set-interpreter /lib/ld-linux-armhf.so.3 pdbg`
> 
> Interesting. What toolchain do you use?

Debian binutils gcc-arm-linux-gnueabi (not gnueabihf, because that's 
what's in README).

> What does patchelf --print-interpreter tell you before you patch it?

/lib/ld-linux.so.3

Hmm, it's building soft float

  Flags:                             0x5000200, Version5 EABI, soft-float ABI

Loader might not have anything hf specific so it might work okay, but I
guess it's not really the right thing to do. I'll submit another patch
for the build instructions then.

> 
> Regardless:
> 
> Reviewed-by: Joel Stanley <joel@jms.id.au>
> 
>> +
>>  ## Usage
>>
>>  Several backends are supported depending on which system you are using and are
>> --
>> 2.23.0
>>
>> --
>> Pdbg mailing list
>> Pdbg@lists.ozlabs.org
>> https://lists.ozlabs.org/listinfo/pdbg
>
Nicholas Piggin Jan. 13, 2021, 5:50 a.m. UTC | #3
Excerpts from Nicholas Piggin's message of January 13, 2021 3:06 pm:
> Excerpts from Joel Stanley's message of January 11, 2021 2:58 pm:
>> On Mon, 21 Dec 2020 at 10:18, Nicholas Piggin <npiggin@gmail.com> wrote:
>>>
>>> For some reason my environment requires this.
>>>
>>> Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
>> 
>> 
>> 
>>> ---
>>>  README.md | 6 ++++++
>>>  1 file changed, 6 insertions(+)
>>>
>>> diff --git a/README.md b/README.md
>>> index abc2088..7892a8d 100644
>>> --- a/README.md
>>> +++ b/README.md
>>> @@ -25,6 +25,12 @@ make
>>>  rsync pdbg root@bmc:/usr/local/bin
>>>  ```
>>>
>>> +Depending on your cross compile environment, you may get a message like
>>> +`pdbg: No such file or directory` when execting the binary on the BMC,
>>> +which may be fixable by correcting loader location:
>>> +
>>> +`patchelf --set-interpreter /lib/ld-linux-armhf.so.3 pdbg`
>> 
>> Interesting. What toolchain do you use?
> 
> Debian binutils gcc-arm-linux-gnueabi (not gnueabihf, because that's 
> what's in README).
> 
>> What does patchelf --print-interpreter tell you before you patch it?
> 
> /lib/ld-linux.so.3
> 
> Hmm, it's building soft float
> 
>   Flags:                             0x5000200, Version5 EABI, soft-float ABI
> 
> Loader might not have anything hf specific so it might work okay, but I
> guess it's not really the right thing to do. I'll submit another patch
> for the build instructions then.

Ohhh, it changed for the 2600 build. I'd thought something must have 
changed on my end. Patch sent.

Thanks,
Nick
diff mbox series

Patch

diff --git a/README.md b/README.md
index abc2088..7892a8d 100644
--- a/README.md
+++ b/README.md
@@ -25,6 +25,12 @@  make
 rsync pdbg root@bmc:/usr/local/bin
 ```
 
+Depending on your cross compile environment, you may get a message like
+`pdbg: No such file or directory` when execting the binary on the BMC,
+which may be fixable by correcting loader location:
+
+`patchelf --set-interpreter /lib/ld-linux-armhf.so.3 pdbg`
+
 ## Usage
 
 Several backends are supported depending on which system you are using and are