commit 9fad802282ef9a571ed1ef11c2fa219f6f0cf571 Author: Thomas Briffard Date: Tue Jun 29 10:17:23 2021 +0200 commit initial, premières applications gérées: qtcreator, git, qgit, qcachegrind, valgrind, kdiff3 diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..496ac0b --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +*.AppImage +.env diff --git a/Dockerfile_centos7_base b/Dockerfile_centos7_base new file mode 100644 index 0000000..afe48e0 --- /dev/null +++ b/Dockerfile_centos7_base @@ -0,0 +1,64 @@ +FROM centos/devtoolset-7-toolchain-centos7 + +WORKDIR / +USER root + +# on installe les outils de bases +RUN yum install -y wget && wget http://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm && rpm -ivh epel-release-latest-7.noarch.rpm && yum install -y \ +autoconf \ +binutils \ +bison \ +boost-python36 \ +boost-python36-devel \ +bzip2 \ +ccache \ +clang \ +cmake3 \ +file \ +flex \ +fuse-devel \ +git \ +lapack \ +lapack-devel \ +libtool \ +libtirpc-devel \ +libXext-devel \ +libXmu-devel \ +libXpm-devel \ +libX11-devel \ +make \ +mesa-libEGL-devel \ +numactl-libs \ +numactl-devel \ +openblas \ +openblas-devel \ +pkg-config \ +python-devel \ +python3-devel \ +rh-python38 \ +rh-python38-python-devel \ +python-pip \ +python-six \ +qjson-devel \ +screen \ +tar \ +time \ +vim \ +xorg-x11-apps && \ +wget https://github.com/linuxdeploy/linuxdeploy/releases/download/continuous/linuxdeploy-x86_64.AppImage && \ +wget https://github.com/AppImage/AppImageKit/releases/download/continuous/appimagetool-x86_64.AppImage && \ +wget https://github.com/linuxdeploy/linuxdeploy-plugin-qt/releases/download/continuous/linuxdeploy-plugin-qt-x86_64.AppImage && \ +chmod +x linuxdeploy-x86_64.AppImage appimagetool-x86_64.AppImage linuxdeploy-plugin-qt-x86_64.AppImage && \ +mv linuxdeploy-x86_64.AppImage appimagetool-x86_64.AppImage linuxdeploy-plugin-qt-x86_64.AppImage /usr/bin/ && \ +yum clean all && python3 -m pip install --upgrade pip && pip3 install six + +# on fixe le fuseau horaire dans le conteneur, +ENV TZ=America/New_York +RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone && \ +echo "LC_ALL=en_US.UTF-8" >> /etc/environment && \ +echo "en_US.UTF-8 UTF-8" >> /etc/locale.gen && \ +echo "LANG=en_US.UTF-8" > /etc/locale.conf && \ +source /etc/locale.conf + +# Exécuter une commande au démarrage de l'image. +CMD ["/bin/bash"] diff --git a/Dockerfile_centos7_base_qt b/Dockerfile_centos7_base_qt new file mode 100644 index 0000000..5e7d9db --- /dev/null +++ b/Dockerfile_centos7_base_qt @@ -0,0 +1,13 @@ +FROM cos7_base + +WORKDIR / + +ARG QT_VER=5.15.2 +ENV QT_VER=$QT_VER +ENV QMAKE=/qt/$QT_VER/gcc_64/bin/qmake +RUN yum install -y cups postgresql unixODBC ninja-build libxkbcommon-x11 xcb-util-wm xcb-util-image xcb-util-keysyms xcb-util-renderutil ninja-build && \ + mkdir qt && cd qt/ && \ + pip3 install aqtinstall && aqt install $QT_VER linux desktop + +# Exécuter une commande au démarrage de l'image. +CMD ["/bin/bash"] diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..89bcbc1 --- /dev/null +++ b/Makefile @@ -0,0 +1,33 @@ +init_env: + @echo "USER=$(shell id -u)" > .env + @echo "GROUP=$(shell id -g)" >> .env + +build_base: + docker-compose build base + +build_base_qt: build_base + docker-compose build base_qt + +qtcreator: init_env build_base_qt + docker-compose build qtcreator + docker-compose run --rm qtcreator + +git: init_env build_base + docker-compose build git + docker-compose run --rm git + +qgit: init_env build_base_qt + docker-compose build qgit + docker-compose run --rm qgit + +qcachegrind: init_env build_base_qt + docker-compose build qcachegrind + docker-compose run --rm qcachegrind + +valgrind: init_env build_base + docker-compose build valgrind + docker-compose run --rm valgrind + +kdiff3: init_env build_base_qt + docker-compose build kdiff3 + docker-compose run --rm kdiff3 diff --git a/README.md b/README.md new file mode 100644 index 0000000..8e71a89 --- /dev/null +++ b/README.md @@ -0,0 +1,38 @@ +# Collection d'applications de développement au format AppImage + +Les applications suivantes: + + - valgrind + - git + - kdiff3 + - qgit + - qtcreator + - qcachegrind + +sont compilées dans un conteneur CentOS7 (glibc 2.17) puis livrées au format [AppImage](https://appimage.org/) via les outils [linuxdeploy](https://github.com/linuxdeploy/linuxdeploy) et [appimagetool](https://github.com/AppImage/AppImageKit). + +Actuellement, toutes les applications faisant appels à Qt sont compilées avec Qt 5.15.2 + +## Pré-Requis + +Vous devez avoir installé sur votre machine : + + - [Docker](https://docs.docker.com/engine/install/) + - [docker-compose](https://docs.docker.com/compose/install/) + +## Utilisation + +``` sh +make APP_NOM +``` + +par exemple, + +``` sh +make qtcreator +make qgit +``` + +Les AppImage seront situées dans les répertoires correspondant aux applications. + +La première fois, les images docker de bases seront constuites, ce qui peut-être assez long... diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..0ed9e13 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,123 @@ +# Les services base et base_qt servent uniquement au build +version: "3.3" +services: + base: + build: + context: . + dockerfile: ./Dockerfile_centos7_base + image: cos7_base + + base_qt: + build: + context: . + dockerfile: ./Dockerfile_centos7_base_qt + image: cos7_base_qt + depends_on: + - base + + qtcreator: + build: + context: ./qtcreator/ + dockerfile: ./Dockerfile_centos7_qtcreator + image: cos7_qtcreator + container_name: docker_cos7_qtcreator + privileged: true + volumes: + - ./qtcreator:/build + - ./template.sh:/template.sh + #tty: true + env_file: + - ./.env + environment: + - CUSTOM_STEP_PRE_DEPLOY=/build/qtcreator_pre_step.sh + - CUSTOM_STEP_POST_DEPLOY=/build/qtcreator_post_step.sh + - EXTRA_QT_PLUGINS=printsupport;sql;designer + - QML_SOURCES_PATHS=/qt-creator/qtcreator_build/share/qtcreator/ + - NOM_APPIMAGE=qtcreator_4.15.1 + command : ["bash", "-c","/template.sh /qt-creator/qtcreator_build/bin/qtcreator /build"] + + git: + build: + context: ./git/ + dockerfile: ./Dockerfile_centos7_git + image: cos7_git + container_name: docker_cos7_git + privileged: true + volumes: + - ./git:/build + - ./template.sh:/template.sh + env_file: + - ./.env + environment: + - CUSTOM_STEP_PRE_DEPLOY=/build/git_pre_step.sh + - NOM_APPIMAGE=git_2.32.0 + command : ["bash", "-c","/template.sh /usr/local/bin/git /build"] + + qgit: + build: + context: ./qgit/ + dockerfile: ./Dockerfile_centos7_qgit + image: cos7_qgit + container_name: docker_cos7_qgit + privileged: true + volumes: + - ./qgit:/build + - ./template.sh:/template.sh + env_file: + - ./.env + environment: + - CUSTOM_STEP_PRE_DEPLOY=/build/qgit_pre_step.sh + - NOM_APPIMAGE=qgit_2.9 + command : ["bash", "-c","/template.sh /qgit/bin/qgit /build"] + + qcachegrind: + build: + context: ./qcachegrind/ + dockerfile: ./Dockerfile_centos7_qcachegrind + image: cos7_qcachegrind + container_name: docker_cos7_qcachegrind + privileged: true + volumes: + - ./qcachegrind:/build + - ./template.sh:/template.sh + env_file: + - ./.env + environment: + - CUSTOM_STEP_PRE_DEPLOY=/build/qcachegrind_pre_step.sh + - NOM_APPIMAGE=qcachegrind_21.04.2 + command : ["bash", "-c","/template.sh /kcachegrind/qcachegrind/qcachegrind /build"] + + valgrind: + build: + context: ./valgrind/ + dockerfile: ./Dockerfile_centos7_valgrind + image: cos7_valgrind + container_name: docker_cos7_valgrind + privileged: true + volumes: + - ./valgrind:/build + - ./template.sh:/template.sh + env_file: + - ./.env + environment: + - CUSTOM_STEP_PRE_DEPLOY=/build/valgrind_pre_step.sh + - NOM_APPIMAGE=valgrind_3.17 + command : ["bash", "-c","/template.sh /usr/local/bin/valgrind /build"] + + kdiff3: + build: + context: ./kdiff3/ + dockerfile: ./Dockerfile_centos7_kdiff3 + image: cos7_kdiff3 + container_name: docker_cos7_kdiff3 + privileged: true + volumes: + - ./kdiff3:/build + - ./template.sh:/template.sh + env_file: + - ./.env + environment: + - CUSTOM_STEP_PRE_DEPLOY=/build/kdiff3_pre_step.sh + - NOM_APPIMAGE=kdiff3_1.9.2 + command : ["bash", "-c","/template.sh /usr/local/bin/kdiff3 /build"] + diff --git a/git/Dockerfile_centos7_git b/git/Dockerfile_centos7_git new file mode 100644 index 0000000..eaf7010 --- /dev/null +++ b/git/Dockerfile_centos7_git @@ -0,0 +1,13 @@ +FROM cos7_base + +ARG GIT_VER=2.32.0 + +RUN yum install -y curl-devel expat-devel gettext-devel openssl-devel zlib-devel perl-CPAN perl-devel && \ + wget https://github.com/git/git/archive/refs/tags/v$GIT_VER.tar.gz && \ + tar -xvf v$GIT_VER.tar.gz && \ + cd git-$GIT_VER && \ + make configure && ./configure --prefix=/usr/local && \ + make -j$(nproc) && make install + +# Exécuter une commande au démarrage de l'image. +CMD ["/bin/bash"] diff --git a/git/git.desktop b/git/git.desktop new file mode 100644 index 0000000..c52cb07 --- /dev/null +++ b/git/git.desktop @@ -0,0 +1,9 @@ +[Desktop Entry] +Name=git +Type=Application +Exec=git +Icon=git +Comment=analysis tools +Categories=Development +StartupWMClass=git +Terminal=false diff --git a/git/git.png b/git/git.png new file mode 100644 index 0000000..c7cf0fb Binary files /dev/null and b/git/git.png differ diff --git a/git/git_pre_step.sh b/git/git_pre_step.sh new file mode 100755 index 0000000..72ced20 --- /dev/null +++ b/git/git_pre_step.sh @@ -0,0 +1,7 @@ +#!/bin/bash +fichierIcon=/build/git.png +fichierDesktop=/build/git.desktop + +AUTRES_OPTIONS="-i $fichierIcon -d $fichierDesktop" + + diff --git a/kdiff3/Dockerfile_centos7_kdiff3 b/kdiff3/Dockerfile_centos7_kdiff3 new file mode 100644 index 0000000..9e988de --- /dev/null +++ b/kdiff3/Dockerfile_centos7_kdiff3 @@ -0,0 +1,12 @@ +FROM cos7_base_qt + +ARG KDIFF3_VER=1.9.2 +ENV LD_LIBRARY_PATH=/qt/$QT_VER/gcc_64/lib:$LD_LIBRARY_PATH + +RUN yum install -y boost169-devel extra-cmake-modules kf5-ki18n-devel kf5-kcoreaddons-devel kf5-kiconthemes-devel kf5-kparts-devel kf5-kdoctools-devel kf5-kcrash-devel && \ + git clone --recursive https://github.com/KDE/kdiff3.git && \ + cd kdiff3 && git checkout $KDIFF3_VER && \ + cmake3 -DCMAKE_PREFIX_PATH=/qt/$QT_VER/gcc_64 -DBOOST_INCLUDEDIR=/usr/include/boost169 -DBOOST_LIBRARYDIR=/usr/lib64/boost169 . && make && make install + +# Exécuter une commande au démarrage de l'image. +CMD ["/bin/bash"] diff --git a/kdiff3/kdiff3.desktop b/kdiff3/kdiff3.desktop new file mode 100644 index 0000000..b9242f0 --- /dev/null +++ b/kdiff3/kdiff3.desktop @@ -0,0 +1,9 @@ +[Desktop Entry] +Type=Application +Name=kdiff3 +GenericName=Kdiff3 +Comment=compares and merges +Exec=kdiff3 +Icon=kdiff3 +Categories=Development;RevisionControl;Qt +Terminal=false diff --git a/kdiff3/kdiff3.png b/kdiff3/kdiff3.png new file mode 100644 index 0000000..4816fdd Binary files /dev/null and b/kdiff3/kdiff3.png differ diff --git a/kdiff3/kdiff3_pre_step.sh b/kdiff3/kdiff3_pre_step.sh new file mode 100755 index 0000000..a4db2b6 --- /dev/null +++ b/kdiff3/kdiff3_pre_step.sh @@ -0,0 +1,7 @@ +#!/bin/bash + +fichierIcon=/build/kdiff3.png +fichierDesktop=/build/kdiff3.desktop + +AUTRES_OPTIONS="-i $fichierIcon -d $fichierDesktop --plugin qt" + diff --git a/qcachegrind/Dockerfile_centos7_qcachegrind b/qcachegrind/Dockerfile_centos7_qcachegrind new file mode 100644 index 0000000..cfb7669 --- /dev/null +++ b/qcachegrind/Dockerfile_centos7_qcachegrind @@ -0,0 +1,10 @@ +FROM cos7_base_qt + +# qcachegrind +ARG KCACHEGRIND_VER=v21.04.2 +RUN git clone --recursive https://github.com/KDE/kcachegrind.git && \ + cd kcachegrind && git checkout $KCACHEGRIND_VER && \ + PATH=/qt/$QT_VER/gcc_64/bin/:$PATH qmake; make + +# Exécuter une commande au démarrage de l'image. +CMD ["/bin/bash"] diff --git a/qcachegrind/kcachegrind.png b/qcachegrind/kcachegrind.png new file mode 100644 index 0000000..1cca5ed Binary files /dev/null and b/qcachegrind/kcachegrind.png differ diff --git a/qcachegrind/qcachegrind.desktop b/qcachegrind/qcachegrind.desktop new file mode 100644 index 0000000..4834558 --- /dev/null +++ b/qcachegrind/qcachegrind.desktop @@ -0,0 +1,159 @@ +[Desktop Entry] +Type=Application +Exec=qcachegrind %F +MimeType=application/x-kcachegrind; +Icon=kcachegrind +Terminal=false +Name=QCachegrind +Name[bg]=QCachegrind +Name[bs]=QCachegrind +Name[ca]=QCachegrind +Name[ca@valencia]=QCachegrind +Name[cs]=QCachegrind +Name[da]=QCachegrind +Name[de]=QCachegrind +Name[el]=QCachegrind +Name[en_GB]=QCachegrind +Name[es]=QCachegrind +Name[et]=QCachegrind +Name[fi]=QCachegrind +Name[fr]=QCachegrind +Name[ga]=QCachegrind +Name[gl]=QCachegrind +Name[hu]=QCachegrind +Name[it]=QCachegrind +Name[kk]=QCachegrind +Name[ko]=QCachegrind +Name[lt]=QCachegrind +Name[mr]=क्यु-कॅशेग्रिन्ड +Name[nb]=QCachegrind +Name[nds]=QCachegrind +Name[nl]=QCachegrind +Name[nn]=QCachegrind +Name[pa]=QCachegrind +Name[pl]=QCachegrind +Name[pt]=QCachegrind +Name[pt_BR]=QCachegrind +Name[ro]=QCachegrind +Name[ru]=QCachegrind +Name[sk]=QCachegrind +Name[sl]=QCachegrind +Name[sr]=Ку‑кешгринд +Name[sr@ijekavian]=Ку‑кешгринд +Name[sr@ijekavianlatin]=QCacheGrind +Name[sr@latin]=QCacheGrind +Name[sv]=Qcachegrind +Name[tr]=QCachegrind +Name[uk]=QCachegrind +Name[x-test]=xxQCachegrindxx +Name[zh_CN]=QCachegrind +Name[zh_TW]=QCachegrind +GenericName=Profiler Frontend +GenericName[bs]=Profajlerski program +GenericName[ca]=Frontal per a l'analitzador del rendiment +GenericName[ca@valencia]=Frontal per a l'analitzador del rendiment +GenericName[cs]=Rozhraní pro profilaci +GenericName[cy]=Blaen-wyneb Proffilydd +GenericName[da]=Grænseflade til profilering +GenericName[de]=Profiler-Oberfläche +GenericName[el]=Πρόγραμμα προφίλ +GenericName[en_GB]=Profiler Frontend +GenericName[eo]=Fasado de Profililo +GenericName[es]=Interfaz del analizador de rendimiento +GenericName[et]=Profileerimisrakendus +GenericName[eu]=Profilatzailearen interfazea +GenericName[fa]=پایانه گزارش‌گیر +GenericName[fi]=Profiloijan käyttöliittymä +GenericName[fr]=Interface de profilage +GenericName[ga]=Comhéadan ar Phróifíleoir +GenericName[gl]=Interface para o profiler +GenericName[hu]=Ábrázoló előtétprogram +GenericName[is]=Myndrænt viðmót á afkastakönnuð +GenericName[it]=Interfaccia a profiler +GenericName[ja]=プロファイラフロントエンド +GenericName[kk]=Профильдеткіштің интерфейсі +GenericName[km]=កម្មវិធី​ផ្នែក​ខាង​មុខ​របស់​ទម្រង់ +GenericName[ko]=프로파일러 프론트엔드 +GenericName[lt]=Profiliuoklio naudotojo sąsaja +GenericName[lv]=Profilēšanas priekšpuse +GenericName[mr]=प्रोफाइलर फ्रंटएन्ड +GenericName[nb]=Grensesnitt for profilvisning +GenericName[nds]=Profiler-Böversiet +GenericName[ne]=प्रोफाइलर फ्रन्टइन्ड +GenericName[nl]=Profiler-hulpprogramma +GenericName[nn]=Grensesnitt for profilvising +GenericName[pa]=ਪਰੋਫਾਇਲਰ ਫਰੰਟ-ਐਂਡ +GenericName[pl]=Interfejs do profilera +GenericName[pt]=Interface de Análise de Performance +GenericName[pt_BR]=Interface de análise de performance +GenericName[ro]=Interfață grafică pentru profilatoare +GenericName[ru]=Интерфейс к профилировщику +GenericName[sk]=Rozhranie pre profiler +GenericName[sl]=Začelje profilnika +GenericName[sr]=Прочеље профилизатора +GenericName[sr@ijekavian]=Прочеље профилизатора +GenericName[sr@ijekavianlatin]=Pročelje profilizatora +GenericName[sr@latin]=Pročelje profilizatora +GenericName[sv]=Profileringsgränssnitt +GenericName[ta]= விவரக்குறிப்பு முன்பகுதி +GenericName[tg]=Интерфейс ба профилкунанда +GenericName[tr]=Profil Önyüzü +GenericName[uk]=Інтерфейс до Profiler +GenericName[wa]=Eterface grafike po Profiler +GenericName[x-test]=xxProfiler Frontendxx +GenericName[zh_CN]=分析器前端 +GenericName[zh_TW]=分析器前端 +Comment=Visualization of Performance Profiling Data +Comment[bg]=Визуализация на данните за производителност +Comment[bs]=Predočenje podataka profiliranja performansi +Comment[ca]=Visualització de les dades d'anàlisi del rendiment +Comment[ca@valencia]=Visualització de les dades d'anàlisi del rendiment +Comment[cs]=Vizualizace profilovacích dat výkonu +Comment[da]=Visualisering af profileringsdata +Comment[de]=Visualisierung von Daten des Laufzeitverhaltens eines Programmes +Comment[el]=Αναπαράσταση δεδομένων ταχύτητας προφίλ +Comment[en_GB]=Visualisation of Performance Profiling Data +Comment[es]=Visualización de datos de análisis de rendimiento +Comment[et]=Jõudluse profileerimise andmete visualiseerimise vahend +Comment[eu]=Errendimendu profil datuen bistaratzea +Comment[fa]=تجسم کارایی گزارش داده‌ها +Comment[fi]=Visualisointi tehokkuusprofiloinnin tiedoista +Comment[fr]=Visualise les données de profilage de performances +Comment[ga]=Amharcléiriú ar Shonraí Próifílithe Feidhmíochta +Comment[gl]=Visualización dos datos da análise de rendemento +Comment[hu]=Teljesítményprofil-adatok megjelenítése +Comment[is]=Sjónræn framsetning gagna úr afkastakönnun +Comment[it]=Visualizzazione dei dati di profilo delle prestazioni +Comment[ja]=パフォーマンスプロファイルデータを視覚化 +Comment[kk]=Деректерді профильдеудің визуализациясы +Comment[km]=កា​រ​មើល​ឃើញ​ការ​អនុវត្ត​របស់​ទិន្នន័យ​ទម្រង់ +Comment[ko]=성능 프로파일링 데이터 시각화 +Comment[lt]=Veikimo profiliavimo duomenų vizualizacija +Comment[lv]=Veiktspējas profilēšanas datu vizualizācija +Comment[mr]=कार्यक्षमता प्रोफाइलिंग डेटाचे व्हिज्युअलायझेशन +Comment[nb]=Vis informasjon om ytelse. +Comment[nds]=Visualiseren vun Programmleisten-Looptietdaten +Comment[ne]=सम्पादन प्रोफाइलिङ डाटाको दृष्टिकरण +Comment[nl]=Visualisatie van Performance Profiling Data +Comment[nn]=Visualisering av data frå ytingsprofilar +Comment[pl]=Wizualizacja danych profilowania wydajności +Comment[pt]=Visualização dos Dados de Análise de Performance +Comment[pt_BR]=Visualização dos dados de análise de desempenho +Comment[ro]=Vizualizarea datelor de profilare a performanței +Comment[ru]=Утилита для визуального профилирования приложений +Comment[sk]=Vizualizácia dát o výkone +Comment[sl]=Vizualizacija podatkov profilnih zmogljivosti +Comment[sr]=Визуелизација профилисања перформанси +Comment[sr@ijekavian]=Визуелизација профилисања перформанси +Comment[sr@ijekavianlatin]=Vizuelizacija profilisanja performansi +Comment[sr@latin]=Vizuelizacija profilisanja performansi +Comment[sv]=Åskådliggörande av profileringsdata för prestanda +Comment[ta]= விவர தகவலை செயல்பாட்டு காட்சியாளிப்பு +Comment[tg]=Утилита барои гузориши профили визуалӣ +Comment[tr]=Performans Profilleme Verisinin Görünür Hali +Comment[ug]=سانلىق-مەلۇماتلارنىڭ سەپلىنىشىنى سۈرەتلەشتۈرۈش +Comment[uk]=Візуалізація даних профілювання швидкодії +Comment[x-test]=xxVisualization of Performance Profiling Dataxx +Comment[zh_CN]=性能测试数据的可视化表现 +Comment[zh_TW]=效能分析資料視覺化 +Categories=Qt;Development; diff --git a/qcachegrind/qcachegrind_pre_step.sh b/qcachegrind/qcachegrind_pre_step.sh new file mode 100755 index 0000000..502d2b0 --- /dev/null +++ b/qcachegrind/qcachegrind_pre_step.sh @@ -0,0 +1,7 @@ +#!/bin/bash + +fichierIcon=/build/kcachegrind.png +fichierDesktop=/build/qcachegrind.desktop + +AUTRES_OPTIONS="-i $fichierIcon -d $fichierDesktop --plugin qt" + diff --git a/qgit/Dockerfile_centos7_qgit b/qgit/Dockerfile_centos7_qgit new file mode 100644 index 0000000..e6b6f51 --- /dev/null +++ b/qgit/Dockerfile_centos7_qgit @@ -0,0 +1,11 @@ +FROM cos7_base_qt + +ARG QGIT_VER=2.9 + +RUN git clone --recursive https://github.com/tibirna/qgit.git && \ + cd qgit && git checkout qgit-$QGIT_VER && \ + PATH=/qt/$QT_VER/gcc_64/bin/:$PATH qmake qgit.pro && \ + make + +# Exécuter une commande au démarrage de l'image. +CMD ["/bin/bash"] diff --git a/qgit/qgit.desktop b/qgit/qgit.desktop new file mode 100644 index 0000000..536ecf2 --- /dev/null +++ b/qgit/qgit.desktop @@ -0,0 +1,9 @@ +[Desktop Entry] +Type=Application +Name=qgit +GenericName=QGit +Comment=A git GUI viewer +Exec=qgit +Icon=qgit +Categories=Development;RevisionControl;Qt +Terminal=false diff --git a/qgit/qgit.png b/qgit/qgit.png new file mode 100644 index 0000000..4816fdd Binary files /dev/null and b/qgit/qgit.png differ diff --git a/qgit/qgit_pre_step.sh b/qgit/qgit_pre_step.sh new file mode 100755 index 0000000..8eeaad7 --- /dev/null +++ b/qgit/qgit_pre_step.sh @@ -0,0 +1,7 @@ +#!/bin/bash + +fichierIcon=/build/qgit.png +fichierDesktop=/build/qgit.desktop + +AUTRES_OPTIONS="-i $fichierIcon -d $fichierDesktop --plugin qt" + diff --git a/qtcreator/Dockerfile_centos7_qtcreator b/qtcreator/Dockerfile_centos7_qtcreator new file mode 100644 index 0000000..5c3735a --- /dev/null +++ b/qtcreator/Dockerfile_centos7_qtcreator @@ -0,0 +1,13 @@ +FROM cos7_base_qt + +ARG QTCREATOR_VER=v4.15.1 + +RUN git clone --recursive https://code.qt.io/qt-creator/qt-creator.git && \ + cd qt-creator && \ + git checkout $QTCREATOR_VER && \ + mkdir qtcreator_build && cd qtcreator_build && \ + QT_VER=$QT_VER cmake3 -DCMAKE_BUILD_TYPE=Release -G Ninja "-DCMAKE_PREFIX_PATH=/qt/$QT_VER/gcc_64/" /qt-creator/ && \ + cmake3 --build . + +# Exécuter une commande au démarrage de l'image. +CMD ["/bin/bash"] diff --git a/qtcreator/QtProject-qtcreator.svg b/qtcreator/QtProject-qtcreator.svg new file mode 100644 index 0000000..c124a24 --- /dev/null +++ b/qtcreator/QtProject-qtcreator.svg @@ -0,0 +1,9 @@ + + + + + + + + + diff --git a/qtcreator/qtcreator.desktop b/qtcreator/qtcreator.desktop new file mode 100644 index 0000000..db08295 --- /dev/null +++ b/qtcreator/qtcreator.desktop @@ -0,0 +1,12 @@ +[Desktop Entry] +Type=Application +Exec=qtcreator %F +Name=Qt Creator +GenericName=C++ IDE for developing Qt applications +X-KDE-StartupNotify=true +Icon=QtProject-qtcreator +StartupWMClass=qtcreator +Terminal=false +Categories=Development;IDE;Qt; +MimeType=text/x-c++src;text/x-c++hdr;text/x-xsrc;application/x-designer;application/vnd.qt.qmakeprofile;application/vnd.qt.xml.resource; + diff --git a/qtcreator/qtcreator_post_step.sh b/qtcreator/qtcreator_post_step.sh new file mode 100755 index 0000000..7cde73a --- /dev/null +++ b/qtcreator/qtcreator_post_step.sh @@ -0,0 +1,6 @@ +#!/bin/bash +cp -r --preserve=links /qt-creator/qtcreator_build/lib/qtcreator $WORK_DIR/AppDir/usr/lib/ +cp -r --preserve=links /qt-creator/qtcreator_build/share/qtcreator $WORK_DIR/AppDir/usr/share/ + +wget https://thomasbriffard.com/public/mon_style_qtcreator.xml -O $WORK_DIR/AppDir/usr/share/qtcreator/styles/onedark_like.xml + diff --git a/qtcreator/qtcreator_pre_step.sh b/qtcreator/qtcreator_pre_step.sh new file mode 100755 index 0000000..485bbd2 --- /dev/null +++ b/qtcreator/qtcreator_pre_step.sh @@ -0,0 +1,18 @@ +#!/bin/bash + +cat << EOF > $WORK_DIR/AppRun +#!/bin/bash +APPDIR=\$(dirname -- "\$0") + +export LD_LIBRARY_PATH=\$APPDIR/usr/lib/:\$LD_LIBRARY_PATH + +exec \$APPDIR/usr/bin/$APP_NOM "\$@" +EOF + +fichierIcon=/build/QtProject-qtcreator.svg +fichierDesktop=/build/qtcreator.desktop + +QT_LIB=/qt/$QT_VER/gcc_64/lib/ +AUTRES_LIB="-l $QT_LIB/libQt5Help.so.5 -l $QT_LIB/libQt5QuickWidgets.so.5 -l $QT_LIB/libQt5DesignerComponents.so.5" + +AUTRES_OPTIONS="-i $fichierIcon -d $fichierDesktop $AUTRES_LIB --custom-apprun $WORK_DIR/AppRun --plugin qt" diff --git a/template.sh b/template.sh new file mode 100755 index 0000000..16c2eb7 --- /dev/null +++ b/template.sh @@ -0,0 +1,79 @@ +#!/bin/bash +# à utiliser pour builder une appimage d'une app quelconque, y compris hors cadre GIREF/BIB +# Ceci est un point départ plus qu'un script clef en main ! +function exit_on_fail() { + "$@" + local status=$? + if [ $status -ne 0 ]; then + echo "Erreur avec: $@" >&2 + exit $status + fi + return $status +} + +# Fonction permettant d'effectuer quelques vérifications de base +function verifications() { + echo "### Vérifications" + command -v linuxdeploy-x86_64.AppImage >/dev/null 2>&1 || { + echo >&2 "L'outil linuxdeploy-x86_64.AppImage n'est pas présent, pas de livraison possible !" + exit 1 + } + command -v appimagetool-x86_64.AppImage >/dev/null 2>&1 || { + echo >&2 "L'outil appimagetool-x86_64.AppImage n'est pas présent, pas de livraison possible !" + exit 1 + } +} + +if [[ "$#" -ne 2 ]] && [[ "$#" -ne 3 ]]; then + echo "Usage: $0 CHEMIN_COMPLET_VERS_APP/mon_app CHEMIN_DESTINATION_APPIMAGE" + exit 0 +fi + +script_dir=$(dirname $0) +BIN=$1 +DEST_DIR=$2 + +verifications + +APP_NOM=$(basename $BIN) +if [[ -z NOM_APPIMAGE ]]; then + if [[ "$APP_NOM" =~ "." ]]; then + NOM_APPIMAGE="${APP_NOM%.???}" + else + NOM_APPIMAGE=$APP_NOM + fi +fi + +AUTRES_OPTIONS="" + +# Répertoire de travail +WORK_DIR=$DEST_DIR/build_AppImage +rm -rf $WORK_DIR +mkdir -p $WORK_DIR/AppDir + +# Si la variable d'env CUSTOM_STEP_PRE_DEPLOY n'est pas vide, on l'utilise pour spécifier des commandes supplémentaires +# (CUSTOM_STEP_PRE_DEPLOY doit être le chemin vers le fichier contenant les commandes supplémentaires +if [[ -n $CUSTOM_STEP_PRE_DEPLOY ]]; then + echo "On source le fichier $CUSTOM_STEP_PRE_DEPLOY" + source $CUSTOM_STEP_PRE_DEPLOY +fi + +exit_on_fail linuxdeploy-x86_64.AppImage --appdir $WORK_DIR/AppDir \ + --executable $BIN \ + $AUTRES_OPTIONS + +# idem PRE_DEPLOY mais après l'appel à linuxdeploy (la structure du AppDir est alors terminée) +if [[ -n $CUSTOM_STEP_POST_DEPLOY ]]; then + echo "On source le fichier $CUSTOM_STEP_POST_DEPLOY" + source $CUSTOM_STEP_POST_DEPLOY +fi + +# Création du fichier .AppImage +echo "### Création fichier .AppImage" +exit_on_fail appimagetool-x86_64.AppImage $WORK_DIR/AppDir $DEST_DIR/$NOM_APPIMAGE.AppImage + +rm -rf $WORK_DIR + +chown $USER:$GROUP $DEST_DIR/$NOM_APPIMAGE.AppImage +echo "Création terminée ! -> $DEST_DIR/$NOM_APPIMAGE.AppImage" + diff --git a/valgrind/Dockerfile_centos7_valgrind b/valgrind/Dockerfile_centos7_valgrind new file mode 100644 index 0000000..0d8a8ea --- /dev/null +++ b/valgrind/Dockerfile_centos7_valgrind @@ -0,0 +1,14 @@ +FROM cos7_base + +ARG VALGRIND_VER=valgrind-3.17.0 + +RUN wget https://sourceware.org/pub/valgrind/$VALGRIND_VER.tar.bz2 && \ + tar -xvf $VALGRIND_VER.tar.bz2 && \ + cd $VALGRIND_VER && \ + ./configure && \ + make -j$(nproc) && \ + make install && \ + cd ../ && rm -rf $VALGRIND_VER* + +# Exécuter une commande au démarrage de l'image. +CMD ["/bin/bash"] diff --git a/valgrind/valgrind.desktop b/valgrind/valgrind.desktop new file mode 100644 index 0000000..b97f538 --- /dev/null +++ b/valgrind/valgrind.desktop @@ -0,0 +1,9 @@ +[Desktop Entry] +Name=valgrind +Type=Application +Exec=valgrind +Icon=valgrind +Comment=analysis tools +Categories=Development +StartupWMClass=valgrind +Terminal=false diff --git a/valgrind/valgrind.png b/valgrind/valgrind.png new file mode 100644 index 0000000..1cca5ed Binary files /dev/null and b/valgrind/valgrind.png differ diff --git a/valgrind/valgrind_pre_step.sh b/valgrind/valgrind_pre_step.sh new file mode 100755 index 0000000..0f94018 --- /dev/null +++ b/valgrind/valgrind_pre_step.sh @@ -0,0 +1,20 @@ +#!/bin/bash +cp -r --preserve=links /usr/local/libexec/valgrind $WORK_DIR/AppDir/ + +cat << EOF > $WORK_DIR/AppRun +#!/bin/bash +APPDIR=\$(dirname -- "\$0") + +export PATH=\$APPDIR/usr/bin:$PATH +export LD_LIBRARY_PATH=\$APPDIR/usr/lib/:$LD_LIBRARY_PATH +export VALGRIND_LIB=\$APPDIR/valgrind + +exec \$APPDIR/usr/bin/$APP_NOM "\$@" +EOF + +fichierIcon=/build/valgrind.png +fichierDesktop=/build/valgrind.desktop + +AUTRES_OPTIONS="-i $fichierIcon -d $fichierDesktop --custom-apprun $WORK_DIR/AppRun" + +