* [gentoo-commits] repo/gentoo:master commit in: app-misc/abook/files/
@ 2017-09-02 15:15 Michael Palimaka
0 siblings, 0 replies; 3+ messages in thread
From: Michael Palimaka @ 2017-09-02 15:15 UTC (permalink / raw
To: gentoo-commits
commit: b99131d4b4f58921e7db75f145a53e0a17b3c57b
Author: Michael Mair-Keimberger (asterix) <m.mairkeimberger <AT> gmail <DOT> com>
AuthorDate: Wed Aug 16 09:04:23 2017 +0000
Commit: Michael Palimaka <kensington <AT> gentoo <DOT> org>
CommitDate: Sat Sep 2 15:15:29 2017 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b99131d4
app-misc/abook: remove unused patches
.../abook/files/abook-0.6.0_pre2-vcard-fix.patch | 10 -
.../files/abook-0.6.0_pre2-vcard-import.patch | 325 ---------------------
2 files changed, 335 deletions(-)
diff --git a/app-misc/abook/files/abook-0.6.0_pre2-vcard-fix.patch b/app-misc/abook/files/abook-0.6.0_pre2-vcard-fix.patch
deleted file mode 100644
index 8045909463a..00000000000
--- a/app-misc/abook/files/abook-0.6.0_pre2-vcard-fix.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- abook-0.6.0pre2/abook.c.orig 2010-10-03 14:54:23.827767178 -0700
-+++ abook-0.6.0pre2/abook.c 2010-10-03 14:54:55.738042419 -0700
-@@ -708,6 +708,7 @@
- check_abook_directory();
- init_opts();
- load_opts(rcfile);
-+ init_standard_fields();
- atexit(free_opts);
-
- /*
diff --git a/app-misc/abook/files/abook-0.6.0_pre2-vcard-import.patch b/app-misc/abook/files/abook-0.6.0_pre2-vcard-import.patch
deleted file mode 100644
index 316f1229fd9..00000000000
--- a/app-misc/abook/files/abook-0.6.0_pre2-vcard-import.patch
+++ /dev/null
@@ -1,325 +0,0 @@
-diff -ru a/filter.c b/filter.c
---- a/filter.c 2006-09-06 07:26:10.000000000 +0200
-+++ b/filter.c 2008-05-18 20:55:12.000000000 +0200
-@@ -44,6 +44,7 @@
- static int csv_parse_file(FILE *in);
- static int allcsv_parse_file(FILE *in);
- static int palmcsv_parse_file(FILE *in);
-+static int vcard_parse_file(FILE *in);
-
- /*
- * export filter prototypes
-@@ -75,6 +76,7 @@
- { "csv", N_("comma separated values"), csv_parse_file },
- { "allcsv", N_("comma separated values (all fields)"), allcsv_parse_file },
- { "palmcsv", N_("Palm comma separated values"), palmcsv_parse_file },
-+ { "vcard", N_("vCard file"), vcard_parse_file },
- { "\0", NULL, NULL }
- };
-
-@@ -1331,6 +1333,262 @@
- */
-
- /*
-+ * vCard import filter
-+ */
-+
-+static char *vcard_fields[] = {
-+ "FN", /* NAME */
-+ "EMAIL", /* EMAIL */
-+ "ADR", /* ADDRESS */
-+ "ADR", /* ADDRESS2 - not used */
-+ "ADR", /* CITY */
-+ "ADR", /* STATE */
-+ "ADR", /* ZIP */
-+ "ADR", /* COUNTRY */
-+ "TEL", /* PHONE */
-+ "TEL", /* WORKPHONE */
-+ "TEL", /* FAX */
-+ "TEL", /* MOBILEPHONE */
-+ "NICKNAME", /* NICK */
-+ "URL", /* URL */
-+ "NOTE", /* NOTES */
-+ NULL /* not implemented: ANNIVERSARY, ITEM_FIELDS */
-+};
-+
-+/*
-+ * mappings between vCard ADR field and abook's ADDRESS
-+ * see rfc2426 section 3.2.1
-+ */
-+static int vcard_address_fields[] = {
-+ -1, /* vCard(post office box) - not used */
-+ -1, /* vCard(the extended address) - not used */
-+ 2, /* vCard(the street address) - ADDRESS */
-+ 4, /* vCard(the locality) - CITY */
-+ 5, /* vCard(the region) - STATE */
-+ 6, /* vCard(the postal code) - ZIP */
-+ 7 /* vCard(the country name) - COUNTRY */
-+};
-+
-+enum {
-+ VCARD_KEY = 0,
-+ VCARD_KEY_ATTRIBUTE,
-+ VCARD_VALUE,
-+};
-+
-+static char *
-+vcard_get_line_element(char *line, int element)
-+{
-+ int i;
-+ char *line_copy = 0;
-+ char *result = 0;
-+ char *key = 0;
-+ char *key_attr = 0;
-+ char *value = 0;
-+
-+ line_copy = xstrdup(line);
-+
-+ /* make newline characters if exist end of string */
-+ for(i=0; line_copy[i]; i++) {
-+ if(line_copy[i] == '\r' || line_copy[i] == '\n') {
-+ line_copy[i] = '\0';
-+ break;
-+ }
-+ }
-+
-+ /* separate key from value */
-+ for(i=0; line_copy[i]; i++) {
-+ if(line_copy[i] == ':') {
-+ line_copy[i] = '\0';
-+ key = line_copy;
-+ value = &line_copy[i+1];
-+ break;
-+ }
-+ }
-+
-+ /* separate key from key attributes */
-+ if (key) {
-+ for(i=0; key[i]; i++) {
-+ if(key[i] == ';') {
-+ key[i] = '\0';
-+ key_attr = &key[i+1];
-+ break;
-+ }
-+ }
-+ }
-+
-+ switch(element) {
-+ case VCARD_KEY:
-+ if(key)
-+ result = xstrdup(key);
-+ break;
-+ case VCARD_KEY_ATTRIBUTE:
-+ if(key_attr)
-+ result = xstrdup(key_attr);
-+ break;
-+ case VCARD_VALUE:
-+ if(value)
-+ result = xstrdup(value);
-+ break;
-+ }
-+
-+ xfree(line_copy);
-+ return result;
-+}
-+
-+static void
-+vcard_parse_email(list_item item, char *line)
-+{
-+ char *email;
-+
-+ email = vcard_get_line_element(line, VCARD_VALUE);
-+
-+ if(item[1]) {
-+ item[1] = strconcat(item[1], ",", email, 0);
-+ xfree(email);
-+ }
-+ else {
-+ item[1] = email;
-+ }
-+}
-+
-+static void
-+vcard_parse_address(list_item item, char *line)
-+{
-+ int i;
-+ int k;
-+ char *value;
-+ char *address_field;
-+
-+ value = vcard_get_line_element(line, VCARD_VALUE);
-+ if(!value)
-+ return;
-+
-+ address_field = value;
-+ for(i=k=0; value[i]; i++) {
-+ if(value[i] == ';') {
-+ value[i] = '\0';
-+ if(vcard_address_fields[k] >= 0) {
-+ item[vcard_address_fields[k]] = xstrdup(address_field);
-+ }
-+ address_field = &value[i+1];
-+ k++;
-+ if((k+1)==(sizeof(vcard_address_fields)/sizeof(*vcard_address_fields)))
-+ break;
-+ }
-+ }
-+ item[vcard_address_fields[k]] = xstrdup(address_field);
-+ xfree(value);
-+}
-+
-+static void
-+vcard_parse_phone(list_item item, char *line)
-+{
-+ int index = 8;
-+ char *type = vcard_get_line_element(line, VCARD_KEY_ATTRIBUTE);
-+ char *value = vcard_get_line_element(line, VCARD_VALUE);
-+
-+ /* set the standard number */
-+ if (!type) {
-+ item[index] = value;
-+ }
-+
-+ /*
-+ * see rfc2426 section 3.3.1
-+ */
-+ else if (strstr(type, "TYPE=") == type){
-+ if (strcasestr(type, "home")) {
-+ item[index] = xstrdup(value);
-+ }
-+ if (strcasestr(type, "work")) {
-+ item[index+1] = xstrdup(value);
-+ }
-+ if (strcasestr(type, "fax")) {
-+ item[index+2] = xstrdup(value);
-+ }
-+ if (strcasestr(type, "cell")) {
-+ item[index+3] = xstrdup(value);
-+ }
-+
-+ xfree(type);
-+ xfree(value);
-+ }
-+}
-+
-+static void
-+vcard_parse_line(list_item item, char *line)
-+{
-+ int i;
-+ char *key;
-+
-+ for(i=0; vcard_fields[i]; i++) {
-+ key = vcard_fields[i];
-+
-+ if(!strncmp(key, line, strlen(key))) {
-+ if(i == 1) {
-+ vcard_parse_email(item, line);
-+ }
-+ else if(i == 2) {
-+ vcard_parse_address(item, line);
-+ }
-+ else if(i == 8) {
-+ vcard_parse_phone(item, line);
-+ }
-+ else {
-+ item[i] = vcard_get_line_element(line, VCARD_VALUE);
-+ }
-+ break;
-+ }
-+ }
-+}
-+
-+static void
-+vcard_parse_item(FILE *in)
-+{
-+ char *line = NULL;
-+ list_item item = item_create();
-+
-+ while(!feof(in)) {
-+ line = getaline(in);
-+
-+ if(line && !strncmp("END:VCARD", line, 9)) {
-+ xfree(line);
-+ break;
-+ }
-+ else if(line) {
-+ vcard_parse_line(item, line);
-+ xfree(line);
-+ }
-+ }
-+
-+ add_item2database(item);
-+ item_free(&item);
-+}
-+
-+static int
-+vcard_parse_file(FILE *in)
-+{
-+ char *line = NULL;
-+
-+ while(!feof(in)) {
-+ line = getaline(in);
-+
-+ if(line && !strncmp("BEGIN:VCARD", line, 11)) {
-+ xfree(line);
-+ vcard_parse_item(in);
-+ }
-+ else if(line) {
-+ xfree(line);
-+ }
-+ }
-+
-+ return 0;
-+}
-+
-+/*
-+ * end of vCard import filter
-+ */
-+
-+/*
- * csv addressbook export filters
- */
-
-diff -ru a/misc.c b/misc.c
---- a/misc.c 2006-09-04 21:24:18.000000000 +0200
-+++ b/misc.c 2008-05-18 18:00:33.000000000 +0200
-@@ -77,6 +77,27 @@
- return 1;
- }
-
-+char *
-+strcasestr(char *haystack, char *needle)
-+{
-+ int i;
-+ int k;
-+
-+ assert(haystack != NULL);
-+ assert(needle != NULL);
-+
-+ for(i=0; i<strlen(haystack)-strlen(needle)+1; i++) {
-+ for(k=0; k<strlen(needle); k++, i++) {
-+ if (tolower(haystack[i]) != tolower(needle[k]))
-+ break;
-+ else if ((k+1) == strlen(needle))
-+ return &haystack[i];
-+ }
-+ }
-+
-+ return NULL;
-+}
-+
-
- #ifdef HAVE_CONFIG_H
- # include "config.h"
-diff -ru a/misc.h b/misc.h
---- a/misc.h 2006-09-04 21:24:18.000000000 +0200
-+++ b/misc.h 2008-05-18 17:55:59.000000000 +0200
-@@ -18,6 +18,8 @@
-
- int is_number(char *s);
-
-+char *strcasestr(char *haystack, char *needle);
-+
- char *strdup_printf(const char *format, ... );
- char *strconcat(const char *str, ...);
-
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-misc/abook/files/
@ 2021-07-17 16:02 Cédric Krier
0 siblings, 0 replies; 3+ messages in thread
From: Cédric Krier @ 2021-07-17 16:02 UTC (permalink / raw
To: gentoo-commits
commit: 181f23e3460b37bb9d6142614e51abaf2b450d91
Author: Cédric Krier <cedk <AT> gentoo <DOT> org>
AuthorDate: Wed Jul 14 14:46:50 2021 +0000
Commit: Cédric Krier <cedk <AT> gentoo <DOT> org>
CommitDate: Sat Jul 17 16:02:32 2021 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=181f23e3
app-misc/abook: Restore link to ncursesw
Package-Manager: Portage-3.0.20, Repoman-3.0.2
Signed-off-by: Cédric Krier <cedk <AT> gentoo.org>
.../abook/files/abook-0.6.1-use-PKG_CHECK_MODULES-for-ncurses.patch | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app-misc/abook/files/abook-0.6.1-use-PKG_CHECK_MODULES-for-ncurses.patch b/app-misc/abook/files/abook-0.6.1-use-PKG_CHECK_MODULES-for-ncurses.patch
index e6f98906af3..00b8e444904 100644
--- a/app-misc/abook/files/abook-0.6.1-use-PKG_CHECK_MODULES-for-ncurses.patch
+++ b/app-misc/abook/files/abook-0.6.1-use-PKG_CHECK_MODULES-for-ncurses.patch
@@ -34,7 +34,7 @@ We don't _always_ have split tinfo, e.g. Prefix.
- AC_CHECK_HEADERS(ncurses.h)],
- [CF_CURSES_LIBS])
- ])
-+PKG_CHECK_MODULES(ncurses, ncurses)
++PKG_CHECK_MODULES(ncurses, [ncursesw ncurses])
+LDFLAGS="${ncurses_LIBS} $LDFLAGS"
+CPPFLAGS="${ncurses_CFLAGS} $CPPFLAGS"
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-misc/abook/files/
@ 2021-07-31 3:25 Sam James
0 siblings, 0 replies; 3+ messages in thread
From: Sam James @ 2021-07-31 3:25 UTC (permalink / raw
To: gentoo-commits
commit: 64dba3109dd18f5a239f63579b12a4d1b17a1c2e
Author: Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Sat Jul 31 02:23:50 2021 +0000
Commit: Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Sat Jul 31 03:25:35 2021 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=64dba310
app-misc/abook: fix linking order for ncurses
Closes: https://bugs.gentoo.org/803155
Signed-off-by: Sam James <sam <AT> gentoo.org>
...k-0.6.1-use-PKG_CHECK_MODULES-for-ncurses.patch | 34 ++++++++++++++++++----
1 file changed, 29 insertions(+), 5 deletions(-)
diff --git a/app-misc/abook/files/abook-0.6.1-use-PKG_CHECK_MODULES-for-ncurses.patch b/app-misc/abook/files/abook-0.6.1-use-PKG_CHECK_MODULES-for-ncurses.patch
index 00b8e444904..8d7a6cddd7c 100644
--- a/app-misc/abook/files/abook-0.6.1-use-PKG_CHECK_MODULES-for-ncurses.patch
+++ b/app-misc/abook/files/abook-0.6.1-use-PKG_CHECK_MODULES-for-ncurses.patch
@@ -1,11 +1,36 @@
+From 243d3c265289171f59de68f5da4de086afb58215 Mon Sep 17 00:00:00 2001
From: Sam James <sam@gentoo.org>
-Date: Wed, 21 Apr 2021 06:06:13 +0100
-Subject: Use PKG_CHECK_MODULES for ncurses
+Date: Sat, 31 Jul 2021 03:21:28 +0100
+Subject: [PATCH] Use PKG_CHECK_MODULES for ncurses
We don't _always_ have split tinfo, e.g. Prefix.
+
+Signed-off-by: Sam James <sam@gentoo.org>
+---
+ Makefile.am | 4 ++--
+ configure.ac | 26 +-------------------------
+ 2 files changed, 3 insertions(+), 27 deletions(-)
+
+diff --git a/Makefile.am b/Makefile.am
+index 8faaa11..18c6892 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -22,8 +22,8 @@ abook_SOURCES = abook.c abook_rl.c database.c edit.c \
+ EXTRA_DIST = config.rpath ANNOUNCE BUGS FAQ abook.1 abookrc.5 sample.abookrc \
+ abook.spec contrib doc/HOWTO.translating_abook RELEASE_NOTES
+
+-abook_LDADD = @LIBINTL@
+-
++abook_CFLAGS = $(ncurses_CFLAGS)
++abook_LDADD = @LIBINTL@ $(ncurses_LIBS)
+
+ install-data-local:
+ $(mkinstalldirs) $(DESTDIR)$(mandir)/man1 $(DESTDIR)$(mandir)/man5
+diff --git a/configure.ac b/configure.ac
+index 5a9ae3b..73a7af0 100644
--- a/configure.ac
+++ b/configure.ac
-@@ -74,31 +74,9 @@ dnl -------------------
+@@ -74,31 +74,7 @@ dnl -------------------
dnl (n)curses detection
dnl -------------------
@@ -35,10 +60,9 @@ We don't _always_ have split tinfo, e.g. Prefix.
- [CF_CURSES_LIBS])
- ])
+PKG_CHECK_MODULES(ncurses, [ncursesw ncurses])
-+LDFLAGS="${ncurses_LIBS} $LDFLAGS"
-+CPPFLAGS="${ncurses_CFLAGS} $CPPFLAGS"
dnl --------------------------
dnl end of (n)curses detection
--
+2.32.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2021-07-31 3:25 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-07-31 3:25 [gentoo-commits] repo/gentoo:master commit in: app-misc/abook/files/ Sam James
-- strict thread matches above, loose matches on Subject: below --
2021-07-17 16:02 Cédric Krier
2017-09-02 15:15 Michael Palimaka
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox