thunderbird-91.2.1

This commit is contained in:
Rmys
2021-11-01 19:25:36 +02:00
committed by GitHub
parent 207ac754f9
commit 5ce97e10f5
7 changed files with 667 additions and 217 deletions
+56 -10
View File
@@ -9,14 +9,60 @@ from pisi.actionsapi import autotools
from pisi.actionsapi import pisitools
from pisi.actionsapi import shelltools
ObjDir = "build"
MOZAPPDIR= "/usr/lib/thunderbird"
shelltools.export("SHELL", "/bin/sh")
shelltools.export("MACH_USE_SYSTEM_PYTHON", "1")
locales = "be ca da de el en-GB en-US es-AR es-ES fi fr hr hu it lt nl pl pt-BR pt-PT ro ru sr sv-SE tr uk".split()
xpidir = "%s/xpi" % get.workDIR()
arch = get.ARCH()
ver = ".".join(get.srcVERSION().split(".")[:3])
def setup():
pisitools.dosed(".mozconfig", "##JOBCOUNT##", get.makeJOBS())
# LOCALE
shelltools.system("rm -rf langpack-tb/*/browser/defaults")
if not shelltools.isDirectory(xpidir): shelltools.makedirs(xpidir)
for locale in locales:
shelltools.system("wget -c -P %s http://ftp.mozilla.org/pub/mozilla.org/thunderbird/releases/%s/linux-%s/xpi/%s.xpi" % (xpidir, ver, arch, locale))
shelltools.makedirs("langpack-tb")
shelltools.system("cp %s/%s.xpi langpack-tb/langpack-%s@thunderbird.mozilla.org.xpi" % (xpidir, locale, locale))
#shelltools.makedirs("langpack-tb/langpack-%s@thunderbird.mozilla.org" % locale)
#shelltools.system("unzip -uo %s/%s.xpi -d langpack-tb/langpack-%s@thunderbird.mozilla.org" % (xpidir, locale, locale))
shelltools.makedirs(ObjDir)
shelltools.cd(ObjDir)
shelltools.system("../mach configure")
def build():
shelltools.cd(ObjDir)
shelltools.system("../mach build")
shelltools.system("../mach buildsymbols")
def install():
pisitools.insinto("/opt/thunderbird", "*")
shelltools.system("mkdir -p %s/usr/bin" % get.installDIR())
#shelltools.system("ln -s /opt/thunderbird/thunderbird /usr/bin/thunderbird" )
pisitools.dosym("/opt/thunderbird/thunderbird","/usr/bin/thunderbird")
for i in ("16", "22", "24", "32", "48", "64", "128", "256"):
pisitools.dodir("/usr/share/icons/hicolor/%sx%s/apps" % (i, i))
pisitools.domove("/opt/thunderbird/chrome/icons/default/default%s.png" % (i), "/usr/share/icons/hicolor/%sx%s/apps" % (i, i),"thunderbird.png")
# Use system certificates
pisitools.dodir("/usr/lib")
shelltools.system("ln -s %s/opt/thunderbird/libnssckbi.so %s/usr/lib/libnssckbi.so" % (get.installDIR(), get.installDIR()))
shelltools.cd(ObjDir)
shelltools.system("DESTDIR=%s ../mach install " % get.installDIR())
shelltools.cd("..")
# Install fix language packs
pisitools.insinto("/usr/lib/thunderbird/extensions", "langpack-tb/*")
# Install icons
pisitools.insinto("/usr/share/pixmaps", "comm/mail/branding/thunderbird/default256.png", "thunderbird.png")
pisitools.insinto("%s/icons" % MOZAPPDIR, "comm/mail/branding/thunderbird/default16.png")
for s in (16, 22, 24, 32, 48, 64, 128, 256):
pisitools.insinto("/usr/share/icons/hicolor/%dx%d/apps" % (s,s), "comm/mail/branding/thunderbird/default%d.png" % s, "thunderbird.png")
# We don't want the development stuff
#pisitools.removeDir("/usr/lib/thunderbird-devel*")
#pisitools.removeDir("/usr/share/idl")
#pisitools.removeDir("/usr/include")
# Install docs
pisitools.dodoc("README*", "LICENSE")