| View previous topic :: View next topic |
| Author |
Message |
charles17 Advocate

Joined: 02 Mar 2008 Posts: 3675
|
Posted: Wed Feb 12, 2020 11:01 am Post subject: [SOLVED] AusweisApp2, need help for ebuild |
|
|
Let's start with this, taken from the wiki:
| AusweisApp2-1.20.0.ebuild: | # Copyright 2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
DESCRIPTION="Official authentication app for German ID cards and residence permits"
HOMEPAGE="https://www.ausweisapp.bund.de/"
SRC_URI="https://github.com/Governikus/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="EUPL-1.2"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE=""
DEPEND=""
RDEPEND="${DEPEND}"
BDEPEND=""
|
First question is how to handle the license which is EUPL v1.2 but Gentoo only has EUPL-1.1
Last edited by charles17 on Thu Feb 27, 2020 9:59 am; edited 3 times in total |
|
| Back to top |
|
 |
fedeliallalinea Administrator


Joined: 08 Mar 2003 Posts: 31082 Location: here
|
Posted: Wed Feb 12, 2020 11:18 am Post subject: |
|
|
You should download EUPL v1.2 text and put in your overlay in licenses directory. _________________ Questions are guaranteed in life; Answers aren't. |
|
| Back to top |
|
 |
charles17 Advocate

Joined: 02 Mar 2008 Posts: 3675
|
|
| Back to top |
|
 |
fedeliallalinea Administrator


Joined: 08 Mar 2003 Posts: 31082 Location: here
|
|
| Back to top |
|
 |
charles17 Advocate

Joined: 02 Mar 2008 Posts: 3675
|
Posted: Wed Feb 12, 2020 1:23 pm Post subject: |
|
|
Thanks, that's clear now.
Next question: Upstream tells me to use cmake for creating a makefile.
I guess this means to inherit cmake-utils and call | Code: | src_prepare() {
cmake-utils_src_prepare
} |
So I am now trying with | Code: | # Copyright 2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit cmake-utils
DESCRIPTION="Official authentication app for German ID cards and residence permits"
HOMEPAGE="https://www.ausweisapp.bund.de/"
SRC_URI="https://github.com/Governikus/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="EUPL-1.2"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE=""
DEPEND=""
RDEPEND="${DEPEND}"
BDEPEND=""
src_prepare() {
cmake-utils_src_prepare
} |
Is this the way to go? Are there any pitfalls? |
|
| Back to top |
|
 |
fedeliallalinea Administrator


Joined: 08 Mar 2003 Posts: 31082 Location: here
|
Posted: Wed Feb 12, 2020 1:32 pm Post subject: |
|
|
Yes use cmake-utils or cmake-multilib if program work also in 32bit.
If in src_prepare you don't need to do particular things you can also omit cmake-utils_src_prepare, it's automagically called
EDIT: you can build application also without shared lib in this case cmake-utils is correct _________________ Questions are guaranteed in life; Answers aren't. |
|
| Back to top |
|
 |
charles17 Advocate

Joined: 02 Mar 2008 Posts: 3675
|
Posted: Wed Feb 12, 2020 1:50 pm Post subject: |
|
|
Good to know. Regarding 32bit I have no clue. Will check that later upstream.
After commenting out and adding some dependencies I am presently checking configure with | Code: | # Copyright 2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit cmake-utils
DESCRIPTION="Official authentication app for German ID cards and residence permits"
HOMEPAGE="https://www.ausweisapp.bund.de/"
SRC_URI="https://github.com/Governikus/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="EUPL-1.2"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE=""
DEPEND="
dev-qt/qtwebsockets
dev-qt/qtquickcontrols2
sys-apps/pcsc-lite"
RDEPEND="${DEPEND}"
BDEPEND=""
#
# src_prepare() {
# cmake-utils_src_prepare
# } |
Output looks like http://dpaste.com/1H9QHW7
Would I need to do something with the Hardcoded definition(s) removed in stuff? |
|
| Back to top |
|
 |
fedeliallalinea Administrator


Joined: 08 Mar 2003 Posts: 31082 Location: here
|
Posted: Wed Feb 12, 2020 2:06 pm Post subject: |
|
|
| charles17 wrote: | | Would I need to do something with the Hardcoded definition(s) removed in stuff? |
I don't know, it's first time that I see this message, anyway operation seems successful done _________________ Questions are guaranteed in life; Answers aren't. |
|
| Back to top |
|
 |
charles17 Advocate

Joined: 02 Mar 2008 Posts: 3675
|
Posted: Wed Feb 12, 2020 2:27 pm Post subject: |
|
|
| http://dpaste.com/1H9QHW7 wrote: | -- The following OPTIONAL packages have been found:
* Java
* PythonInterp (required version >= 2.7)
-- The following REQUIRED packages have been found:
* Qt5Core (required version >= 5.10)
* Qt5Concurrent (required version >= 5.10)
* Qt5Network (required version >= 5.10)
* Qt5Gui (required version >= 5.13.2)
* Qt5Svg (required version >= 5.10)
* Qt5LinguistTools (required version >= 5.10)
* Qt5WebSockets (required version >= 5.10)
* Qt5Qml (required version >= 5.10)
* Qt5Quick (required version >= 5.10)
* Qt5QuickControls2 (required version >= 5.10)
* Qt5Widgets (required version >= 5.10)
* OpenSSL (required version >= 1.1)
* PkgConfig
-- The following OPTIONAL packages have not been found:
* Doxygen |
I want to add the REQUIRED packages to DEPEND, but cannot find what is Qt5Qml and Qt5Quick.
Any idea? |
|
| Back to top |
|
 |
fedeliallalinea Administrator


Joined: 08 Mar 2003 Posts: 31082 Location: here
|
Posted: Wed Feb 12, 2020 2:37 pm Post subject: |
|
|
| charles17 wrote: | I want to add the REQUIRED packages to DEPEND, but cannot find what is Qt5Qml[color] and [color=red]Qt5Quick.
Any idea? |
Yes
| Code: | $ equery b /usr/include/qt5/QtQml/qtqml-config.h
* Searching for /usr/include/qt5/QtQml/qtqml-config.h ...
dev-qt/qtdeclarative-5.14.1 (/usr/include/qt5/QtQml/qtqml-config.h)
$ equery b /usr/lib64/libQt5Quick.so
* Searching for /usr/lib64/libQt5Quick.so ...
dev-qt/qtdeclarative-5.14.1 (/usr/lib64/libQt5Quick.so.5.14.1)
dev-qt/qtdeclarative-5.14.1 (/usr/lib64/libQt5Quick.so -> libQt5Quick.so.5.14.1) |
but
| Code: | $ equery d dev-qt/qtdeclarative
* These packages depend on dev-qt/qtdeclarative:
...
dev-qt/qtwebsockets-5.14.1 (qml ? ~dev-qt/qtdeclarative-5.14.1)
... |
so you can add only dev-qt/qtwebsockets[qml] _________________ Questions are guaranteed in life; Answers aren't. |
|
| Back to top |
|
 |
charles17 Advocate

Joined: 02 Mar 2008 Posts: 3675
|
Posted: Wed Feb 12, 2020 2:56 pm Post subject: |
|
|
| fedeliallalinea wrote: | | so you can add only dev-qt/qtwebsockets[qml] |
Done.
Now I have | AusweisApp2-1.20.0.ebuild: | # Copyright 2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit cmake-utils
DESCRIPTION="Official authentication app for German ID cards and residence permits"
HOMEPAGE="https://www.ausweisapp.bund.de/"
SRC_URI="https://github.com/Governikus/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="EUPL-1.2"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="doc"
DEPEND="
dev-qt/qtcore
dev-qt/qtconcurrent
dev-qt/qtnetwork
dev-qt/qtgui
dev-qt/qtsvg
dev-qt/linguist-tools
dev-qt/qtwebsockets[qml]
dev-qt/qtdeclarative
dev-qt/qtquickcontrols2
dev-qt/qtwidgets
dev-libs/openssl
virtual/pkgconfig
sys-apps/pcsc-lite
doc? ( app-doc/doxygen )"
RDEPEND="${DEPEND}"
BDEPEND=""
# src_prepare() {
# cmake-utils_src_prepare
# } |
And repoman tells me | Code: | RDEPEND.suspect 3
sys-auth/AusweisApp2/AusweisApp2-1.20.0.ebuild: 'dev-qt/linguist-tools'
sys-auth/AusweisApp2/AusweisApp2-1.20.0.ebuild: 'virtual/pkgconfig'
sys-auth/AusweisApp2/AusweisApp2-1.20.0.ebuild: 'app-doc/doxygen' |
What does that mean? |
|
| Back to top |
|
 |
fedeliallalinea Administrator


Joined: 08 Mar 2003 Posts: 31082 Location: here
|
Posted: Wed Feb 12, 2020 3:12 pm Post subject: |
|
|
If you add dev-qt/qtwebsockets[qml] you can omit dev-qt/qtdeclarative.
Use also slot :5 for qt packages because in some overlays there is yet qt:4 libs
| charles17 wrote: | And repoman tells me | Code: | RDEPEND.suspect 3
sys-auth/AusweisApp2/AusweisApp2-1.20.0.ebuild: 'dev-qt/linguist-tools'
sys-auth/AusweisApp2/AusweisApp2-1.20.0.ebuild: 'virtual/pkgconfig'
sys-auth/AusweisApp2/AusweisApp2-1.20.0.ebuild: 'app-doc/doxygen' |
What does that mean? |
| man repoman: | RDEPEND.suspect
RDEPEND contains a package that usually only belongs in DEPEND |
_________________ Questions are guaranteed in life; Answers aren't. |
|
| Back to top |
|
 |
charles17 Advocate

Joined: 02 Mar 2008 Posts: 3675
|
Posted: Wed Feb 12, 2020 3:21 pm Post subject: |
|
|
Done.
| AusweisApp2-1.20.0.ebuild: | # Copyright 2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit cmake-utils
DESCRIPTION="Official authentication app for German ID cards and residence permits"
HOMEPAGE="https://www.ausweisapp.bund.de/"
SRC_URI="https://github.com/Governikus/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="EUPL-1.2"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="doc"
CDEPEND="
dev-qt/qtcore:5
dev-qt/qtconcurrent:5
dev-qt/qtnetwork:5
dev-qt/qtgui:5
dev-qt/qtsvg:5
dev-qt/qtwebsockets:5[qml]
dev-qt/qtquickcontrols2:5
dev-qt/qtwidgets:5
dev-libs/openssl
sys-apps/pcsc-lite"
DEPEND="
dev-qt/linguist-tools:5
virtual/pkgconfig
doc? ( app-doc/doxygen )
${CDEPEND}"
RDEPEND="${CDEPEND}"
BDEPEND=""
# src_prepare() {
# cmake-utils_src_prepare
# |
Now, how to deal with python stuff? |
|
| Back to top |
|
 |
fedeliallalinea Administrator


Joined: 08 Mar 2003 Posts: 31082 Location: here
|
Posted: Wed Feb 12, 2020 3:25 pm Post subject: |
|
|
You can also write dependencies without use a new variable
| Code: | RDEPEND="
dev-qt/qtcore:5
dev-qt/qtconcurrent:5
dev-qt/qtnetwork:5
dev-qt/qtgui:5
dev-qt/qtsvg:5
dev-qt/qtwebsockets:5[qml]
dev-qt/qtquickcontrols2:5
dev-qt/qtwidgets:5
dev-libs/openssl
sys-apps/pcsc-lite"
DEPEND="${RDEPEND}
dev-qt/linguist-tools:5
virtual/pkgconfig
doc? ( app-doc/doxygen )" |
| charles17 wrote: | | Now, how to deal with python stuff? |
I don't know how the package uses python but is an optional dependency _________________ Questions are guaranteed in life; Answers aren't. |
|
| Back to top |
|
 |
charles17 Advocate

Joined: 02 Mar 2008 Posts: 3675
|
Posted: Wed Feb 12, 2020 3:50 pm Post subject: |
|
|
| fedeliallalinea wrote: | You can also write dependencies without use a new variable
| Code: | RDEPEND="
dev-qt/qtcore:5
dev-qt/qtconcurrent:5
dev-qt/qtnetwork:5
dev-qt/qtgui:5
dev-qt/qtsvg:5
dev-qt/qtwebsockets:5[qml]
dev-qt/qtquickcontrols2:5
dev-qt/qtwidgets:5
dev-libs/openssl
sys-apps/pcsc-lite"
DEPEND="${RDEPEND}
dev-qt/linguist-tools:5
virtual/pkgconfig
doc? ( app-doc/doxygen )" |
|
Done.
| AusweisApp2-1.20.0.ebuild: | # Copyright 2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit cmake-utils
DESCRIPTION="Official authentication app for German ID cards and residence permits"
HOMEPAGE="https://www.ausweisapp.bund.de/"
SRC_URI="https://github.com/Governikus/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="EUPL-1.2"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="doc"
RDEPEND="
dev-qt/qtcore:5
dev-qt/qtconcurrent:5
dev-qt/qtnetwork:5
dev-qt/qtgui:5
dev-qt/qtsvg:5
dev-qt/qtwebsockets:5[qml]
dev-qt/qtquickcontrols2:5
dev-qt/qtwidgets:5
dev-libs/openssl
sys-apps/pcsc-lite"
DEPEND="${RDEPEND}
dev-qt/linguist-tools:5
virtual/pkgconfig
doc? ( app-doc/doxygen ) |
And then, when I run ebuild AusweisApp2-1.20.0.ebuild clean install I get | Code: | $ tree /var/tmp/portage/sys-auth/AusweisApp2-1.20.0/image
/var/tmp/portage/sys-auth/AusweisApp2-1.20.0/image
└── usr
├── bin
│ └── AusweisApp2
└── share
├── applications
│ └── com.governikus.ausweisapp2.desktop
├── AusweisApp2_CE
│ └── AusweisApp2
│ ├── AusweisApp2.rcc
│ ├── config.json
│ ├── npa.svg
│ └── translations
│ └── ausweisapp2_de.qm
├── doc
│ └── AusweisApp2-1.20.0
│ ├── AUTHORS.bz2
│ └── README.rst.bz2
└── metainfo
└── com.governikus.ausweisapp2.metainfo.xml
|
I kind of remember there was something to be done for the desktop stuff ...
And, what about package category, would sys-auth be appropriate for authentication using the German identity card?
Presently, /usr/bin/AusweisApp2 fails with | Code: | | /usr/bin/AusweisApp2: error while loading shared libraries: libAusweisAppInit.so: cannot open shared object file: No such file or directory |
| fedeliallalinea wrote: | | charles17 wrote: | | Now, how to deal with python stuff? |
I don't know how the package uses python but is an optional dependency |
Will do that later, also java |
|
| Back to top |
|
 |
fedeliallalinea Administrator


Joined: 08 Mar 2003 Posts: 31082 Location: here
|
Posted: Wed Feb 12, 2020 4:18 pm Post subject: |
|
|
| charles17 wrote: | | I kind of remember there was something to be done for the desktop stuff ... |
Like what?
| charles17 wrote: | | And, what about package category, would sys-auth be appropriate for authentication using the German identity card? |
It seems ok
| /var/db/repos/gentoo/sys-auth/metadata.xml: | <longdescription lang="en">
The sys-auth category contains applications and libraries to support
authentication and authorization facilities.
Here belongs PAM modules, NSS modules and login apps.
</longdescription> |
_________________ Questions are guaranteed in life; Answers aren't. |
|
| Back to top |
|
 |
charles17 Advocate

Joined: 02 Mar 2008 Posts: 3675
|
Posted: Wed Feb 12, 2020 4:52 pm Post subject: |
|
|
So I will keep it in category sys-auth.
Problem with missing libAusweisAppInit.so is it is available here in | /var/tmp/portage/sys-auth/AusweisApp2-1.20.0/work/AusweisApp2-1.20.0_build/src/init/: | ├── AusweisAppInit_autogen
│ ├── EWIEGA46WW
│ │ └── moc_SignalHandler.cpp
│ ├── include
│ ├── moc_predefs.h
│ └── mocs_compilation.cpp
├── CMakeFiles
│ ├── AusweisAppInit_autogen.dir
│ │ ├── AutogenInfo.cmake
│ │ └── AutogenOldSettings.txt
│ └── AusweisAppInit.dir
│ ├── AusweisAppInit_autogen
│ │ └── mocs_compilation.cpp.o
│ ├── Bootstrap.cpp.o
│ ├── CommandLineParser.cpp.o
│ ├── SignalHandler_bsd_linux_osx.cpp.o
│ └── SignalHandler.cpp.o
├── cmake_install.cmake
├── config.h
└── libAusweisAppInit.so |
But it does not get installed to the image. Why?? |
|
| Back to top |
|
 |
fedeliallalinea Administrator


Joined: 08 Mar 2003 Posts: 31082 Location: here
|
Posted: Wed Feb 12, 2020 5:39 pm Post subject: |
|
|
If you don't need shared libraries for other programs you can build program with option -DBUILD_SHARED_LIBS=OFF, I saw it too, the shared libraries are not installed.
So add this in ebuild
| Code: | src_configure() {
local mycmakeargs=( -DBUILD_SHARED_LIBS=OFF )
cmake-utils_src_configure
} |
_________________ Questions are guaranteed in life; Answers aren't. |
|
| Back to top |
|
 |
charles17 Advocate

Joined: 02 Mar 2008 Posts: 3675
|
|
| Back to top |
|
 |
fedeliallalinea Administrator


Joined: 08 Mar 2003 Posts: 31082 Location: here
|
Posted: Wed Feb 12, 2020 6:05 pm Post subject: |
|
|
| charles17 wrote: | | Does it mean that libAusweisAppInit.so would then be integrated in /usr/bin/AusweisApp2 ? |
I think yes.
Arch build program with BUILD_SHARED_LIBS=OFF, or more precisely if you run cmake manually with cmake -DCMAKE_BUILD_TYPE=RELEASE -DCMAKE_INSTALL_PREFIX=/usr .. BUILD_SHARED_LIBS option is set to OFF if you use cmake-utils eclass this option is enable (I don't know why I should I look at cmake-utils.eclass source code) _________________ Questions are guaranteed in life; Answers aren't. |
|
| Back to top |
|
 |
charles17 Advocate

Joined: 02 Mar 2008 Posts: 3675
|
Posted: Wed Feb 12, 2020 6:29 pm Post subject: |
|
|
Added -DBUILD_SHARED_LIBS=OFF | AusweisApp2-1.20.0.ebuild: | # Copyright 2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit cmake-utils
DESCRIPTION="Official authentication app for German ID cards and residence permits"
HOMEPAGE="https://www.ausweisapp.bund.de/"
SRC_URI="https://github.com/Governikus/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="EUPL-1.2"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="doc"
RDEPEND="
dev-qt/qtcore:5
dev-qt/qtconcurrent:5
dev-qt/qtnetwork:5
dev-qt/qtgui:5
dev-qt/qtsvg:5
dev-qt/qtwebsockets:5[qml]
dev-qt/qtquickcontrols2:5
dev-qt/qtwidgets:5
dev-libs/openssl
sys-apps/pcsc-lite"
DEPEND="${RDEPEND}
dev-qt/linguist-tools:5
virtual/pkgconfig
doc? ( app-doc/doxygen )"
src_configure() {
local mycmakeargs=( -DBUILD_SHARED_LIBS=OFF )
cmake-utils_src_configure
|
And finally /usr/bin/AusweisApp2 starts see https://i.imgur.com/HQvr85s.png |
|
| Back to top |
|
 |
fedeliallalinea Administrator


Joined: 08 Mar 2003 Posts: 31082 Location: here
|
Posted: Wed Feb 12, 2020 6:50 pm Post subject: |
|
|
Good . Maybe for openssl use dev-libs/openssl:0= see here for explanation _________________ Questions are guaranteed in life; Answers aren't. |
|
| Back to top |
|
 |
charles17 Advocate

Joined: 02 Mar 2008 Posts: 3675
|
Posted: Wed Feb 12, 2020 7:26 pm Post subject: |
|
|
| Thanks for all your help, fedeliallalinea |
|
| Back to top |
|
 |
mike155 Advocate

Joined: 17 Sep 2010 Posts: 4438 Location: Frankfurt, Germany
|
Posted: Wed Feb 12, 2020 7:37 pm Post subject: |
|
|
Charles17 and fedeliallalinea: thanks for the ebuild!
I tested it and it works.  |
|
| Back to top |
|
 |
charles17 Advocate

Joined: 02 Mar 2008 Posts: 3675
|
Posted: Thu Feb 13, 2020 9:07 am Post subject: |
|
|
| bug 344941 |
|
| Back to top |
|
 |
|