mirror of
https://github.com/Foundry376/Mailspring.git
synced 2024-11-11 10:12:00 +08:00
23 lines
469 B
Bash
Executable file
23 lines
469 B
Bash
Executable file
#!/bin/bash
|
|
|
|
set -e
|
|
|
|
SPEC_FILE="$1"
|
|
DESKTOP_FILE="$2"
|
|
BUILD_DIRECTORY="$3"
|
|
|
|
RPM_BUILD_ROOT=~/rpmbuild
|
|
ARCH=`uname -m`
|
|
|
|
rpmdev-setuptree
|
|
|
|
cp -r $BUILD_DIRECTORY/Nylas/* $RPM_BUILD_ROOT/BUILD
|
|
cp $SPEC_FILE $RPM_BUILD_ROOT/SPECS
|
|
cp ./N1.sh $RPM_BUILD_ROOT/BUILD
|
|
cp $RPM_BUILD_ROOT/BUILD/N1.sh $RPM_BUILD_ROOT/BUILD/nylas
|
|
cp $DESKTOP_FILE $RPM_BUILD_ROOT/BUILD
|
|
|
|
rpmbuild -ba $SPEC_FILE
|
|
cp $RPM_BUILD_ROOT/RPMS/$ARCH/nylas-*.rpm $BUILD_DIRECTORY/rpm
|
|
|
|
rm -rf $RPM_BUILD_ROOT
|