1
0
mirror of https://github.com/ciromattia/kcc synced 2025-12-13 17:56:30 +00:00

Overhauled Linux build environment

This commit is contained in:
Paweł Jastrzębski
2016-02-18 12:21:21 +01:00
parent f78dc3cd8f
commit c9cf635229
3 changed files with 2 additions and 29 deletions

View File

@@ -1,26 +0,0 @@
# Recipe used to build DEB package
FROM acidweb/kcc-base
MAINTAINER Paweł Jastrzębski <pawelj@iosphe.re>
ENV KCCVER 5.0.1
ADD . /app
RUN pip3 install pillow python-slugify psutil scandir pyinstaller
RUN gem install fpm
RUN useradd -ms /bin/bash kcc && chown -R kcc:kcc /app
USER kcc
WORKDIR /app
RUN pyinstaller -F -s --noupx kcc.py
RUN mkdir -p dist/usr/bin dist/usr/share/applications dist/usr/share/doc/kindlecomicconverter dist/usr/share/kindlecomicconverter dist/usr/share/lintian/overrides
RUN mv dist/kcc dist/usr/bin
RUN cp icons/comic2ebook.png dist/usr/share/kindlecomicconverter
RUN cp LICENSE.txt dist/usr/share/doc/kindlecomicconverter/copyright
RUN cp other/linux/kindlecomicconverter.desktop dist/usr/share/applications
RUN cp other/linux/kindlecomicconverter dist/usr/share/lintian/overrides
WORKDIR /app/dist
RUN fpm -f -s dir -t deb -n kindlecomicconverter -v $KCCVER -m "Paweł Jastrzębski <pawelj@iosphe.re>" --license "ISC" --description "Comic and Manga converter for e-book readers.\nThis app allows you to transform your PNG, JPG, GIF, CBZ, CBR and CB7 files\ninto EPUB or MOBI format e-books." --url "https://kcc.iosphe.re/" --deb-priority "optional" --vendor "" --category "graphics" -d "unrar | unrar-free" -d "p7zip-full" usr
CMD mkdir -p /out/dist && cp kindlecomicconverter_${KCCVER}_amd64.deb /out/dist

View File

@@ -1,4 +1,4 @@
kindlecomicconverter: statically-linked-binary usr/bin/kcc
kindlecomicconverter: binary-without-manpage usr/bin/kcc kindlecomicconverter: binary-without-manpage usr/bin/kcc
kindlecomicconverter: wrong-name-for-changelog-of-native-package usr/share/doc/kindlecomicconverter/changelog.Debian.gz kindlecomicconverter: wrong-name-for-changelog-of-native-package usr/share/doc/kindlecomicconverter/changelog.Debian.gz
kindlecomicconverter: file-missing-in-md5sums usr/share/doc/kindlecomicconverter/changelog.Debian.gz kindlecomicconverter: file-missing-in-md5sums usr/share/doc/kindlecomicconverter/changelog.Debian.gz
kindlecomicconverter: hardening-no-relro usr/bin/kcc

View File

@@ -90,8 +90,7 @@ class BuildBinaryCommand(distutils.cmd.Command):
os.system("bash -c '%s'" % script) os.system("bash -c '%s'" % script)
exit(0) exit(0)
else: else:
os.system('docker build --no-cache -t kcc . && docker run --rm -v ' + os.getcwd() + os.system('docker run --rm -v ' + os.getcwd() + ':/app -e KCCVER=' + VERSION + ' acidweb/kcc')
':/out kcc && docker rmi kcc')
exit(0) exit(0)