Skip to content

Commit

Permalink
Arm build: More simplification of the script
Browse files Browse the repository at this point in the history
  • Loading branch information
Obijuan committed Mar 19, 2022
1 parent 6536321 commit 9059ff3
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 31 deletions.
20 changes: 9 additions & 11 deletions Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -297,6 +297,9 @@ module.exports = function (grunt) {

//-- NW TARBALL with path
const NW_TARBALL = NW_PATH + "/" + NW_NAME_TAR_GZ;

//-- SRC path where the NW files (for ARM) are locted
const NW_SRC_PATH = DIST_TMP_ARM + "/" + NWJS_ARM_NAME;

//-------------------------------------------------------------------------
//-- EXEC TASK:
Expand Down Expand Up @@ -767,10 +770,7 @@ module.exports = function (grunt) {
//-- More info: https://github.com/sindresorhus/grunt-shell#readme
shell: {
test: {
command: [

//-- Just a test
'ls --color',
command: [

//-- Create a temp DIR
`mkdir -p ${DIST_TMP_ARM}`,
Expand All @@ -779,15 +779,13 @@ module.exports = function (grunt) {
`tar xzf ${NWJS_ARM_PACKAGE} -C ${DIST_TMP_ARM}`,

//-- Uncompress the NW tarball (inside the NW-dist)
`tar xzf ${NW_TARBALL} -C ${DIST_TMP_ARM}`
`tar xzf ${NW_TARBALL} -C ${DIST_TMP_ARM}`,

].join(' && ')
//-- Copy the ARM NW files to the Icestudio dist folder
`cp -R ${NW_SRC_PATH}/* ${DIST_ICESTUDIO_AARCH64}/`

//
// #-- Unzip the NW tarball into the cache folder
// echo "${BLUE}unzipping the NW tarball: $NW_NAME_TAR_GZ${NC}"
// tar xzf "$NW_TARBALL" -C $DIST_TMP
//
].join(' && ')

},

},
Expand Down
20 changes: 0 additions & 20 deletions scripts/mergeAarch64.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,30 +6,10 @@ BLUE="\033[1;34m"
RED="\033[1;31m"
GREEN="\033[1;32m"

#-- The NWjs binary for ARM is a tarball (tar.gz) that should be
#-- uncompressed and copied to the icestudio/aarch64 (DESTINATION) folder

echo "* ARGUMENTS: $1"

#-- The NW tarball name (not extension) is received as an argument
NW_NAME=$1

#-- Folder where to uncompress the NW dist tarball
DIST_TMP="dist/tmp/nwjsAarch64"

#-- Folder where the final NW binary files should be copied
DESTINATION="dist/icestudio/aarch64"

#-- Src folder where the NW files have been unzipped
NW_SRC_PATH="$DIST_TMP/$NW_NAME"

#-- Copy the NW files to the DESTINATION folder

echo "${GREEN}Copying NW files...${NC}"
echo "From: $NW_SRC_PATH/*"
echo "To: $DESTINATION/"
cp -R $NW_SRC_PATH/* $DESTINATION/

#-- The icestudio executable file is called nw
#-- rename it to icestudio
mv $DESTINATION/nw $DESTINATION/icestudio
Expand Down

0 comments on commit 9059ff3

Please sign in to comment.