conda-forge / code-server-feedstock

A conda-smithy repository for code-server.
BSD 3-Clause "New" or "Revised" License
1 stars 11 forks source link

Working on the `GLIBC_2.25 not found` build issue #95

Closed avsthiago closed 6 months ago

avsthiago commented 12 months ago

Checklist

conda-forge-webservices[bot] commented 12 months ago

Hi! This is the friendly automated conda-forge-linting service.

I just wanted to let you know that I linted all conda-recipes in your PR (recipe) and found it was in an excellent condition.

avsthiago commented 12 months ago

Hi @xhochy, @janjagusch, and @jtilly,

I'm addressing a build issue in our conda feedstock (link to build issue) due to CentOS 7's outdated GLIBC conflicting with Node 18 requirements.

Since code-server doesn't support cos7 anymore, would building the package on a different Linux distribution with a newer GLIBC be a feasible workaround in the conda-forge context? Any guidance or alternative suggestions would be greatly appreciated

+ code-server --help
node:internal/modules/cjs/loader:1340
  return process.dlopen(module, path.toNamespacedPath(filename));
                 ^

Error: /lib64/libc.so.6: version `GLIBC_2.25' not found (required by /home/conda/feedstock_root/build_artifacts/code-server_1701001419227/_h_env_placehold/share/code-server/node_modules/argon2/lib/binding/napi-v3/argon2.node)
    at Module._extensions..node (node:internal/modules/cjs/loader:1340:18)
    at Module.load (node:internal/modules/cjs/loader:1119:32)
    at Module._load (node:internal/modules/cjs/loader:960:12)
    at Module.require (node:internal/modules/cjs/loader:1143:19)
    at require (node:internal/modules/cjs/helpers:119:18)
    at Object.<anonymous> (/home/conda/feedstock_root/build_artifacts/code-server_1701001419227/_h_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold/share/code-server/node_modules/argon2/argon2.js:9:25)
    at Module._compile (node:internal/modules/cjs/loader:1256:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1310:10)
    at Module.load (node:internal/modules/cjs/loader:1119:32)
    at Module._load (node:internal/modules/cjs/loader:960:12) {
  code: 'ERR_DLOPEN_FAILED'
xhochy commented 12 months ago

At the moment, it's not possible.

avsthiago commented 12 months ago

@xhochy, what do you think about this solution? I kept the code-server --help test for the osx and aarch64 and reduced the test to only which code-server when building the linux64 version.

My goal here is to unblock the osx and aarch64 builds. I also expect the package to only fail on Linux only if the system doesn't have GLIBC >= 2.25.

avsthiago commented 7 months ago

@xhochy, could you please review this PR again when you have time?

conda-forge-webservices[bot] commented 7 months ago

Hi! This is the friendly automated conda-forge-linting service.

I wanted to let you know that I linted all conda-recipes in your PR (recipe) and found some lint.

Here's what I've got...

For recipe:

conda-forge-webservices[bot] commented 7 months ago

Hi! This is the friendly automated conda-forge-linting service.

I just wanted to let you know that I linted all conda-recipes in your PR (recipe) and found it was in an excellent condition.

xhochy commented 7 months ago

@conda-forge-admin please rerender

avsthiago commented 7 months ago

@conda-forge-admin please rerender

ehfd commented 6 months ago

@avsthiago Unfortunately, c_stdlib as sysroot was probably not it. After rerender, that was automatically fixed and logs changed to something else.

Perhaps the build container to Alma (within conda_build_config.yaml)?

avsthiago commented 6 months ago

Yeah, @ehfd, that didn't work. I'll give it another try with the Alma image.

avsthiago commented 6 months ago

@conda-forge-admin please rerender

ehfd commented 6 months ago

Looks like the original solutions were right, except needing to rerender after putting it into conda_build_config.yaml.

avsthiago commented 6 months ago

@xhochy I tried to fix the build by only changing the c_stdlib_version, but that didn't work. The only fix I found so far was to change the docker_image.

Do you see any other option?

ehfd commented 6 months ago

I guess changing docker_image for conda_build_config.yaml and rerendering is OK, if not changing the .scripts folder?

xhochy commented 6 months ago

c_stdlib_version is the way to go. What was the error?

Otherwise the version constraints will not be set correctly.

ehfd commented 6 months ago

@xhochy

https://dev.azure.com/conda-forge/feedstock-builds/_build/results?buildId=917329&view=logs&j=656edd35-690f-5c53-9ba3-09c10d0bea97&t=986b1512-c876-5f92-0d81-ba851554a0a3

https://dev.azure.com/conda-forge/feedstock-builds/_build/results?buildId=917329&view=logs&jobId=6494c7a6-a019-59a3-6f3d-9bab8ca96717&j=6494c7a6-a019-59a3-6f3d-9bab8ca96717&t=18c91bca-a25a-5f89-34d4-93bbec4021bc

Compare the two. linux_64 still shows Error: /lib64/libc.so.6: versionGLIBC_2.25' not found` for testing. Build is successful, but cannot test.

ehfd commented 6 months ago

@avsthiago @xhochy Perhaps require stdlib('c') with 2.28 constraint in the test environment as well? It can be that the test environment is capturing the container (outside) glibc environment. Otherwise, when sysroot is 2.28 the build container must change automatically to Alma 8.

xhochy commented 6 months ago

We probably need the docker image and c_stdlib_version at the same time. In future, setting the docker image should be obsolete, but until the new sysroot is fully rolled out, we will need to add that to conda_build_config.yaml, too.

ehfd commented 6 months ago

@xhochy Then everything is as it is now.

https://github.com/conda-forge/code-server-feedstock/pull/95/commits/24af81eceedc84ecd78f704a39f0f8de23c4f875