A small tool to view real-world ActivityPub objects as JSON! Enter a URL
or username from Mastodon or a similar service below, and we'll send a
request with
the right
Accept
header
to the server to view the underlying object.
{
"@context": [
"https://join-lemmy.org/context.json",
"https://www.w3.org/ns/activitystreams"
],
"type": "Page",
"id": "https://leminal.space/post/19386723",
"attributedTo": "https://leminal.space/u/hallettj",
"to": [
"https://programming.dev/c/nix",
"https://www.w3.org/ns/activitystreams#Public"
],
"name": "Patch interpreter path in embedded binary?",
"cc": [],
"content": "<p>I’m trying to write a Nix package for a closed-source, precompiled binary with an unusual twist. The <a href=\"https://graphql-engine-cdn.hasura.io/ddn/cli/v4/v2.29.0/cli-ddn-linux-amd64\" rel=\"nofollow\">binary</a> is statically-linked, but it contains an embedded binary that is dynamically-linked. Is there some way I can use patchelf or another tool to path the interpreter path in the embedded binary?</p>\n<p>The embedded binary does not have any runtime library dependencies, but it does need an interpreter which it expects at the hard-coded path <code>/lib64/ld-linux-x86-64.so.2</code>. It is embedded using the golang “embed” library.</p>\n<p>I have a <a href=\"https://github.com/hasura/ddn-cli-nix/pull/5\" rel=\"nofollow\">workaround</a> that wraps the binary using <code>buildFHSEnv</code>. That works, but the resulting closure is about 300 MB bigger than it needs to be.</p>\n",
"mediaType": "text/html",
"source": {
"content": "I'm trying to write a Nix package for a closed-source, precompiled binary with an unusual twist. The [binary](https://graphql-engine-cdn.hasura.io/ddn/cli/v4/v2.29.0/cli-ddn-linux-amd64) is statically-linked, but it contains an embedded binary that is dynamically-linked. Is there some way I can use patchelf or another tool to path the interpreter path in the embedded binary?\n\nThe embedded binary does not have any runtime library dependencies, but it does need an interpreter which it expects at the hard-coded path `/lib64/ld-linux-x86-64.so.2`. It is embedded using the golang \"embed\" library.\n\nI have a [workaround](https://github.com/hasura/ddn-cli-nix/pull/5) that wraps the binary using `buildFHSEnv`. That works, but the resulting closure is about 300 MB bigger than it needs to be.",
"mediaType": "text/markdown"
},
"attachment": [],
"sensitive": false,
"published": "2025-05-07T02:25:49.696439Z",
"language": {
"identifier": "en",
"name": "English"
},
"audience": "https://programming.dev/c/nix",
"tag": [
{
"href": "https://leminal.space/post/19386723",
"name": "#nix",
"type": "Hashtag"
}
]
}