Skip to content

Node support for apt #53856

Answered by mateuspaulino
TracerDS asked this question in General
Jul 15, 2024 · 4 comments · 8 replies
Discussion options

You must be logged in to vote

Hi @TracerDS, it is possible but it will take a few steps:

sudo apt update
sudo apt install -y build-essential fakeroot dpkg-dev

Download Node.js Source:
Get the source code for the version of Node.js you want to package.

VERSION=v16.16.0  # Replace with your desired version
wget https://nodejs.org/dist/$VERSION/node-$VERSION.tar.gz
tar -xzf node-$VERSION.tar.gz
cd node-$VERSION

Build Node.js from source.

./configure
make -j$(nproc)

Install Node.js into a directory which will be used to create the .deb package.

mkdir -p ../nodejs-staging/usr/local
make install DESTDIR=$(pwd)/../nodejs-staging/usr/local

Create the necessary files for the .deb package.

    mkdir -p ../nodejs-staging/DEB…

Replies: 4 comments 8 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
4 replies
@TracerDS
Comment options

@mhdawson
Comment options

@TracerDS
Comment options

@mhdawson
Comment options

Comment options

You must be logged in to vote
4 replies
@TracerDS
Comment options

@ovflowd
Comment options

@TracerDS
Comment options

@ovflowd
Comment options

Answer selected by RedYetiDev
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
6 participants