Browse Source

generate linux-zip by default, and from that the xpi

master
Arian Sanusi Arian Sanusi (p≡p Foundation) 2 years ago
parent
commit
9d635a6ab1
No known key found for this signature in database GPG Key ID: 49B08FCFF6BC3B2
4 changed files with 39 additions and 11 deletions
  1. +15
    -10
      Makefile
  2. +1
    -0
      dependencies_fedora_27.sh
  3. +22
    -0
      enigmail_pEpAdapter_extensionRelative.patch
  4. +1
    -1
      prepareEnigmailTree.sh

+ 15
- 10
Makefile View File

@@ -7,8 +7,8 @@ ENIG_ID_DARWIN=macos-$(ID_POSTFIX)
ENIG_ID_WIN=windows-x86-$(shell date --rfc-3339=date)

.PHONY: all foreign
all: build/bin/pep-json-server build/enigmail-$(ENIG_ID).xpi build/share/pEp/system.db
foreign: build/enigmail-$(ENIG_ID_DARWIN).xpi build/enigmail-$(ENIG_ID_WIN).xpi
all: build/bin/pep-json-server build/enigmail-$(ENIG_ID).zip build/share/pEp/system.db
xpis: build/enigmail-$(ENIG_ID).xpi build/enigmail-$(ENIG_ID_DARWIN).xpi build/enigmail-$(ENIG_ID_WIN).xpi

build build/lib:
mkdir -p build/lib
@@ -70,23 +70,28 @@ build/bin/pep-json-server: engine-install
make -C pepjsonserveradapter/server all
cp pepjsonserveradapter/server/pep-json-server $@

build/enigmail-$(ENIG_ID).xpi: build/bin/pep-json-server build/share/pEp/system.db
build/pepmda: build/bin/pep-json-server build/share/pEp/system.db
mkdir -p $@
bash -e common/prepareEnigmailTree.sh build/pepmda build/bin/pep-json-server build/share/pEp/system.db `which gpg` common/vanilla

build/enigmail-$(ENIG_ID).zip: build/pepmda
cd build ; zip -r ~/$@ pepmda

build/enigmail-$(ENIG_ID).xpi: build/pepmda
git clone https://git.code.sf.net/p/enigmail/source enigmail || true # ( cd enigmail ; git pull )
cd enigmail ; git checkout caece124642980eed67ae917dbca33926bed84ef
-rm -rf enigmail/build/dist/pepmda
bash -e common/prepareEnigmailTree.sh enigmail build/bin/pep-json-server build/share/pEp/system.db `which gpg` common/vanilla
cd enigmail ; git checkout -- util/genxpi package/pEpAdapter.jsm package/pEp.jsm package/enigmail.js
mkdir -p ~/enigmail/build/dist
cp -rfp ~/build/pepmda enigmail/build/dist
cd enigmail ; git checkout -- util/genxpi package/pEpAdapter.jsm # package/pEp.jsm package/enigmail.js
patch -N enigmail/util/genxpi common/enigmail.genxpi.patch
patch -N enigmail/package/pEpAdapter.jsm common/enigmail_pEpAdapter.jsm.patch
patch -N enigmail/package/pEp.jsm common/enigmail_pEp.jsm.patch
patch -N enigmail/package/enigmail.js common/enigmail_enigmail.js.patch
patch -N enigmail/package/pEpAdapter.jsm common/enigmail_pEpAdapter_extensionRelative.patch
cd enigmail ; ./configure --prefix ~/build
$(MAKE) -C enigmail
cp enigmail/build/enigmail-2.0.xpi $@

build/enigmail-$(ENIG_ID_DARWIN).xpi: MDA_ZIP=pepmda-darwin-x86_64.zip
build/enigmail-$(ENIG_ID_WIN).xpi: MDA_ZIP=pepmda-winnt-x86.zip
build/enigmail-$(ENIG_ID_DARWIN).xpi build/enigmail-$(ENIG_ID_WIN).xpi: $(MDA_ZIP) #pepmda-darwin-x86_64.zip pepmda-winnt-x86.zip build/enigmail-$(ENIG_ID).xpi
build/enigmail-$(ENIG_ID_DARWIN).xpi build/enigmail-$(ENIG_ID_WIN).xpi: $(MDA_ZIP) build/enigmail-$(ENIG_ID).xpi #pepmda-darwin-x86_64.zip pepmda-winnt-x86.zip build/enigmail-$(ENIG_ID).xpi
rm -rf enigmail/build/dist/pepmda
unzip $(MDA_ZIP) -d enigmail/build/dist
$(MAKE) -C enigmail


+ 1
- 0
dependencies_fedora_27.sh View File

@@ -1,4 +1,5 @@
#!/bin/sh
set -e

certdir=/etc/pki/ca-trust/source/anchors/
packages="@development-tools gcc-c++ mercurial redhat-lsb python-lxml zlib-devel automake libtool supermin patchelf"


+ 22
- 0
enigmail_pEpAdapter_extensionRelative.patch View File

@@ -0,0 +1,22 @@
diff --git a/package/pEpAdapter.jsm b/package/pEpAdapter.jsm
index 542c71f8..0301910c 100644
--- a/package/pEpAdapter.jsm
+++ b/package/pEpAdapter.jsm
@@ -145,7 +145,16 @@ var EnigmailPEPAdapter = {
execFile = EnigmailFiles.resolvePath(
EnigmailFiles.potentialWindowsExecutable(PEP_SERVER_EXECUTABLE), pepmda.path, EnigmailOS.isDosLike);
if (!execFile || !execFile.exists() || !execFile.isExecutable()) {
- execFile = null;
+ let pepmda = EnigmailApp.getProfileDirectory();
+ pepmda.append("extensions");
+ pepmda.append("{847b3a00-7ab1-11d4-8f02-006008948af5}");
+ pepmda.append("pepmda");
+ pepmda.append("bin");
+ execFile = EnigmailFiles.resolvePath(
+ EnigmailFiles.potentialWindowsExecutable(PEP_SERVER_EXECUTABLE), pepmda.path, EnigmailOS.isDosLike);
+ if (!execFile || !execFile.exists() || !execFile.isExecutable()) {
+ execFile = null;
+ }
}
}
return execFile;

+ 1
- 1
prepareEnigmailTree.sh View File

@@ -9,7 +9,7 @@ if [[ "$#" -ne 5 ]] ; then
exit 1
fi

enigDist="$1"/build/dist/pepmda
enigDist="$1"
mda="$2"
systemDB="$3"
gpg="$4"


Loading…
Cancel
Save