Home
Support Forums

`GLIBC_2.25' not found

Hi, I’m trying to get a purescript project to build (it builds fine locally), and I think there’s a missing dependency? I can’t figure out how to fix it. I found a similar post that suggested prepending npm rebuild && to the build command, but that didn’t work. I’m pretty sure glibc should be installed in Xenial.

2:47:33 AM: Build ready to start

2:47:35 AM: build-image version: be42e453d6c8f171cc2f654acc29c0a8b60e6d93

2:47:35 AM: build-image tag: v3.7.1

2:47:35 AM: buildbot version: b47b671c7e5601877c51968241eb899bf590a815

2:47:35 AM: Fetching cached dependencies

2:47:35 AM: Failed to fetch cache, continuing with build

2:47:35 AM: Starting to prepare the repo for build

2:47:35 AM: No cached dependencies found. Cloning fresh repo

2:47:35 AM: git clone https://github.com/strangepoop/tvimstick

2:47:36 AM: Preparing Git Reference refs/heads/master

2:47:37 AM: Parsing package.json dependencies

2:47:38 AM: Starting build script

2:47:38 AM: Installing dependencies

2:47:38 AM: Python version set to 2.7

2:47:40 AM: v12.18.0 is already installed.

2:47:41 AM: Now using node v12.18.0 (npm v6.14.4)

2:47:41 AM: Started restoring cached build plugins

2:47:41 AM: Finished restoring cached build plugins

2:47:41 AM: Attempting ruby version 2.7.1, read from environment

2:47:43 AM: Using ruby version 2.7.1

2:47:43 AM: Using PHP version 5.6

2:47:43 AM: Started restoring cached node modules

2:47:43 AM: Finished restoring cached node modules

2:47:43 AM: Installing NPM modules using NPM version 6.14.4

2:47:46 AM: npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142

2:47:47 AM: npm WARN deprecated har-validator@5.1.5: this library is no longer supported

2:47:55 AM: npm WARN deprecated request-promise-native@1.0.9: request-promise-native has been deprecated because it extends the now deprecated request package, see https://github.com/request/request/issues/3142

2:47:57 AM: npm WARN deprecated urix@0.1.0: Please see https://github.com/lydell/urix#deprecated

2:47:57 AM: npm WARN deprecated resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated

2:48:16 AM: > @parcel/source-map@2.0.0-alpha.4.21 install /opt/build/repo/node_modules/@parcel/source-map

2:48:16 AM: > node-gyp-build

2:48:16 AM: > @parcel/watcher@2.0.0-alpha.10 install /opt/build/repo/node_modules/@parcel/watcher

2:48:16 AM: > node-gyp-build

2:48:17 AM: > core-js@3.11.0 postinstall /opt/build/repo/node_modules/core-js

2:48:17 AM: > node -e "try{require('./postinstall')}catch(e){}"

2:48:17 AM: > ejs@2.7.4 postinstall /opt/build/repo/node_modules/ejs

2:48:17 AM: > node ./postinstall.js

2:48:17 AM: > purescript@0.14.1 postinstall /opt/build/repo/node_modules/purescript

2:48:17 AM: > install-purescript --purs-ver=0.14.1

2:48:18 AM: [ SUCCESS ] Check if a prebuilt 0.14.1 binary is provided for linux (377ms)

2:48:19 AM: [ SUCCESS ] Download the prebuilt PureScript binary (919ms)

2:48:19 AM: [ FAILURE ] Verify the prebuilt binary works correctly

2:48:19 AM: Error: Command failed: /opt/build/repo/node_modules/purescript/purs.bin --version

2:48:19 AM: /opt/build/repo/node_modules/purescript/purs.bin: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.25' not found (required by /opt/build/repo/node_modules/purescript/purs.bin)
/opt/build/repo/node_modules/purescript/purs.bin: /lib/x86_64-linux-gnu/libm.so.6: version `GLIBC_2.27' not found (required by /opt/build/repo/node_modules/purescript/purs.bin)

2:48:19 AM: at ChildProcess.exithandler (child_process.js:303:12)

2:48:19 AM: at ChildProcess.emit (events.js:315:20)

2:48:19 AM: at maybeClose (internal/child_process.js:1021:16)

2:48:19 AM: at Socket.<anonymous> (internal/child_process.js:443:11)

2:48:19 AM: at Socket.emit (events.js:315:20)

2:48:19 AM: at Pipe.<anonymous> (net.js:674:12)

2:48:19 AM: ↓ Fallback: building from source

2:48:19 AM: [ FAILURE ] Check if 'stack' command is available

2:48:19 AM: Error: Command failed with exit code 2 (ENOENT): stack --allow-different-user --numeric-version

2:48:19 AM: spawn stack ENOENT

2:48:19 AM: at Process.ChildProcess._handle.onexit (internal/child_process.js:267:19)

2:48:19 AM: at onErrorNT (internal/child_process.js:469:16)

2:48:19 AM: at processTicksAndRejections (internal/process/task_queues.js:84:21)

2:48:20 AM: npm WARN notsup Unsupported engine for @parcel/source-map@2.0.0-alpha.4.21: wanted: {"node":"^12.18.3 || >=14"} (current: {"node":"12.18.0","npm":"6.14.4"})

2:48:20 AM: npm WARN notsup Not compatible with your version of node/npm: @parcel/source-map@2.0.0-alpha.4.21

2:48:20 AM: npm ERR! code ELIFECYCLE

2:48:20 AM: npm ERR! errno 1

2:48:20 AM: npm ERR! purescript@0.14.1 postinstall: `install-purescript --purs-ver=0.14.1`

2:48:20 AM: npm ERR! Exit status 1

2:48:20 AM: npm ERR!

2:48:20 AM: npm ERR! Failed at the purescript@0.14.1 postinstall script.

2:48:20 AM: npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

2:48:20 AM: npm ERR! A complete log of this run can be found in:

2:48:20 AM: npm ERR! /opt/buildhome/.npm/_logs/2021-04-22T21_18_20_221Z-debug.log

2:48:20 AM: Error during NPM install

2:48:20 AM: Build was terminated: Build script returned non-zero exit code: 1

2:48:20 AM: Creating deploy upload records

2:48:20 AM: Failing build: Failed to build site

2:48:20 AM: Failed during stage 'building site': Build script returned non-zero exit code: 1

2:48:20 AM: Finished processing build request in 45.276140447s

My build command is just

npm rebuild && npm run build-prod

and package.json is:

{
  "private": true,
  "devDependencies": {
    "parcel": "2.0.0-beta.2",
    "purescript": "^0.14.0",
    "spago": "^0.19.1"
  },
  "scripts": {
    "build": "spago build",
    "test": "spago test",
    "serve": "parcel dev/index.html --open",
    "build-prod": "mkdir -p prod && cp dev/index.html prod/ && rm -rf dist && spago bundle-app --to prod/index.js && parcel build prod/index.html"
  }
}

Any help is appreciated!

hey there! sorry to be a bit slow to reply.

You can see all the software that is currently installed on/with the xenial build image here:

looks like the thing you need isn’t on that list. I don’t know much about that package, but what happens if you explicitly install it? :thinking:

Thanks for responding, Perry.

I pored over the deploy documentation but I couldn’t find out whether there was a way of doing this. I tried prepending apt install libc6 && to the build command, but that doesn’t seem to change anything; even the deploy log is exactly the same.

Is there a more idiomatic/functinal way of installing a package?

EDIT: In fact, this seems to say that you can’t explicitly install, so I’m wondering whether you meant something else when you suggested “explicitly install it”?

This “package” btw is the GNU C library. I’d be surprised if it wasn’t there, it’s probably just slightly outdated?

hi there @buildmybuild , just letting you know we haven’t forgotten about you. I am still trying to get some :eyes: on this.

I am also interested in this.

So far, I’m building Purescript locally, then bundling the resulting JavaScript in my Netlify functions directory. I’d like for Netlify to build the Purescript for me. Here is my most recent deploy log:

7:35:26 PM: Build ready to start
7:35:28 PM: build-image version: 2cee85eb7f808bf3b6e87378c5307f9411f0a332
7:35:28 PM: build-image tag: v3.8.0
7:35:28 PM: buildbot version: 487f6d01b44481b4d57253f3d6071f198697110f
7:35:28 PM: Fetching cached dependencies
7:35:28 PM: Starting to download cache of 106.5MB
7:35:28 PM: Finished downloading cache in 519.492175ms
7:35:28 PM: Starting to extract cache
7:35:32 PM: Finished extracting cache in 3.268370771s
7:35:32 PM: Finished fetching cache in 3.835654458s
7:35:32 PM: Starting to prepare the repo for build
7:35:32 PM: Preparing Git Reference refs/heads/publish
7:35:33 PM: Parsing package.json dependencies
7:35:34 PM: Different build command detected, going to use the one specified in the Netlify configuration file: 'npm run publish-purescript' versus '' in the Netlify UI
7:35:34 PM: Starting build script
7:35:34 PM: Installing dependencies
7:35:34 PM: Python version set to 2.7
7:35:35 PM: Started restoring cached node version
7:35:38 PM: Finished restoring cached node version
7:35:38 PM: Attempting node version '16.4.2' from .node-version
7:35:38 PM: v16.4.2 is already installed.
7:35:39 PM: Now using node v16.4.2 (npm v7.18.1)
7:35:39 PM: Started restoring cached build plugins
7:35:39 PM: Finished restoring cached build plugins
7:35:39 PM: Attempting ruby version 2.7.2, read from environment
7:35:41 PM: Using ruby version 2.7.2
7:35:41 PM: Using PHP version 5.6
7:35:41 PM: Started restoring cached node modules
7:35:41 PM: Finished restoring cached node modules
7:35:42 PM: Installing NPM modules using NPM version 7.18.1
7:35:44 PM: npm WARN deprecated har-validator@5.1.5: this library is no longer supported
7:35:44 PM: npm WARN deprecated uuid@3.4.0: Please upgrade  to version 7 or higher.  Older versions may use Math.random() in certain circumstances, which is known to be problematic.  See https://v8.dev/blog/math-random for details.
7:35:44 PM: npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
7:35:53 PM: npm ERR! code 1
7:35:53 PM: Creating deploy upload records
7:35:53 PM: npm ERR! path /opt/build/repo/node_modules/purescript
7:35:53 PM: npm ERR! command failed
7:35:53 PM: npm ERR! command sh -c install-purescript --purs-ver=0.14.3
7:35:53 PM: npm ERR! [ SUCCESS ] Check if a prebuilt 0.14.3 binary is provided for linux (428ms)
7:35:53 PM: npm ERR! [ SUCCESS ] Download the prebuilt PureScript binary (823ms)
7:35:53 PM: npm ERR! [ FAILURE ] Verify the prebuilt binary works correctly
7:35:53 PM: npm ERR! Error: Command failed: /opt/build/repo/node_modules/purescript/purs.bin --version
7:35:53 PM: npm ERR! /opt/build/repo/node_modules/purescript/purs.bin: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.25' not found (required by /opt/build/repo/node_modules/purescript/purs.bin)npm ERR! /opt/build/repo/node_modules/purescript/purs.bin: /lib/x86_64-linux-gnu/libm.so.6: version `GLIBC_2.27' not found (required by /opt/build/repo/node_modules/purescript/purs.bin)npm ERR!
7:35:53 PM: npm ERR!     at ChildProcess.exithandler (node:child_process:397:12)
7:35:53 PM: npm ERR!     at ChildProcess.emit (node:events:394:28)
7:35:53 PM: npm ERR!     at maybeClose (node:internal/child_process:1067:16)
7:35:53 PM: npm ERR!     at Socket.<anonymous> (node:internal/child_process:453:11)
7:35:53 PM: npm ERR!     at Socket.emit (node:events:394:28)
7:35:53 PM: npm ERR!     at Pipe.<anonymous> (node:net:662:12)
7:35:53 PM: npm ERR!
7:35:53 PM: npm ERR! ↓ Fallback: building from source
7:35:53 PM: npm ERR!
7:35:53 PM: npm ERR! [ FAILURE ] Check if 'stack' command is available
7:35:53 PM: npm ERR! Error: Command failed with exit code 2 (ENOENT): stack --allow-different-user --numeric-version
7:35:53 PM: npm ERR! spawn stack ENOENT
7:35:53 PM: npm ERR!     at Process.ChildProcess._handle.onexit (node:internal/child_process:282:19)
7:35:53 PM: npm ERR!     at onErrorNT (node:internal/child_process:480:16)
7:35:53 PM: npm ERR!     at processTicksAndRejections (node:internal/process/task_queues:83:21)
7:35:53 PM: npm ERR! A complete log of this run can be found in:
7:35:54 PM: Failed during stage 'building site': Build script returned non-zero exit code: 1
7:35:53 PM: npm ERR!     /opt/buildhome/.npm/_logs/2021-07-08T22_35_53_701Z-debug.log
7:35:53 PM: Error during NPM install
7:35:53 PM: Build was terminated: Build script returned non-zero exit code: 1
7:35:54 PM: Failing build: Failed to build site
7:35:54 PM: Finished processing build request in 26.108517438s

It’s still a missing glibc, but now the version has bumped to 2.27. :slight_smile:

Any help would be appreciated.

Hey there, thanks for reaching out!

The glibc component will be inherent within our build environment, given it’s a Linux distro (hence why it doesn’t appear in our ‘included software’ list).

You could try running ldd --version as your build command, to see what version we run! Or, check out this link. Our Xenial build image runs glibc ver. 2.23.

However, our latest build image, Focal, supports 2.31. You may wish to try upgrading to this image (see How do I update my build image?)!

1 Like

I can confirm with gratitude that I could build on Netlify using Purescript 0.14.3 on the Focal image.

Thank you.

1 Like