From d87262dd706fec50cd150aab3e93883b6337466d Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sat, 14 Jul 2018 20:56:41 +0100 Subject: gentoo resync : 14.07.2018 --- app-misc/tdl/Manifest | 8 - app-misc/tdl/files/1.5.2-ldflags.patch | 13 - app-misc/tdl/files/tdl-1.5.2-list.c.patch | 34 -- app-misc/tdl/files/tdl-1.5.2-main.c.patch | 178 ----------- app-misc/tdl/files/tdl-1.5.2-man.patch | 507 ------------------------------ app-misc/tdl/metadata.xml | 13 - app-misc/tdl/tdl-1.5.2-r2.ebuild | 75 ----- 7 files changed, 828 deletions(-) delete mode 100644 app-misc/tdl/Manifest delete mode 100644 app-misc/tdl/files/1.5.2-ldflags.patch delete mode 100644 app-misc/tdl/files/tdl-1.5.2-list.c.patch delete mode 100644 app-misc/tdl/files/tdl-1.5.2-main.c.patch delete mode 100644 app-misc/tdl/files/tdl-1.5.2-man.patch delete mode 100644 app-misc/tdl/metadata.xml delete mode 100644 app-misc/tdl/tdl-1.5.2-r2.ebuild (limited to 'app-misc/tdl') diff --git a/app-misc/tdl/Manifest b/app-misc/tdl/Manifest deleted file mode 100644 index 5d18c067b65d..000000000000 --- a/app-misc/tdl/Manifest +++ /dev/null @@ -1,8 +0,0 @@ -AUX 1.5.2-ldflags.patch 350 BLAKE2B 147ecde0a506852a3540c825143478cd7b741d3846afa7e58fe01cb389aaa1b9bd186916cd714b5d24a01a6ce5cc714e0bab53d95fee563a2916d8d87a149df8 SHA512 a3bb6f75a56d350755edf4cbb7a36fbe3da2e87fb8744a5597f9909cfe9e03b9ea4a50d70d9ca0cb2c480c11597701fbf9866d5eb7e726617005679c41ec5e9d -AUX tdl-1.5.2-list.c.patch 1272 BLAKE2B 4d65bd0c6336d459b388f2375468871df6e7761e5be90aba3d059ec7991b4e41907b3c1089f3ada9416cb944a74b90d15c8435866d622e1117b4084df9facba8 SHA512 a66d0728f06d386827dd1232e3c290c9e749689cb368b9240638cde86c5ef1ae5e9ce5923a6b7dbba5e04c30ded2174c1c16e24ca6a943754cd178098a732400 -AUX tdl-1.5.2-main.c.patch 4967 BLAKE2B f609c3a44996ddf4bac91f65e28e3dbad4600284a8ffe0f249a2e58289ee98d0f6fb4533599d66b8a7019e52a235f6366ace8ef12e6882606849f9fccbd3e927 SHA512 b7036f2b4292263fcde59c6cb46a869dec92fe314f4d3a5d4f2f5411adb945ec5493e82a142372bca933d67c423c4deff333b297a1dc2481d993de1789faaeb2 -AUX tdl-1.5.2-man.patch 11004 BLAKE2B 849601edce8452c3ca590b6b10f211ee81355adc121ff878fee165758bde10cc58b4a72a0bb71855b58093ff45a21d51761e24563b50c8be88ebb61d9d1a50eb SHA512 fef2ca8f8c6db0b61037ad10269fe185f2d5cb1ffdee0560acdba61be87d71d2195471412d26a5c6e7766332d9a13bf95774b0374de14b6df7b4a97ad27e8d32 -DIST tdl-1.5.2.tar.gz 66057 BLAKE2B cc2d5581126d995098b5dc3032c97213614acaea3b984a507a824da2ba4d3be9afff954722f29acf0b9bd26db42ada22d67fc9110496961c2cb3104d9b4b7ece SHA512 8c07a5b6a5434bb567a2d68b6e0215bbfa7be3f7176ae1042652ac18684289117230af25d8d161fcf1ba27d9b740fd3fcd43c3213467b533de64390686481fe0 -DIST tdl-screenshot.png.tar 20480 BLAKE2B ce9284501ba1550179e1c3da54399a802aae3c0fb23b9a1ea25a1adb0f5c0404fe7694a360435913bb91cc1977d71561050ec0fe4e1681db775cdc7ec5fa11b7 SHA512 caca9793626b320ded4c7f16425b98e4bfde9ab0ca3c1bea60ecc8aaa8db080ab6fc3c474aef4d56e394b6415ec1162671329912aa22452dbd5dc72b50c7c8f6 -EBUILD tdl-1.5.2-r2.ebuild 1513 BLAKE2B bc883123e1df051229cfe479f95f46faeb498dbb4aa8c501dfd901a247a0797dd80c528603ed518202e3eb8fab926f0ba825af69f77c6123eb77fcee8318242a SHA512 40c6116b132441e21d62bccb997b1e140879df1981684aaba097d8b3373b4f933d94b89e52b3dc2d864a1b08193b09811437bad3077e228a600d0275fb752794 -MISC metadata.xml 507 BLAKE2B 9887ee368ca6f3409ee7da8a1fe98b0b6bac98f3b6949a1a263c9a8966b95d73c33c2b496f98732824e08d17af45b12a12916707e6932be88a947e9ca46d416e SHA512 ce0e36e0dc95b3c050f17e33220bb85c07946127337ae766b7c3af2d9d0891187bb9ab73d8cb01f91bad4f061620d19a403f3af85c801e3194f0a9dc6a0b6ce2 diff --git a/app-misc/tdl/files/1.5.2-ldflags.patch b/app-misc/tdl/files/1.5.2-ldflags.patch deleted file mode 100644 index d807fdf02246..000000000000 --- a/app-misc/tdl/files/1.5.2-ldflags.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/Makefile.in b/Makefile.in -index 46b05ca..eb9b656 100644 ---- a/Makefile.in -+++ b/Makefile.in -@@ -52,7 +52,7 @@ OBJ = main.o io.o add.o done.o remove.o move.o list.o \ - all : tdl - - tdl : $(OBJ) -- $(CC) $(CFLAGS) -o tdl $(OBJ) $(LIB_READLINE) -+ $(CC) $(CFLAGS) $(LDFLAGS) -o tdl $(OBJ) $(LIB_READLINE) - - %.o : %.c - $(CC) $(CFLAGS) -c $< diff --git a/app-misc/tdl/files/tdl-1.5.2-list.c.patch b/app-misc/tdl/files/tdl-1.5.2-list.c.patch deleted file mode 100644 index d2cc39bd49c1..000000000000 --- a/app-misc/tdl/files/tdl-1.5.2-list.c.patch +++ /dev/null @@ -1,34 +0,0 @@ ---- tdl-1.5.2.orig/list.c -+++ tdl-1.5.2/list.c -@@ -75,14 +75,15 @@ - static void print_timestamp(int timestamp, char *leader, int indent, int monochrome)/*{{{*/ - { - char buffer[32]; -- time_t now; -+ time_t now, timestamp2; - long diff, days_ago, days_ahead; - - now = time(NULL); - diff = now - timestamp; - days_ago = (diff + ((diff > 0) ? 43200 : -43200)) / 86400; -+ timestamp2 = (time_t) timestamp; - strftime(buffer, sizeof(buffer), "%a %d %b %Y %H:%M", -- localtime((time_t *)×tamp)); -+ localtime(×tamp2)); - do_indent(indent+2); - if (days_ago < 0) { - days_ahead = - days_ago; -@@ -524,6 +525,13 @@ - * Otherwise, use the priority from the specified node, _except_ when - * that is higher than normal, in which case use normal. */ - prio_to_use = (prio_set) ? prio : ((node_prio > prio) ? prio : node_prio); -+ /* if listing up-to-some-depth (option -N) and also -+ * beginning at some top-level (option NNN) then depth must be -+ * decremented by 1 -+ * see: http://bugs.debian.org/364083 */ -+ if (options.depth > 0) { -+ options.depth--; -+ } - list_chain(&n->kids, INDENT_TAB, 0, &options, index_buffer, prio_to_use, now, hits); - } - } else if ((y[0] == '-') && (y[1] == '-')) { diff --git a/app-misc/tdl/files/tdl-1.5.2-main.c.patch b/app-misc/tdl/files/tdl-1.5.2-main.c.patch deleted file mode 100644 index c195a1e5cb7c..000000000000 --- a/app-misc/tdl/files/tdl-1.5.2-main.c.patch +++ /dev/null @@ -1,178 +0,0 @@ ---- tdl-1.5.2.orig/main.c -+++ tdl-1.5.2/main.c -@@ -80,7 +80,7 @@ - return; - } - /*}}}*/ --static volatile void unlock_and_exit(int code)/*{{{*/ -+static void unlock_and_exit(int code)/*{{{*/ - { - unlock_database(); - exit(code); -@@ -237,22 +237,91 @@ - - } - /*}}}*/ --static void rename_database(char *path)/*{{{*/ -+static mode_t get_mode(const char *path); /* prototype */ -+/*}}}*/ -+static int copy_file_contents(char *pathsrc, char *pathdest) { -+ int src, dest; -+ ssize_t rdsize = 1; -+ char buf[4096]; -+ -+ src = open(pathsrc, O_RDONLY); -+ if (src == -1) { -+ perror("warning, couldn't open database"); -+ return 0; -+ } -+ dest = open(pathdest, O_WRONLY | O_CREAT, get_mode(pathsrc)); -+ if (dest == -1) { -+ perror("warning, couldn't open/create backup database"); -+ close(src); -+ return 0; -+ } -+ if (ftruncate(dest,0) != 0) { -+ perror("warning, couldn't truncate backup database"); -+ close(src); -+ close(dest); -+ return 0; -+ } -+ lseek(src,0,SEEK_SET); -+ lseek(dest,0,SEEK_SET); -+ while (rdsize > 0) { -+ rdsize = read(src, buf, 4096); -+ if (rdsize == -1) { -+ perror("warning, error reading database"); -+ close(src); -+ close(dest); -+ return 0; -+ } -+ if (rdsize > 0) { -+ if (write(dest, buf, rdsize) != rdsize) { -+ perror("warning, error writing to backup database"); -+ close(src); -+ close(dest); -+ return 0; -+ } -+ } -+ } -+ close(src); -+ close(dest); -+ return 1; -+} -+/*}}}*/ -+static int path_is_symlink(char *path) { -+ int i; -+ struct stat s; -+ i = lstat(path, &s); -+ if ((i == 0) && (S_ISLNK(s.st_mode))) { -+ return 1; /* is a symlink */ -+ } -+ return 0; /* not a symlink */ -+} -+/*}}}*/ -+static int rename_database(char *path)/*{{{*/ - { -- int len; -+ /* the rename_database function returns 1 if database or/and -+ * database backup file are symlinks; otherwise returns 0 */ -+ int len, symlinks; - char *pathbak; -- -+ - len = strlen(path); - pathbak = new_array(char, len + 5); - strcpy(pathbak, path); - strcat(pathbak, ".bak"); -- if (rename(path, pathbak) < 0) { -- if (is_noisy) { -- perror("warning, couldn't save backup database:"); -+ -+ symlinks = path_is_symlink(path) | path_is_symlink(pathbak); -+ -+ if (symlinks) { -+ if (access(path,F_OK) == 0) { -+ copy_file_contents(path, pathbak); -+ } -+ } else { -+ if (rename(path, pathbak) < 0) { -+ if (is_noisy) { -+ perror("warning, couldn't save backup database:"); -+ } - } - } - free(pathbak); -- return; -+ return symlinks; - } - /*}}}*/ - static char *executable_name(char *argv0)/*{{{*/ -@@ -315,7 +384,7 @@ - /*}}}*/ - static void save_database(char *path)/*{{{*/ - { -- FILE *out; -+ FILE *out = NULL; - int out_fd; - mode_t database_mode; - if (is_loaded && currently_dirty) { -@@ -324,20 +393,34 @@ - /* The next line only used to happen if the command wasn't 'create'. - * However, it should quietly fail for create, where the existing database - * doesn't exist */ -- rename_database(path); -- -- /* Open database this way so that the permissions from the existing -- database can be duplicated onto the new one in way free of race -- conditions. */ -- out_fd = open(path, O_WRONLY | O_CREAT | O_EXCL, database_mode); -- if (out_fd < 0) { -- fprintf(stderr, "Could not open new database %s for writing : %s\n", -- path, strerror(errno)); -- unlock_and_exit(1); -+ if (rename_database(path) == 0) { -+ /* database is a regular file */ -+ /* Open database this way so that the permissions from the existing -+ database can be duplicated onto the new one in way free of race -+ conditions. */ -+ out_fd = open(path, O_WRONLY | O_CREAT | O_EXCL, database_mode); -+ if (out_fd < 0) { -+ fprintf(stderr, "Could not open new database %s for writing : %s\n", -+ path, strerror(errno)); -+ unlock_and_exit(1); -+ } - } else { -- /* Normal case */ -- out = fdopen(out_fd, "wb"); -+ /* database and/or backup database are symlinks */ -+ /* we should truncate existing file and write its contents */ -+ out_fd = open(path, O_WRONLY | O_CREAT, database_mode); -+ if (out_fd < 0) { -+ fprintf(stderr, "Could not open database %s for writing : %s\n", -+ path, strerror(errno)); -+ unlock_and_exit(1); -+ } else { -+ /* Normal case */ -+ if (ftruncate(out_fd, 0) != 0) { -+ perror("warning, couldn't truncate database:"); -+ unlock_and_exit(1); -+ } -+ } - } -+ out = fdopen(out_fd, "wb"); - if (!out) { - fprintf(stderr, "Cannot open database %s for writing\n", path); - unlock_and_exit(1); -@@ -728,6 +811,11 @@ - - if (!is_loaded && cmds[index].load_db) { - load_database(current_database_path); -+ if (is_interactive && (!is_loaded)) { -+ fprintf(stderr, "error: could not open database. please create a " -+ "database with 'tdl create' before using this tdl command\n"); -+ unlock_and_exit(-1); -+ } - } - - pp = is_tdl ? (p + 1) : p; diff --git a/app-misc/tdl/files/tdl-1.5.2-man.patch b/app-misc/tdl/files/tdl-1.5.2-man.patch deleted file mode 100644 index 955201a2fe2f..000000000000 --- a/app-misc/tdl/files/tdl-1.5.2-man.patch +++ /dev/null @@ -1,507 +0,0 @@ ---- tdl-1.5.2.orig/tdl.1 -+++ tdl-1.5.2/tdl.1 -@@ -2,25 +2,25 @@ - .SH NAME - tdl \- To do list manager - .SH SYNOPSIS --tdl [-q] -+tdl [\-q] - .br --tdl [-q] add|edit|defer|log -+tdl [\-q] add|edit|defer|log - .br --tdl [-q] list|done|undo|report -+tdl [\-q] list|done|undo|report - .br --tdl [-q] remove|above|below|into|clone|copyto -+tdl [\-q] remove|above|below|into|clone|copyto - .br --tdl [-q] postpone|ignore|open -+tdl [\-q] postpone|ignore|open - .br --tdl [-q] which|version|help -+tdl [\-q] which|version|help - .br --tdla [-q] -+tdla [\-q] - .br --tdll [-q] -+tdll [\-q] - .br --tdld [-q] -+tdld [\-q] - .br --tdlg [-q] -+tdlg [\-q] - - .SH DESCRIPTION - A program for managing a to-do list. -@@ -68,9 +68,9 @@ - modified database back to the disk. Only use it if you want to discard - all changes made in this tdl run. - --.pp -+.PP - All forms may take --.I -q -+.I \-q - as the first command line argument. Currently, this suppresses the warning - message if no existing database can be found. The intended use is for using - .B tdll -@@ -104,7 +104,7 @@ - appear as the last children of the parent node afterwards. - .P - .ce 1 ----ooOOoo-- -+\-\-ooOOoo-\- - .PP - .B tdl add - .I [@datespec] -@@ -156,7 +156,7 @@ - environment is set, in which case this specifies the path to use). - .P - .ce 1 ----ooOOoo-- -+\-\-ooOOoo-\- - .PP - .B tdl below - .I index_to_insert_below -@@ -173,7 +173,7 @@ - appear as the first children of the parent node afterwards. - .P - .ce 1 ----ooOOoo-- -+\-\-ooOOoo-\- - .PP - .B tdl clone - .I index_to_clone ... -@@ -185,7 +185,7 @@ - to change its text. - .P - .ce 1 ----ooOOoo-- -+\-\-ooOOoo-\- - .PP - .B tdl copyto - .I new_parent_index -@@ -197,7 +197,7 @@ - children of an existing entry, rather than making them new top level entries. - .P - .ce 1 ----ooOOoo-- -+\-\-ooOOoo-\- - .PP - .B tdl create - .PP -@@ -217,7 +217,7 @@ - TDL_DATABASE. - .P - .ce 1 ----ooOOoo-- -+\-\-ooOOoo-\- - .PP - .B tdl defer - .I [@datespec] -@@ -233,7 +233,7 @@ - .P - which defers entries 1, 2.1 and all its children, and 5 until the following Friday. - To list deferred entries, use --.I list -p -+.I list \-p - , to defer entries indefinitely, see - .I postpone - command. -@@ -242,7 +242,7 @@ - command. - .P - .ce 1 ----ooOOoo-- -+\-\-ooOOoo-\- - .PP - .B tdl done - .I @datespec -@@ -278,7 +278,7 @@ - section later in this page. - .P - .ce 1 ----ooOOoo-- -+\-\-ooOOoo-\- - .PP - .B tdl edit - .I index_to_change -@@ -294,7 +294,7 @@ - command. - .P - .ce 1 ----ooOOoo-- -+\-\-ooOOoo-\- - .PP - .B exit - .PP -@@ -308,7 +308,7 @@ - command, which loses all updates made during the current tdl run. - .P - .ce 1 ----ooOOoo-- -+\-\-ooOOoo-\- - .PP - .B tdl export - .I filename -@@ -322,14 +322,14 @@ - the original database. - .P - .ce 1 ----ooOOoo-- -+\-\-ooOOoo-\- - .PP - .B tdl help - .PP - This command displays a summary of use of each of the commands. - .P - .ce 1 ----ooOOoo-- -+\-\-ooOOoo-\- - .PP - .B tdl ignore - .I index_to_ignore ... -@@ -353,7 +353,7 @@ - it - .P - .ce 1 ----ooOOoo-- -+\-\-ooOOoo-\- - .PP - .B tdl import - .I filename -@@ -367,7 +367,7 @@ - wanted to merge their entries to form one combo database. - .P - .ce 1 ----ooOOoo-- -+\-\-ooOOoo-\- - .PP - .B tdl into - .I new_parent_index -@@ -381,23 +381,23 @@ - argument has ".0" appended to it. - .P - .ce 1 ----ooOOoo-- -+\-\-ooOOoo-\- - .PP - .B tdl list --.I [-v] --.I [-a] --.I [-p] --.I [-m] --.I [-1...9] -+.I [\-v] -+.I [\-a] -+.I [\-p] -+.I [\-m] -+.I [\-1...9] - .I [] - .I [|...] - .br - .B tdll --.I [-v] --.I [-a] --.I [-p] --.I [-m] --.I [-1...9] -+.I [\-v] -+.I [\-a] -+.I [\-p] -+.I [\-m] -+.I [\-1...9] - .I [] - .I [|