[PATCH] gnu: Add kitsas

  • Done
  • quality assurance status badge
Details
4 participants
  • Ludovic Courtès
  • Maxim Cournoyer
  • Bruno Victal
  • Saku Laesvuori
Owner
unassigned
Submitted by
Saku Laesvuori
Severity
normal
S
S
Saku Laesvuori wrote on 20 Mar 2023 11:56
(address . guix-patches@gnu.org)(name . Saku Laesvuori)(address . saku@laesvuori.fi)
20230320105602.8040-1-saku@laesvuori.fi
* gnu/packages/finance.scm (kitsas): New variable.
---
gnu/packages/finance.scm | 57 ++++++++++++++++++++++++++++++++++++++++
1 file changed, 57 insertions(+)

Toggle diff (79 lines)
diff --git a/gnu/packages/finance.scm b/gnu/packages/finance.scm
index 3f3fc078f0..9c27df04ad 100644
--- a/gnu/packages/finance.scm
+++ b/gnu/packages/finance.scm
@@ -109,6 +109,7 @@ (define-module (gnu packages finance)
#:use-module (gnu packages multiprecision)
#:use-module (gnu packages ncurses)
#:use-module (gnu packages networking)
+ #:use-module (gnu packages pdf)
#:use-module (gnu packages pkg-config)
#:use-module (gnu packages popt)
#:use-module (gnu packages protobuf)
@@ -1290,6 +1291,62 @@ (define-public keepkey-agent
agent.")
(license license:lgpl3)))
+(define-public kitsas
+ (package
+ (name "kitsas")
+ (version "4.0.3")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append
+ "https://github.com/artoh/kitupiikki/archive/refs/tags/v"
+ version ".tar.gz"))
+ (sha256
+ (base32
+ "1a15axggskrvjb3r3yyr3kdxyzcygxjj756b6dzpwlca5g1l7x5w"))))
+ (build-system qt-build-system)
+ (inputs (list qtbase-5 libzip poppler-qt5 qtsvg-5))
+ (arguments
+ '(#:test-target "check"
+ #:tests? #f
+ #:phases (modify-phases %standard-phases
+ (replace 'configure
+ (lambda* _
+ (invoke "qmake" "kitsasproject.pro" "CONFIG+=release")))
+ (replace 'install
+ (lambda* (#:key outputs #:allow-other-keys)
+ (let ((out (assoc-ref outputs "out")))
+ (install-file "kitsas/kitsas"
+ (string-append out "/bin/"))
+ (install-file "kitsas.png"
+ (string-append out "/share/icons/"))
+ (install-file "kitsas.desktop"
+ (string-append out
+ "/share/applications/"))))))))
+ (home-page "https://kitsas.fi")
+ (synopsis "Finnish bookkeeping software for small organisations")
+ (description
+ "The software is in Finnish only.
+
+ Finnish free software accounting program with the following goals and features:
+
+ @itemize @bullet
+ @item
+ Ease of use
+ @item
+ Digital management of documents
+ @item
+ Creating a digital archive
+ @item
+ Built-in invoicing
+ @item
+ Creating reports
+ @end itemize")
+ (license license:gpl3)))
+ ; GPL3 with additional terms:
+ ; - Modified versions of this software should be clearly mentioned as modified
+ ; - Kitsas Oy will not support any modified version of this software
+ ; - The name Kitsas Oy should not be used in any modified version
+
(define-public python-stdnum
(package
(name "python-stdnum")

base-commit: 3a2200e1ad2049ad7e25295e6b4e013f74dd84e2
--
2.39.2
B
B
Bruno Victal wrote on 20 Mar 2023 19:09
(name . Saku Laesvuori)(address . saku@laesvuori.fi)(address . 62292@debbugs.gnu.org)
d295a68e-f294-a967-1c85-062c8d03c017@makinata.eu
Hi Saku,

On 2023-03-20 10:56, Saku Laesvuori via Guix-patches via wrote:
Toggle quote (11 lines)
>
> +(define-public kitsas
> + (package
> + (name "kitsas")
> + (version "4.0.3")
> + (source (origin
> + (method url-fetch)
> + (uri (string-append
> + "https://github.com/artoh/kitupiikki/archive/refs/tags/v"
> + version ".tar.gz"))

Use git-fetch instead.
GitHub tarballs are not stable and their hash can change in the future.

Toggle quote (7 lines)
> + (sha256
> + (base32
> + "1a15axggskrvjb3r3yyr3kdxyzcygxjj756b6dzpwlca5g1l7x5w"))))
> + (build-system qt-build-system)
> + (inputs (list qtbase-5 libzip poppler-qt5 qtsvg-5))
> + (arguments

[...]

Toggle quote (3 lines)
> + '(#:test-target "check"
> + #:tests? #f

If the tests don't work, leave a comment stating such.
It's worth trying to get them working if possible though.

[...]

Toggle quote (15 lines)
> + #:phases (modify-phases %standard-phases
> + (replace 'configure
> + (lambda* _
> + (invoke "qmake" "kitsasproject.pro" "CONFIG+=release")))
> + (replace 'install
> + (lambda* (#:key outputs #:allow-other-keys)
> + (let ((out (assoc-ref outputs "out")))
> + (install-file "kitsas/kitsas"
> + (string-append out "/bin/"))
> + (install-file "kitsas.png"
> + (string-append out "/share/icons/"))
> + (install-file "kitsas.desktop"
> + (string-append out
> + "/share/applications/"))))))))

Prefer list to ' and use G-Expressions here, i.e.

(arguments
(list
#:tests? #f ;; comment here...
#:phases
#~(modify-phases %standard-phases
(replace 'install
(lambda* _
(install-file "kitsas/kitsas" (string-append #$output "/bin/"))
... )))))


Toggle quote (20 lines)
> + (home-page "https://kitsas.fi")
> + (synopsis "Finnish bookkeeping software for small organisations")
> + (description
> + "The software is in Finnish only.
> +
> + Finnish free software accounting program with the following goals and features:
> +
> + @itemize @bullet
> + @item
> + Ease of use
> + @item
> + Digital management of documents
> + @item
> + Creating a digital archive
> + @item
> + Built-in invoicing
> + @item
> + Creating reports
> + @end itemize")

You can collapse this into:

@itemize @bullet
@item Ease of use
@item Digital management of documents
...
@end itemize

Toggle quote (6 lines)
> + (license license:gpl3)))
> + ; GPL3 with additional terms:
> + ; - Modified versions of this software should be clearly mentioned as modified
> + ; - Kitsas Oy will not support any modified version of this software
> + ; - The name Kitsas Oy should not be used in any modified version

Move this comment into the package definition.


Cheers,
Bruno
M
M
Maxim Cournoyer wrote on 22 Mar 2023 13:29
control message for bug #62292
(address . control@debbugs.gnu.org)
87cz51hsub.fsf@gmail.com
tags 62292 + moreinfo
quit
S
S
Saku Laesvuori wrote on 22 Mar 2023 13:54
[PATCH v2] gnu: Add kitsas
(address . 62292@debbugs.gnu.org)
20230322125443.6561-1-saku@laesvuori.fi
* gnu/packages/finance.scm (kitsas): New variable.
---
gnu/packages/finance.scm | 49 ++++++++++++++++++++++++++++++++++++++++
1 file changed, 49 insertions(+)

Toggle diff (71 lines)
diff --git a/gnu/packages/finance.scm b/gnu/packages/finance.scm
index 3f3fc078f0..a4b7ede62a 100644
--- a/gnu/packages/finance.scm
+++ b/gnu/packages/finance.scm
@@ -109,6 +109,7 @@ (define-module (gnu packages finance)
#:use-module (gnu packages multiprecision)
#:use-module (gnu packages ncurses)
#:use-module (gnu packages networking)
+ #:use-module (gnu packages pdf)
#:use-module (gnu packages pkg-config)
#:use-module (gnu packages popt)
#:use-module (gnu packages protobuf)
@@ -1290,6 +1291,54 @@ (define-public keepkey-agent
agent.")
(license license:lgpl3)))
+(define-public kitsas
+ (package
+ (name "kitsas")
+ (version "4.0.3")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/artoh/kitupiikki")
+ (commit (string-append "v" version))))
+ (sha256
+ (base32
+ "0hrbsqqm6v2pmjq17s7i4akjgclz3d051mg02vcykq80xgxvbkgf"))))
+ (build-system qt-build-system)
+ (inputs (list qtbase-5 libzip poppler-qt5 qtsvg-5))
+ (arguments
+ (list
+ ; Some tests fail and others segfault
+ #:tests #f
+ #:test-target "check"
+ #:phases #~(modify-phases %standard-phases
+ (replace 'configure
+ (lambda* _
+ (invoke "qmake" "kitsasproject.pro" "CONFIG+=release")))
+ (replace 'install
+ (lambda* _
+ (install-file "kitsas/kitsas" (string-append #$output "/bin/"))
+ (install-file "kitsas.png" (string-append #$output "/share/icons/"))
+ (install-file "kitsas.desktop" (string-append #$output "/share/applications/")))))))
+ (home-page "https://kitsas.fi")
+ (synopsis "Finnish bookkeeping software for small organisations")
+ (description
+ "The software is in Finnish only.
+
+ Finnish free software accounting program with the following goals and features:
+
+ @itemize @bullet
+ @item Ease of use
+ @item Digital management of documents
+ @item Creating a digital archive
+ @item Built-in invoicing
+ @item Creating reports
+ @end itemize")
+ ; GPL3 with additional terms:
+ ; - Modified versions of this software should be clearly mentioned as modified
+ ; - Kitsas Oy will not support any modified version of this software
+ ; - The name Kitsas Oy should not be used in any modified version
+ (license license:gpl3)))
+
(define-public python-stdnum
(package
(name "python-stdnum")

base-commit: 3a2200e1ad2049ad7e25295e6b4e013f74dd84e2
--
2.39.2
L
L
Ludovic Courtès wrote on 17 Apr 2023 23:29
Re: bug#62292: [PATCH] gnu: Add kitsas
(name . Saku Laesvuori)(address . saku@laesvuori.fi)
87wn2ab3ku.fsf_-_@gnu.org
Hi Saku,

Saku Laesvuori <saku@laesvuori.fi> skribis:

Toggle quote (2 lines)
> * gnu/packages/finance.scm (kitsas): New variable.

Thanks for the updated patch. I went ahead and applied it with the
changes below (the license is ‘gpl3+’ because the ‘LICENSE’ file
explicitly says “version 3 or any later version”).

The test failures are worrisome though. Could you investigate why those
tests are failing or crashing?

Those failures may indicate real issues. Or it could be that they
require a running X server (other packages usually solve that by
spawning ‘Xvfb’ right before the ‘check’ phase).

Thank you, and thanks Bruno for reviewing.

Ludo’.
Closed
S
S
Saku Laesvuori wrote on 18 Apr 2023 16:51
(name . Ludovic Courtès)(address . ludo@gnu.org)
20230418145159.gkrlxcyyghpfnpxi@X-kone
Toggle quote (7 lines)
> The test failures are worrisome though. Could you investigate why those
> tests are failing or crashing?
>
> Those failures may indicate real issues. Or it could be that they
> require a running X server (other packages usually solve that by
> spawning ‘Xvfb’ right before the ‘check’ phase).

The tests also fail on an Arch linux machine with a running X server. I
tried removing the failing ones, but that caused some of the previously
passing ones to start segfaulting, so I have no idea how to fix them
properly.

- Saku
-----BEGIN PGP SIGNATURE-----

iQIzBAABCAAdFiEEoMkZR3NPB29fCOn/JX0oSiodOjIFAmQ+ro8ACgkQJX0oSiod
OjJQsQ/+MeUdfUQm5VZgxxrnzrVjL4WcCQu7Zvhf8bfgXglBWyZrUpz9U7BOPEvB
4nxsRKrzU5nJfzlV0Rzsy0xBh7loV0kl59Nt0tqs5LS9Me38HO2/sXuya+P1pIsT
kP3cjjnsTfGI8lDVYPMXIV9LK0rv5gMDU5BMlpa4C0eIiHZAHdQ71enAhRL0E2Tw
BWZfZN5AzwmlgM9xbrk/dfCwd06j3E2rO6uX3HktGOsrtxdAQ2m/zd4JHnnARrHH
hIZ1rLDC9Tyyu0EQBPU6aAJrgd5gYSdQc7BdFNdsOMGPoAk2f7C0ZJ6WK6uopFEC
0qtnaVuBF9x3zbD7tOiPrq76V3Ziw3MGOF7i61kuBOksgrZil99HOLN+IdAxQbSF
v5CigmRbfwAoRP+eHI69lsZWOcXNe50/ObwmFa+Oen5VxLIxSeEXVa8wXzH+gnb2
7owRR3bnFYc+6IgBYdaM+OOcYDrYte7/1QQGinVpSqMhhDQRKwG0AT51BK1pH4BQ
fBX9MrGNmgxDWs12KDeK2Wi7J9O3nCO234X//R2xFh7+zXg0YgJU8MYOi6pCxPjb
CFo9BDghrz287wVyQ0jwrQNN1/+w/dF8Yjln6rywqrFg7xWtQ1RVx0YQEcCkQd+y
tLnfhHB6oc+6L/cSP4aPRMpJ2/yEL9MIhHfd605ROyF2m0H58NA=
=e60H
-----END PGP SIGNATURE-----


Closed
L
L
Ludovic Courtès wrote on 20 Apr 2023 12:30
(name . Saku Laesvuori)(address . saku@laesvuori.fi)
87cz3yvoa1.fsf@gnu.org
Saku Laesvuori <saku@laesvuori.fi> skribis:

Toggle quote (12 lines)
>> The test failures are worrisome though. Could you investigate why those
>> tests are failing or crashing?
>>
>> Those failures may indicate real issues. Or it could be that they
>> require a running X server (other packages usually solve that by
>> spawning ‘Xvfb’ right before the ‘check’ phase).
>
> The tests also fail on an Arch linux machine with a running X server. I
> tried removing the failing ones, but that caused some of the previously
> passing ones to start segfaulting, so I have no idea how to fix them
> properly.

OK. Could you report it upstream?

Thanks,
Ludo’.
Closed
S
S
Saku Laesvuori wrote on 20 Apr 2023 13:38
(name . Ludovic Courtès)(address . ludo@gnu.org)
20230420113812.np2jslq2dv4muqs6@X-kone
Toggle quote (14 lines)
> >> The test failures are worrisome though. Could you investigate why those
> >> tests are failing or crashing?
> >>
> >> Those failures may indicate real issues. Or it could be that they
> >> require a running X server (other packages usually solve that by
> >> spawning ‘Xvfb’ right before the ‘check’ phase).
> >
> > The tests also fail on an Arch linux machine with a running X server. I
> > tried removing the failing ones, but that caused some of the previously
> > passing ones to start segfaulting, so I have no idea how to fix them
> > properly.
>
> OK. Could you report it upstream?

I'll send the maintainer an email as their issue tracker is on Github
and I'd prefer not registering an account there.
-----BEGIN PGP SIGNATURE-----

iQIzBAABCAAdFiEEoMkZR3NPB29fCOn/JX0oSiodOjIFAmRBJCQACgkQJX0oSiod
OjIOZBAAleF/xFmbvYsRE+QcV/+lijz163rD/DYThZllaDgHGWvVUITuB3+YE3Fr
ZYQP36w/PhIQRHzKE0OcvqaSYBf1mQOGOqUJD1i0qpURuX3dqNNzlPO1BnsVHWAn
xyXkLFNUiwHMgWeZpUCl8lShXsBBZNCvM8h2Wk24+IP/WECh+0edJJgR3hfQBa7e
HiashPFnXkqAUYihJENqfWt0t5LJBuWahkPoLQIZ66Yg6PYvCX9Lu1pmHb/Un7pi
4G46v0kT9iXRkVvjPmWMCy9zPezv3hKvXUYEnY6amz1pLUh4jipnV8U/U15oMMTj
z4RU8NzqV4HiX/56yfgH8wu+//jlemf8fzdMiR9hnAfNXJrCD19F/NBi9wWqw3uM
QqtQZCMChrxSGt6saqiP/TK2otit1p/hdhM0HahRXmyrlboCjfhRpgZW7114VJJp
ArjFzKaS88s3juqYqb0Yx4Eo6B7razrVrnAns0qVnvvayLBPwlfHexbF+ki0yTgs
DcCsMZpXUuKGaHJotHXA+tXnL5gAX0KmprSHDmlKc13La3JaDhLXzUXre3FiqvoV
nfgB0Cfih7VUlNpoAFFCZFf8Kpw78EEz15A5ZD9NgoyPlvZE6QrW1NoRxA7Wcl/5
vE2c8Ev0y65RCTyN8fX6aeNRmhukmie7VqSBLdyrmJe/YrPQvIA=
=Beag
-----END PGP SIGNATURE-----


Closed
S
S
Saku Laesvuori wrote on 20 Apr 2023 14:37
(name . Ludovic Courtès)(address . ludo@gnu.org)
20230420123703.6z25ifbu3blqumoh@X-kone
On Thu, Apr 20, 2023 at 02:38:14PM +0300, Saku Laesvuori wrote:
Toggle quote (17 lines)
> > >> The test failures are worrisome though. Could you investigate why those
> > >> tests are failing or crashing?
> > >>
> > >> Those failures may indicate real issues. Or it could be that they
> > >> require a running X server (other packages usually solve that by
> > >> spawning ‘Xvfb’ right before the ‘check’ phase).
> > >
> > > The tests also fail on an Arch linux machine with a running X server. I
> > > tried removing the failing ones, but that caused some of the previously
> > > passing ones to start segfaulting, so I have no idea how to fix them
> > > properly.
> >
> > OK. Could you report it upstream?
>
> I'll send the maintainer an email as their issue tracker is on Github
> and I'd prefer not registering an account there.

Apparently the tests haven't been kept up to date with Qt and may get
fixed when Kitsas is updated to Qt 6.
-----BEGIN PGP SIGNATURE-----

iQIzBAABCAAdFiEEoMkZR3NPB29fCOn/JX0oSiodOjIFAmRBMe8ACgkQJX0oSiod
OjJp9hAAs9Or4yJgxrph9lCsU0/VVpwupHanURNDJjqb7O4Q+7cuFnUf/cEoF2uR
cZEHgsL5ZFqxasRiOWYiX9pMj8LAJz+sAkUeZOcd0jqosNSOWbWDAuK7Wqxg5Aw5
V5y5KffCP6io6Lqb8hgJbIBtC4+oeUcgV7Rubw97bhuIuKnCVa9qcGkovk2Z1y9m
IWQK3cc2U/mFEqG0B6C68UzWU56af78sFcl6Bd4+JZ483EMA6RUQU0OtWdim2uAg
tEW5ddOc0iw7BvyTeFV3ZKdXd6gaOvgW1w6aytPEGuRGOKbBTjiAL8hEcEF0GRkn
LrYAsvDm4UBUtHYfDGYUtslLEQ7rXfQyDb7sU4Ibv2AYcWqOpf0T6HnPq8Ne+WwA
vFHXrIVMPOzyaFKjfPZ0QqC21ZDFr4YchY47NfU/b4X3k7sT7AL2O7JKulCnLT/l
Ka53ve9lhfVbcvgxhMqZWyiBFRCChUlE70uTuAJjOxePsaN8hgxDlGQLhINt1oeT
zcISPcycZIijrRrJtw/zVtY9kky2+3BjaXniGSafdBXOqKZ13SeVDNbSCrIvEPtd
yDx3p37P35ZleChfVHB2BAoo22UJmRS54RqEuL++nUtzCSvkj4Lz63yDi7SGw/Oq
GaeGMT2CG+OPN5gUr6xyzPGb5hXsr3ZJnOAIvNIsmHzW86Gb1y4=
=f62N
-----END PGP SIGNATURE-----


Closed
?