Skip to content
This repository has been archived by the owner on Oct 5, 2022. It is now read-only.

get rid of native dependencies (electron, electron-store, native-keymaps) #163

Closed
jgbradley1 opened this issue Apr 11, 2019 · 1 comment · Fixed by #165
Closed

get rid of native dependencies (electron, electron-store, native-keymaps) #163

jgbradley1 opened this issue Apr 11, 2019 · 1 comment · Fixed by #165
Assignees

Comments

@jgbradley1
Copy link
Contributor

jgbradley1 commented Apr 11, 2019

I've been trying to build the "next" version of several of the docker images in this repo. I was constantly getting build errors from node-gyp regarding the native-keymap module

> [email protected] install /home/theia/node_modules/native-keymap
> node-gyp rebuild

Package x11 was not found in the pkg-config search path.
Perhaps you should add the directory containing `x11.pc'
to the PKG_CONFIG_PATH environment variable
Package 'x11', required by 'virtual:world', not found
Package 'xkbfile', required by 'virtual:world', not found
gyp: Call to 'pkg-config x11 xkbfile --libs' returned exit status 1 while in binding.gyp. while trying to load binding.gyp
gyp ERR! configure error
gyp ERR! stack Error: `gyp` failed with exit code: 1
gyp ERR! stack     at ChildProcess.onCpExit (/usr/local/lib/node_modules/npm/node_modules/node-gyp/lib/configure.js:345:16)
gyp ERR! stack     at emitTwo (events.js:126:13)
gyp ERR! stack     at ChildProcess.emit (events.js:214:7)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:198:12)
gyp ERR! System Linux 4.9.125-linuxkit
gyp ERR! command "/usr/local/bin/node" "/usr/local/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /home/theia/node_modules/native-keymap
gyp ERR! node -v v8.15.1
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2019-04-11T04_01_23_796Z-debug.log

Solution
The solution already exists in the gitpod Dockerfile. Corresponding packages for libx11-dev and libxkbfile-dev must be added to each OS used under theia-apps.

Alpine: apk add libx11-dev libxkbfile-dev
Ubuntu: apt-get install -y libx11-dev libxkbfile-dev
CenttOS: yum install -y libX11-devel libxkbfile-devel

@akosyakov
Copy link
Member

This dep is useless for docker images. Only can work in Electron.

@akosyakov akosyakov self-assigned this Apr 11, 2019
@akosyakov akosyakov changed the title Add dependencies for native-keymap get rid of native dependencies (electron, electron-store, native-keymaps) Apr 11, 2019
akosyakov added a commit that referenced this issue Apr 11, 2019
Signed-off-by: Anton Kosyakov <[email protected]>
akosyakov added a commit that referenced this issue Apr 11, 2019
Signed-off-by: Anton Kosyakov <[email protected]>
dwjbosman pushed a commit to dwjbosman/theia-apps that referenced this issue Jul 24, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants