From: "Alfredo Tupone" <tupone@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: www-apps/liquid_feedback_core/files/, www-apps/liquid_feedback_core/
Date: Sat, 10 Apr 2021 18:39:08 +0000 (UTC) [thread overview]
Message-ID: <1618079936.7a6e7bdea0fbadbb6a05609271eca7d8a680136e.tupone@gentoo> (raw)
commit: 7a6e7bdea0fbadbb6a05609271eca7d8a680136e
Author: Alfredo Tupone <tupone <AT> gentoo <DOT> org>
AuthorDate: Sat Apr 10 18:38:56 2021 +0000
Commit: Alfredo Tupone <tupone <AT> gentoo <DOT> org>
CommitDate: Sat Apr 10 18:38:56 2021 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7a6e7bde
www-apps/liquid_feedback_core: bump to 3.2.2
Package-Manager: Portage-3.0.13, Repoman-3.0.2
Signed-off-by: Alfredo Tupone <tupone <AT> gentoo.org>
www-apps/liquid_feedback_core/Manifest | 1 +
.../files/liquid_feedback_core-3.2.2-gentoo.patch | 51 ++++++++++++++++++++++
.../liquid_feedback_core/files/postinstall-en.txt | 17 +++-----
.../liquid_feedback_core-3.2.2.ebuild | 42 ++++++++++++++++++
4 files changed, 101 insertions(+), 10 deletions(-)
diff --git a/www-apps/liquid_feedback_core/Manifest b/www-apps/liquid_feedback_core/Manifest
index 39220e88882..11e79310b42 100644
--- a/www-apps/liquid_feedback_core/Manifest
+++ b/www-apps/liquid_feedback_core/Manifest
@@ -1,2 +1,3 @@
DIST liquid_feedback_core-v2.2.6.tar.gz 127440 BLAKE2B d62ecd8c9947259a7213f92ecaf1491a5e858ff2fdaff5e020fc4ec0c433297d8a7701a812de200130a1ed7f08ded1d9f31d42de7fffa2981361efee0e31646c SHA512 6f680398a7d2e529e642dc94ba16bc1b33d25459ddbf629c06387391ef13c0e212a108cc337cd2bc29505f4f6436b6e92994e63eaa09fe1c07733d2821d9b7f1
DIST liquid_feedback_core-v3.0.4.tar.gz 142983 BLAKE2B 05e8c1630a8fa3932b4fc291843dd0c45e2333940394a0632309c9041dc850cc894a6cb54fb840329f67812ebcde5d540c338cf27a88ad428aaa066329725409 SHA512 baea8a61c94e640557d0169b6171247ff0303ff1a9c8b587c6769e367cf56805c1a1e660aadf7178d984182be6dde326770240b3ffeda42139c4a94445a2bbf8
+DIST liquid_feedback_core-v3.2.2.tar.gz 162505 BLAKE2B dc6e9d0b8d1e596150520e068e7743a6e839f7e6ffc3c605d090973a179652858c037c4f12c75774d158adfc60484d1ac321350fa7f8d16329043051ae2cd98c SHA512 60a3548008235822e83c6614e990d87200b342d8e5c5fd1ca1f6092bc48d918f9dbfcc130039f4acf2956a19100cc96187ac1c7f5174f7e69a45f651643ab1d9
diff --git a/www-apps/liquid_feedback_core/files/liquid_feedback_core-3.2.2-gentoo.patch b/www-apps/liquid_feedback_core/files/liquid_feedback_core-3.2.2-gentoo.patch
new file mode 100644
index 00000000000..541464723f8
--- /dev/null
+++ b/www-apps/liquid_feedback_core/files/liquid_feedback_core-3.2.2-gentoo.patch
@@ -0,0 +1,51 @@
+--- a/lf_update_issue_order.c 2021-04-10 18:32:19.101947834 +0200
++++ b/lf_update_issue_order.c 2021-04-10 18:36:07.377117090 +0200
+@@ -1,3 +1,5 @@
++#define _GNU_SOURCE
++
+ #include <stdlib.h>
+ #include <stdio.h>
+ #include <string.h>
+@@ -417,7 +419,7 @@
+ logging = 1;
+ }
+ for (i=argb; i<argc; i++) len += strlen(argv[i]) + 1;
+- conninfo = malloc(len * sizeof(char));
++ conninfo = malloc(len * sizeof(char) + 1);
+ if (!conninfo) {
+ fprintf(stderr, "Error: Could not allocate memory for conninfo string.\n");
+ abort();
+--- a/lf_update_suggestion_order.c 2021-04-10 18:38:31.138743181 +0200
++++ b/lf_update_suggestion_order.c 2021-04-10 18:39:29.851786017 +0200
+@@ -1,3 +1,5 @@
++#define _GNU_SOURCE
++
+ #include <stdlib.h>
+ #include <stdio.h>
+ #include <string.h>
+@@ -474,7 +476,7 @@
+ logging = 1;
+ }
+ for (i=argb; i<argc; i++) len += strlen(argv[i]) + 1;
+- conninfo = malloc(len * sizeof(char));
++ conninfo = malloc(len * sizeof(char) + 1);
+ if (!conninfo) {
+ fprintf(stderr, "Error: Could not allocate memory for conninfo string.\n");
+ abort();
+--- a/lf_update.c 2021-04-10 18:40:48.036510216 +0200
++++ b/lf_update.c 2021-04-10 18:55:46.869758233 +0200
+@@ -1,3 +1,5 @@
++#define _GNU_SOURCE
++
+ #include <stdlib.h>
+ #include <stdio.h>
+ #include <string.h>
+@@ -51,7 +53,7 @@
+ {
+ size_t len = 0;
+ for (i=1; i<argc; i++) len += strlen(argv[i]) + 1;
+- conninfo = malloc(len * sizeof(char));
++ conninfo = malloc(len * sizeof(char) + 1);
+ if (!conninfo) {
+ fprintf(stderr, "Error: Could not allocate memory for conninfo string\n");
+ return 1;
diff --git a/www-apps/liquid_feedback_core/files/postinstall-en.txt b/www-apps/liquid_feedback_core/files/postinstall-en.txt
index 128c7b20ee7..e1eb550eeea 100644
--- a/www-apps/liquid_feedback_core/files/postinstall-en.txt
+++ b/www-apps/liquid_feedback_core/files/postinstall-en.txt
@@ -1,25 +1,22 @@
-Merge info from README file with these.
-
To use Liquid Feedback you have to follow these
simple steps, which have to be done as the postgres system user (or
which ever is the database superuser):
-$ createuser liquid_feedback
-and answer the following
-Shall the new role be a superuser? (y/n) n
-Shall the new role be allowed to create databases? (y/n) y
-Shall the new role be allowed to create more new roles? (y/n) n
+$ createuser -d liquid_feedback
$ psql
postgres=# ALTER USER liquid_feedback WITH PASSWORD 'the_new_password';
$ createdb -U liquid_feedback liquid_feedback
$ psql -U liquid_feedback liquid_feedback
-liquid_feedback=# \i /usr/share/liquid_feedback_code/core.sql
-liquid_feedback=# \i /usr/share/liquid_feedback_code/init.sql
+liquid_feedback=# \i /usr/share/liquid_feedback_core/core.sql
INSERT INTO system_setting (member_ttl) VALUES ('1 year');
INSERT INTO contingent (polling, time_frame, text_entry_limit, initiative_limit) VALUES (false, '1 hour', 20, 6);
INSERT INTO contingent (polling, time_frame, text_entry_limit, initiative_limit) VALUES (false, '1 day', 80, 12);
INSERT INTO contingent (polling, time_frame, text_entry_limit, initiative_limit) VALUES (true, '1 hour', 200, 60);
INSERT INTO contingent (polling, time_frame, text_entry_limit, initiative_limit) VALUES (true, '1 day', 800, 120);
-INSERT INTO policy (index, name, admission_time, discussion_time, verification_time, voting_time, issue_quorum_num, issue_quorum_den, initiative_quorum_num, initiative_quorum_den) VALUES (1, 'Default policy', '8 days', '15 days', '8 days', '15 days', 10, 100, 10, 100);
+
+and Create an invite code for an admin user:
+
+$ psql -U liquid_feedback liquid_feedback
+liquid_feedback=# INSERT INTO member (invite_code, admin) VALUES ('sesam', true);
diff --git a/www-apps/liquid_feedback_core/liquid_feedback_core-3.2.2.ebuild b/www-apps/liquid_feedback_core/liquid_feedback_core-3.2.2.ebuild
new file mode 100644
index 00000000000..13d55279376
--- /dev/null
+++ b/www-apps/liquid_feedback_core/liquid_feedback_core-3.2.2.ebuild
@@ -0,0 +1,42 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit toolchain-funcs
+
+MY_P=${PN}-v${PV}
+
+DESCRIPTION="Internet platforms for proposition development and decision making"
+HOMEPAGE="https://www.public-software-group.org/liquid_feedback"
+SRC_URI="https://www.public-software-group.org/pub/projects/liquid_feedback/backend/v${PV}/${MY_P}.tar.gz"
+
+LICENSE="HPND CC-BY-2.5"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE=""
+
+RDEPEND="dev-db/postgresql:="
+DEPEND="${RDEPEND}"
+
+S=${WORKDIR}/${MY_P}
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-3.0.4-gentoo.patch
+ "${FILESDIR}"/${P}-gentoo.patch
+)
+
+src_compile() {
+ emake \
+ CC="$(tc-getCC)" \
+ CFLAGS="${CFLAGS}" \
+ CPPFLAGS="-I $(pg_config --includedir)" \
+ LDFLAGS="${LDFLAGS} -L $(pg_config --libdir)"
+}
+
+src_install() {
+ dobin lf_update lf_update_suggestion_order lf_export
+ insinto /usr/share/${PN}
+ doins -r {core,init,demo,test}.sql update
+ dodoc README "${FILESDIR}"/postinstall-en.txt
+}
next reply other threads:[~2021-04-10 18:39 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-04-10 18:39 Alfredo Tupone [this message]
-- strict thread matches above, loose matches on Subject: below --
2024-01-25 11:04 [gentoo-commits] repo/gentoo:master commit in: www-apps/liquid_feedback_core/files/, www-apps/liquid_feedback_core/ Alfredo Tupone
2024-02-16 17:40 Alfredo Tupone
2024-02-20 7:33 Alfredo Tupone
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1618079936.7a6e7bdea0fbadbb6a05609271eca7d8a680136e.tupone@gentoo \
--to=tupone@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox