first version of shell scripts
This commit is contained in:
parent
816a2fd81a
commit
002b02bd43
4 changed files with 19 additions and 39 deletions
|
|
@ -1,4 +1,4 @@
|
|||
.PHONY : help fetch all clean build dir bootstrap winsdk setup-debian setup-fedora veryclean docker-build docker-run docker-clean artifacts
|
||||
.PHONY : help fetch all clean build dir bootstrap winsdk setup-debian setup-fedora veryclean docker-build docker-run docker-clean artifacts pre-build post-package
|
||||
|
||||
version:=$(shell cat version)
|
||||
release:=$(shell cat release)
|
||||
|
|
@ -36,7 +36,7 @@ help :
|
|||
@echo " docker-clean - Remove" $(docker_image_name) "docker image."
|
||||
@echo ""
|
||||
|
||||
all : build package
|
||||
all : dir pre-build build package post-package artifacts
|
||||
|
||||
fetch :
|
||||
wget -q -O version "https://gitlab.com/librewolf-community/browser/source/-/raw/main/version"
|
||||
|
|
@ -54,23 +54,36 @@ veryclean : clean
|
|||
rm -f "librewolf-$$(cat version)-$$(cat source_release).source.tar.gz" "librewolf-$$(cat version)-$$(cat source_release).source.tar.gz.sha256sum"
|
||||
rm -f version source_release
|
||||
|
||||
pre-build :
|
||||
./assets/pre_build_patches_mozconfig.sh
|
||||
|
||||
build : dir
|
||||
(cd librewolf-$(full_version) && ./mach build)
|
||||
|
||||
|
||||
package : dir
|
||||
(cd librewolf-$(full_version) && ./mach package)
|
||||
# ( cd librewolf-$(full_version) && echo 'Packaging... (output hidden)' && \
|
||||
# cat browser/locales/shipped-locales | xargs ./mach package-multi-locale --locales >/dev/null )
|
||||
# (cd librewolf-$(full_version) && ./mach package)
|
||||
( cd librewolf-$(full_version) && echo 'Packaging... (output hidden)' && \
|
||||
cat browser/locales/shipped-locales | xargs ./mach package-multi-locale --locales >/dev/null )
|
||||
|
||||
post-package :
|
||||
cp -v librewolf-$(full_version)/obj-x86_64-pc-linux-gnu/dist/librewolf-$(full_version).en-US.linux-x86_64.tar.bz2 .
|
||||
./assets/post_package_distini_etc.sh
|
||||
|
||||
artifacts :
|
||||
${MAKE} -f assets/artifacts.mk artifacts
|
||||
|
||||
|
||||
|
||||
|
||||
dir : librewolf-$(full_version)
|
||||
|
||||
|
||||
librewolf-$(full_version) : librewolf-$(full_version).source.tar.gz
|
||||
rm -rf $@
|
||||
tar xf $<
|
||||
touch $@
|
||||
# this is the place to apply patches and create a custom mozconfig
|
||||
cp -v assets/mozconfig.$(arch) librewolf-$(full_version)/mozconfig
|
||||
# (cd librewolf-$(full_version) && patch -p1 -i ../assets/tryfix-reslink-fail.patch)
|
||||
# (cd librewolf-$(full_version) && patch -p1 -i ../assets/fix-l10n-package-cmd.patch)
|
||||
|
|
|
|||
|
|
@ -11,37 +11,4 @@ setupname=librewolf-$(full_version).en-US.win64-setup.exe
|
|||
zipname=librewolf-$(full_version).en-US.win64-portable.zip
|
||||
|
||||
artifacts :
|
||||
|
||||
# this section makes the work/librewolf folder
|
||||
( rm -rf work && mkdir work )
|
||||
( cd work && unzip -q ../$(incoming_artifact) )
|
||||
mv work/firefox work/librewolf
|
||||
mv work/librewolf/firefox.exe work/librewolf/librewolf.exe
|
||||
cp assets/librewolf.ico work/librewolf
|
||||
# this section makes the setup.exe
|
||||
mkdir work/x86-ansi
|
||||
wget -q -O ./work/x86-ansi/nsProcess.dll "https://shorsh.de/upload/2y9p/nsProcess.dll"
|
||||
wget -q -O ./work/vc_redist.x64.exe "https://aka.ms/vs/17/release/vc_redist.x64.exe"
|
||||
sed "s/pkg_version/$(full_version)/g" < assets/setup.nsi > work/tmp.nsi
|
||||
cp assets/librewolf.ico work
|
||||
cp assets/banner.bmp work
|
||||
( cd work && $(mozbuild)/nsis/bin/makensis -V1 tmp.nsi )
|
||||
rm -rf work/tmp.nsi work/librewolf.ico work/banner.bmp work/x86-ansi vc_redist.x64.exe
|
||||
mv work/$(setupname) .
|
||||
# this section makes the portable.zip
|
||||
rm -rf work/librewolf-$(full_version)
|
||||
mkdir -p work/librewolf-$(full_version)/Profiles/Default
|
||||
mkdir -p work/librewolf-$(full_version)/LibreWolf
|
||||
cp -r work/librewolf/* work/librewolf-$(full_version)/LibreWolf
|
||||
( cd work && git clone "https://github.com/ltGuillaume/LibreWolf-Portable" )
|
||||
cp work/LibreWolf-Portable/LibreWolf-Portable.* work/LibreWolf-Portable/*.exe work/librewolf-$(full_version)
|
||||
wget -q -O work/ahk.zip "https://www.autohotkey.com/download/ahk.zip"
|
||||
( mkdir work/ahk && cd work/ahk && unzip -q ../ahk.zip )
|
||||
( cd work/librewolf-$(full_version) && wine64 ../ahk/Compiler/Ahk2Exe.exe /in LibreWolf-Portable.ahk /icon LibreWolf-Portable.ico )
|
||||
( cd work/librewolf-$(full_version) && rm -f LibreWolf-Portable.ahk LibreWolf-Portable.ico dejsonlz4.exe jsonlz4.exe )
|
||||
# issue #224 - Consider including msvcp140 & vcruntime140 in portable package
|
||||
( cd work/librewolf-$(full_version)/LibreWolf && \
|
||||
wget -q -O ./vc_redist.x64-extracted.zip "https://gitlab.com/librewolf-community/browser/windows/uploads/7106b776dc663d985bb88eabeb4c5d7d/vc_redist.x64-extracted.zip" && \
|
||||
unzip vc_redist.x64-extracted.zip && \
|
||||
rm vc_redist.x64-extracted.zip )
|
||||
( rm -f $(zipname) && cd work && zip -qr9 ../$(zipname) librewolf-$(full_version) )
|
||||
@echo "artifacts.mk: Hello, world!"
|
||||
|
|
|
|||
0
flatpak/assets/post_build_distini_etc.sh → flatpak/assets/post_package_distini_etc.sh
Normal file → Executable file
0
flatpak/assets/post_build_distini_etc.sh → flatpak/assets/post_package_distini_etc.sh
Normal file → Executable file
0
flatpak/assets/pre_build_patches_mozconfig.sh
Normal file → Executable file
0
flatpak/assets/pre_build_patches_mozconfig.sh
Normal file → Executable file
Loading…
Add table
Reference in a new issue