2015-10-22 13:49:38 +02:00
|
|
|
DESTDIR=./
|
|
|
|
INSTALL_LOCATION=$(DESTDIR)/opt/pitaya
|
|
|
|
ELECTRON_ARCH=x64
|
2015-10-17 11:34:37 +02:00
|
|
|
|
2015-10-22 13:49:38 +02:00
|
|
|
ifeq ($(DEB_TARGET_ARCH), i386)
|
|
|
|
ELECTRON_ARCH=ia32
|
|
|
|
endif
|
2015-10-17 11:34:37 +02:00
|
|
|
|
2015-10-22 13:49:38 +02:00
|
|
|
all: build
|
2015-10-17 11:34:37 +02:00
|
|
|
|
2015-10-22 13:49:38 +02:00
|
|
|
build:
|
|
|
|
apt-get install --yes --no-install-recommends curl ca-certificates
|
|
|
|
curl --silent --location https://deb.nodesource.com/setup_0.12 | bash -
|
|
|
|
apt-get install --yes nodejs
|
|
|
|
npm install --ignore-scripts
|
2015-10-17 11:34:37 +02:00
|
|
|
npm run clean
|
2015-10-22 13:49:38 +02:00
|
|
|
npm run compile
|
|
|
|
npm run package -- --arch=$(ELECTRON_ARCH)
|
2015-10-17 11:34:37 +02:00
|
|
|
|
2015-10-22 13:49:38 +02:00
|
|
|
install:
|
|
|
|
mkdir -p $(INSTALL_LOCATION)
|
|
|
|
cp -r build/pitaya-linux-$(ELECTRON_ARCH)/* $(INSTALL_LOCATION)/
|