summaryrefslogtreecommitdiff
path: root/app-text/bogosort
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
committerV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
commit8376ef56580626e9c0f796d5b85b53a0a1c7d5f5 (patch)
tree7681bbd4e8b05407772df40a4bf04cbbc8afc3fa /app-text/bogosort
parent30a9caf154332f12ca60756e1b75d2f0e3e1822d (diff)
gentoo resync : 14.07.2018
Diffstat (limited to 'app-text/bogosort')
-rw-r--r--app-text/bogosort/Manifest5
-rw-r--r--app-text/bogosort/bogosort-0.4.2-r1.ebuild34
-rw-r--r--app-text/bogosort/files/bogosort-0.4.2-glibc-2.10.patch41
-rw-r--r--app-text/bogosort/files/xmalloc.patch15
-rw-r--r--app-text/bogosort/metadata.xml13
5 files changed, 108 insertions, 0 deletions
diff --git a/app-text/bogosort/Manifest b/app-text/bogosort/Manifest
new file mode 100644
index 000000000000..607b0c22c33f
--- /dev/null
+++ b/app-text/bogosort/Manifest
@@ -0,0 +1,5 @@
+AUX bogosort-0.4.2-glibc-2.10.patch 1479 BLAKE2B 6d5a6e9ff7f43a5275e8db8d1478a06ab69863105ffdfb3ed821bdbb7b901f2b0ed9b9158ee0795ca4e1dc01b01c5a3fdaedf5bd4996d3d9bc5ec4a89492e6eb SHA512 742b473df18b8eee876857fc3fa14bacc95bce4e14d083deb066d4451385437cd040cf40b6c572762c047b1aaa3e2ee973f2d880c5915993bf6a4ba130a776e4
+AUX xmalloc.patch 395 BLAKE2B 0ec83824e8ac740512c3c241cf2df352ca5b5d05a38507288fe5f96512eebb94d5532af0cfb6e05fcfcac9c10c96091584b917966629268e9921d964e8adb0c5 SHA512 c1479f342d71e1c53a2b038bc7bf858292c6585b8360b41c6006a4ef0efbafc3260cf8523efedee945c084247851186dda3450ab0533465c33176b038a8c0243
+DIST bogosort-0.4.2.tar.gz 161628 BLAKE2B 92abbb809747e3fdfd2a6e33f7f753f1ddccd4ecd9883f0a02fc843f8f680e0a5e6e6b65c3943708ed074a944e5187bb889297365ae0dd34292215b056bd46fc SHA512 2d2f7be36ec08aa78323cbdc5f1030297706c364d6fc82554065cf737295d11c90dd6061323f2732b63c70401d710b2018075bff6d1e6ab0078069b405ea62e9
+EBUILD bogosort-0.4.2-r1.ebuild 702 BLAKE2B d70ee1662cb0528e340837d4a95a5165edfe4387d92ce5d9512f16335ea8651718087b7c9960986f5f188dd6c28004ef10e2fc69989531b492e8a47ad77313d1 SHA512 7baec5a2de60f5bbef8689c12d6fdc54a3fd40dee3b64877af819422f986c50fb706c52906486a055af2ef16650e908a3c5b960181dba14b1ee14955d5c7a769
+MISC metadata.xml 500 BLAKE2B aeef2d2944fbcde35a34db35b8461e3fb22d5da60e0e6fee48cecbcd45991d44aa4511e0907587369c2a7c7bf2c735260ed516b5b9292e1fb60bd7a2e9c3859d SHA512 4975f3dcbf7a97db8c64835a83f45a0be5d3c34aaa9fe9f8b2e2e8bd5aaf102fe35a2f4dc609bbcd115ad08d86707818033c7b7759c17a3f233417af67604edb
diff --git a/app-text/bogosort/bogosort-0.4.2-r1.ebuild b/app-text/bogosort/bogosort-0.4.2-r1.ebuild
new file mode 100644
index 000000000000..5eff84f8ed58
--- /dev/null
+++ b/app-text/bogosort/bogosort-0.4.2-r1.ebuild
@@ -0,0 +1,34 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="5"
+
+inherit eutils toolchain-funcs
+
+DESCRIPTION="A file sorting program which uses the bogosort algorithm"
+HOMEPAGE="http://www.lysator.liu.se/~qha/bogosort/"
+SRC_URI="ftp://ulrik.haugen.se/pub/unix/bogosort/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="amd64 hppa ~mips ppc sparc x86 ~x86-linux ~ppc-macos"
+IUSE=""
+
+DEPEND=""
+RDEPEND=""
+
+src_prepare() {
+ epatch \
+ "${FILESDIR}"/xmalloc.patch \
+ "${FILESDIR}"/${P}-glibc-2.10.patch
+}
+
+src_configure() {
+ tc-export CC
+ econf || die
+}
+
+src_install() {
+ make DESTDIR="${D}" install || die
+ dodoc README NEWS ChangeLog AUTHORS || die
+}
diff --git a/app-text/bogosort/files/bogosort-0.4.2-glibc-2.10.patch b/app-text/bogosort/files/bogosort-0.4.2-glibc-2.10.patch
new file mode 100644
index 000000000000..ac54c8b61b05
--- /dev/null
+++ b/app-text/bogosort/files/bogosort-0.4.2-glibc-2.10.patch
@@ -0,0 +1,41 @@
+diff -ur bogosort-0.4.2.orig/getlines.c bogosort-0.4.2/getlines.c
+--- bogosort-0.4.2.orig/getlines.c 2002-05-04 23:22:22.000000000 +0300
++++ bogosort-0.4.2/getlines.c 2009-08-06 14:32:22.000000000 +0300
+@@ -49,7 +49,7 @@
+ char **ss = NULL;
+
+ /* read all lines available */
+- while ((s = getline(stream)) != NULL) {
++ while ((s = get_line(stream)) != NULL) {
+ if (numlines == allocated) /* make more room if needed */
+ ss = (char **)xrealloc(ss,
+ (allocated += LINESTEP) * sizeof (char *));
+@@ -81,7 +81,7 @@
+ allocated = numlines + 1; /* this is a lie, but it's close enough */
+
+ /* read all lines available */
+- while ((s = getline(stream)) != NULL) {
++ while ((s = get_line(stream)) != NULL) {
+ if (numlines == allocated) /* make more room if needed */
+ ss = (char **)xrealloc(ss,
+ (allocated += LINESTEP) * sizeof (char *));
+@@ -100,7 +100,7 @@
+ * line in stream, return NULL on EOF
+ */
+ char *
+-getline(FILE *stream)
++get_line(FILE *stream)
+ {
+ int c, numchars = 0, allocated = 0;
+ char *s = NULL;
+diff -ur bogosort-0.4.2.orig/getlines.h bogosort-0.4.2/getlines.h
+--- bogosort-0.4.2.orig/getlines.h 2002-03-16 00:04:38.000000000 +0200
++++ bogosort-0.4.2/getlines.h 2009-08-06 14:32:48.000000000 +0300
+@@ -39,6 +39,6 @@
+ * getline: return a pointer to a newly allocated string containing the next
+ * line in stream
+ */
+-char *getline(FILE *stream);
++char *get_line(FILE *stream);
+
+ #endif /* GETLINES_H */
diff --git a/app-text/bogosort/files/xmalloc.patch b/app-text/bogosort/files/xmalloc.patch
new file mode 100644
index 000000000000..41545ca34ba8
--- /dev/null
+++ b/app-text/bogosort/files/xmalloc.patch
@@ -0,0 +1,15 @@
+--- xmalloc.c.orig 2004-12-15 23:44:16.880786468 +0100
++++ xmalloc.c 2004-12-15 23:44:21.846546805 +0100
+@@ -68,12 +68,6 @@
+ The caller may set it to some other value. */
+ int xmalloc_exit_failure = EXIT_FAILURE;
+
+-#if __STDC__ && (HAVE_VPRINTF || HAVE_DOPRNT)
+-void error (int, int, const char *, ...);
+-#else
+-void error ();
+-#endif
+-
+ static VOID *
+ fixup_null_alloc (n)
+ size_t n;
diff --git a/app-text/bogosort/metadata.xml b/app-text/bogosort/metadata.xml
new file mode 100644
index 000000000000..46dbedede5f6
--- /dev/null
+++ b/app-text/bogosort/metadata.xml
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="project">
+ <email>shell-tools@gentoo.org</email>
+ <name>Gentoo Shell Tools Project</name>
+ </maintainer>
+ <longdescription lang="en">
+ The bogosort will sort a file in a similar way to sort(1), but using
+ the bogosort algorithm rather than the conventional qsort. The tool
+ can also randomise the lines in its input.
+ </longdescription>
+</pkgmetadata>