aboutsummaryrefslogtreecommitdiffstats
path: root/main/libc0.9.32
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2013-07-30 12:42:51 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2013-07-30 12:42:51 +0000
commit871f00fe9da801411a775a30afc861d58e0eb20f (patch)
tree513d6ae3213bbc982b0dbeeebd8f42c5fde83ed9 /main/libc0.9.32
parenta4d45f7f15e6b92de57accd07cf20782ec8bdf7a (diff)
downloadaports-871f00fe9da801411a775a30afc861d58e0eb20f.tar.bz2
aports-871f00fe9da801411a775a30afc861d58e0eb20f.tar.xz
main/libc0.9.32: add mkostemp
needed by util-linux
Diffstat (limited to 'main/libc0.9.32')
-rw-r--r--main/libc0.9.32/0001-libc-stdlib-add-mkostemp-helpers.patch155
-rw-r--r--main/libc0.9.32/0001-stdlib-Fix-fndecl-of-mkostemp-mkostemp64.patch44
-rw-r--r--main/libc0.9.32/APKBUILD11
3 files changed, 208 insertions, 2 deletions
diff --git a/main/libc0.9.32/0001-libc-stdlib-add-mkostemp-helpers.patch b/main/libc0.9.32/0001-libc-stdlib-add-mkostemp-helpers.patch
new file mode 100644
index 0000000000..371177f561
--- /dev/null
+++ b/main/libc0.9.32/0001-libc-stdlib-add-mkostemp-helpers.patch
@@ -0,0 +1,155 @@
+From 42d1b23fc0f3748b8bf474e456d6c44aa7e563fd Mon Sep 17 00:00:00 2001
+From: Mike Frysinger <vapier@gentoo.org>
+Date: Wed, 14 Nov 2012 00:30:54 -0500
+Subject: [PATCH] libc/stdlib: add mkostemp helpers
+
+Some projects (like udev) are starting to use this.
+
+Imported from glibc.
+
+Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+---
+ include/stdlib.h | 23 +++++++++++++++++++++++
+ libc/stdlib/Makefile.in | 4 ++--
+ libc/stdlib/mkostemp.c | 32 ++++++++++++++++++++++++++++++++
+ libc/stdlib/mkostemp64.c | 33 +++++++++++++++++++++++++++++++++
+ 4 files changed, 90 insertions(+), 2 deletions(-)
+ create mode 100644 libc/stdlib/mkostemp.c
+ create mode 100644 libc/stdlib/mkostemp64.c
+
+diff --git a/include/stdlib.h b/include/stdlib.h
+index 354fc66..79ccc55 100644
+--- a/include/stdlib.h
++++ b/include/stdlib.h
+@@ -652,6 +652,29 @@ extern int mkstemp64 (char *__template) __nonnull ((1)) __wur;
+ extern char *mkdtemp (char *__template) __THROW __nonnull ((1)) __wur;
+ #endif
+
++#ifdef __USE_GNU
++/* Generate a unique temporary file name from TEMPLATE similar to
++ mkstemp. But allow the caller to pass additional flags which are
++ used in the open call to create the file..
++
++ This function is a possible cancellation point and therefore not
++ marked with __THROW. */
++# ifndef __USE_FILE_OFFSET64
++extern int mkostemp (char *__template, int __flags) __nonnull ((1)) __wur;
++# else
++# ifdef __REDIRECT
++extern int __REDIRECT (mkostemp, (char *__template, int __flags), mkostemp64)
++ __nonnull ((1)) __wur;
++# else
++# define mkostemp mkostemp64
++# endif
++# endif
++# ifdef __USE_LARGEFILE64
++extern int mkostemp64 (char *__template, int __flags) __nonnull ((1)) __wur;
++# endif
++
++#endif
++
+
+ __BEGIN_NAMESPACE_STD
+ /* Execute the given line as a shell command.
+diff --git a/libc/stdlib/Makefile.in b/libc/stdlib/Makefile.in
+index 3166b8e..b92f7ce 100644
+--- a/libc/stdlib/Makefile.in
++++ b/libc/stdlib/Makefile.in
+@@ -12,7 +12,7 @@ include $(top_srcdir)libc/stdlib/malloc-simple/Makefile.in
+ include $(top_srcdir)libc/stdlib/malloc-standard/Makefile.in
+
+ CSRC-y := \
+- abort.c getenv.c mkdtemp.c realpath.c canonicalize.c mkstemp.c \
++ abort.c getenv.c mkdtemp.c realpath.c canonicalize.c mkstemp.c mkostemp.c \
+ rand.c random.c random_r.c setenv.c div.c ldiv.c lldiv.c \
+ getpt.c drand48-iter.c jrand48.c \
+ jrand48_r.c lcong48.c lrand48.c lrand48_r.c mrand48.c mrand48_r.c nrand48.c \
+@@ -21,7 +21,7 @@ CSRC-y := \
+ CSRC-$(UCLIBC_HAS_ADVANCED_REALTIME) += posix_memalign.c
+ CSRC-$(UCLIBC_HAS_PTY) += grantpt.c unlockpt.c ptsname.c
+ CSRC-$(UCLIBC_HAS_ARC4RANDOM) += arc4random.c
+-CSRC-$(UCLIBC_HAS_LFS) += mkstemp64.c
++CSRC-$(UCLIBC_HAS_LFS) += mkstemp64.c mkostemp64.c
+ CSRC-$(UCLIBC_HAS_FLOATS) += drand48.c drand48_r.c erand48.c erand48_r.c
+ CSRC-$(if $(findstring yy,$(UCLIBC_HAS_FLOATS)$(UCLIBC_SUSV3_LEGACY)),y) += \
+ gcvt.c
+diff --git a/libc/stdlib/mkostemp.c b/libc/stdlib/mkostemp.c
+new file mode 100644
+index 0000000..93b50fc
+--- /dev/null
++++ b/libc/stdlib/mkostemp.c
+@@ -0,0 +1,32 @@
++/* Copyright (C) 1998-2012 Free Software Foundation, Inc.
++ This file is part of the GNU C Library.
++
++ The GNU C Library is free software; you can redistribute it and/or
++ modify it under the terms of the GNU Lesser General Public
++ License as published by the Free Software Foundation; either
++ version 2.1 of the License, or (at your option) any later version.
++
++ The GNU C Library is distributed in the hope that it will be useful,
++ but WITHOUT ANY WARRANTY; without even the implied warranty of
++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
++ Lesser General Public License for more details.
++
++ You should have received a copy of the GNU Lesser General Public
++ License along with the GNU C Library; if not, see
++ <http://www.gnu.org/licenses/>. */
++
++#include <stdio.h>
++#include <stdlib.h>
++#include "../misc/internals/tempname.h"
++
++/* Generate a unique temporary file name from TEMPLATE.
++ The last six characters of TEMPLATE must be "XXXXXX";
++ they are replaced with a string that makes the filename unique.
++ Then open the file and return a fd. */
++int
++mkostemp (template, flags)
++ char *template;
++ int flags;
++{
++ return __gen_tempname (template, __GT_FILE, flags);
++}
+diff --git a/libc/stdlib/mkostemp64.c b/libc/stdlib/mkostemp64.c
+new file mode 100644
+index 0000000..5509d8c
+--- /dev/null
++++ b/libc/stdlib/mkostemp64.c
+@@ -0,0 +1,33 @@
++/* Copyright (C) 2000-2012 Free Software Foundation, Inc.
++ This file is part of the GNU C Library.
++
++ The GNU C Library is free software; you can redistribute it and/or
++ modify it under the terms of the GNU Lesser General Public
++ License as published by the Free Software Foundation; either
++ version 2.1 of the License, or (at your option) any later version.
++
++ The GNU C Library is distributed in the hope that it will be useful,
++ but WITHOUT ANY WARRANTY; without even the implied warranty of
++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
++ Lesser General Public License for more details.
++
++ You should have received a copy of the GNU Lesser General Public
++ License along with the GNU C Library; if not, see
++ <http://www.gnu.org/licenses/>. */
++
++#include <fcntl.h>
++#include <stdio.h>
++#include <stdlib.h>
++#include "../misc/internals/tempname.h"
++
++/* Generate a unique temporary file name from TEMPLATE.
++ The last six characters of TEMPLATE must be "XXXXXX";
++ they are replaced with a string that makes the filename unique.
++ Then open the file and return a fd. */
++int
++mkostemp64 (template, flags)
++ char *template;
++ int flags;
++{
++ return __gen_tempname (template, __GT_BIGFILE, flags | O_LARGEFILE);
++}
+--
+1.8.3.3
+
diff --git a/main/libc0.9.32/0001-stdlib-Fix-fndecl-of-mkostemp-mkostemp64.patch b/main/libc0.9.32/0001-stdlib-Fix-fndecl-of-mkostemp-mkostemp64.patch
new file mode 100644
index 0000000000..cd0285d09d
--- /dev/null
+++ b/main/libc0.9.32/0001-stdlib-Fix-fndecl-of-mkostemp-mkostemp64.patch
@@ -0,0 +1,44 @@
+From 5084cf8b6b8f01890b62bfd0edf085d04887d084 Mon Sep 17 00:00:00 2001
+From: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
+Date: Sun, 10 Feb 2013 17:21:15 +0100
+Subject: [PATCH] stdlib: Fix fndecl of mkostemp, mkostemp64
+
+Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
+---
+ libc/stdlib/mkostemp.c | 4 +---
+ libc/stdlib/mkostemp64.c | 4 +---
+ 2 files changed, 2 insertions(+), 6 deletions(-)
+
+diff --git a/libc/stdlib/mkostemp.c b/libc/stdlib/mkostemp.c
+index 93b50fc..0369235 100644
+--- a/libc/stdlib/mkostemp.c
++++ b/libc/stdlib/mkostemp.c
+@@ -24,9 +24,7 @@
+ they are replaced with a string that makes the filename unique.
+ Then open the file and return a fd. */
+ int
+-mkostemp (template, flags)
+- char *template;
+- int flags;
++mkostemp (char *template, int flags)
+ {
+ return __gen_tempname (template, __GT_FILE, flags);
+ }
+diff --git a/libc/stdlib/mkostemp64.c b/libc/stdlib/mkostemp64.c
+index 5509d8c..d21def5 100644
+--- a/libc/stdlib/mkostemp64.c
++++ b/libc/stdlib/mkostemp64.c
+@@ -25,9 +25,7 @@
+ they are replaced with a string that makes the filename unique.
+ Then open the file and return a fd. */
+ int
+-mkostemp64 (template, flags)
+- char *template;
+- int flags;
++mkostemp64 (char *template, int flags)
+ {
+ return __gen_tempname (template, __GT_BIGFILE, flags | O_LARGEFILE);
+ }
+--
+1.8.3.4
+
diff --git a/main/libc0.9.32/APKBUILD b/main/libc0.9.32/APKBUILD
index de59072ebe..c86249eed6 100644
--- a/main/libc0.9.32/APKBUILD
+++ b/main/libc0.9.32/APKBUILD
@@ -4,7 +4,7 @@ pkgname=libc$_abiver
_gitver=
pkgver=0.9.33.2
_ver=${pkgver/_/-}
-pkgrel=22
+pkgrel=23
pkgdesc="C library for developing embedded Linux systems"
url=http://uclibc.org
license="LGPL-2"
@@ -18,7 +18,6 @@ replaces=uclibc
depends="libpthread libc"
options="!strip"
triggers="uclibc-utils.trigger=/lib:/usr/lib"
-ldpath="/lib"
_snapurl="http://git.uclibc.org/uClibc/snapshot/master.tar.bz2"
_snapfile="$pkgname-$pkgver.tar.bz2"
@@ -68,6 +67,8 @@ librt-re-add-SIGCANCEL-to-the-list-of-blocked-signal-in-helper-thread.patch
uClibc-0.9.33.2-dup3.patch
avoid-forced-unwind.patch
+ 0001-libc-stdlib-add-mkostemp-helpers.patch
+ 0001-stdlib-Fix-fndecl-of-mkostemp-mkostemp64.patch
uclibcconfig.x86
uclibcconfig.x86_64
@@ -212,6 +213,8 @@ e5352b7ebaa21e2ed787ce124ef67c9f 0001-ldd-subdepends-check-stderr.patch
cbbd96f04cf17a403c1f74767e144fa2 uClibc-0.9.33.2-define-MSG_CMSG_CLOEXEC.patch
7671d02a05a074bbcbcd6193492772d6 uClibc-0.9.33.2-dup3.patch
bfe02411af06545da375f177cfaf7efe avoid-forced-unwind.patch
+5320bafb053938dda439cdf06095d172 0001-libc-stdlib-add-mkostemp-helpers.patch
+d1dd50e417383d46acdd5976813c9862 0001-stdlib-Fix-fndecl-of-mkostemp-mkostemp64.patch
ce8a33a31f5a53031fbad8b1d1b66d44 uclibcconfig.x86
e861a17baa541accf4d4d39a98d74c32 uclibcconfig.x86_64
ce8a33a31f5a53031fbad8b1d1b66d44 uclibcconfig.i486
@@ -253,6 +256,8 @@ b284cf0f0f19897272ca0c8e10c7aa05a837807efcaad2b44e4f1a2c2fb1bbe4 libdl.patch
a53bbdbe8af14cb6918836bea42ec0c85fca1a0e3de1ba3a3767d0bb97d08c92 uClibc-0.9.33.2-define-MSG_CMSG_CLOEXEC.patch
cf0ce515c8d98e68cec01e805cb568371dd6f4aa21c14ea8bf841a0a0c26b358 uClibc-0.9.33.2-dup3.patch
59265ece74b907c34186d47f035c9cc3b390f19bc4ef932d915317119574e709 avoid-forced-unwind.patch
+013f33861790a75d3ec1c28861d57a86e990a06f47120d992f40a36985132550 0001-libc-stdlib-add-mkostemp-helpers.patch
+646dc019fd010c16d9c2cbea251be816ce44ad780eac8aad58108923d2b473bd 0001-stdlib-Fix-fndecl-of-mkostemp-mkostemp64.patch
7f613b473adbbf38701125f3d298d11f91e102e5cda17eec8133e8463bdc10c9 uclibcconfig.x86
bec76f2c67c0c632b24bb8c3db01396cc56f208a8c5ca16543fd5e71050d8c88 uclibcconfig.x86_64
7f613b473adbbf38701125f3d298d11f91e102e5cda17eec8133e8463bdc10c9 uclibcconfig.i486
@@ -294,6 +299,8 @@ be0bc446a030b1e59ccd8fa564b773cf12f6aac1ecb645ceeeb54958ebd8dd8619431bc395aeb640
2982f918b8d73cff688fca4363eb9f165bc5383937e5d669e57c35dc2b9d4ec6efa6592ee7450f01382adaf7dbb92f6f7e623e9f885aa698c831cc7861131530 uClibc-0.9.33.2-define-MSG_CMSG_CLOEXEC.patch
1e3241a2b8332a23793da9a1dacd3622f38499f1c1a9fe67f5afc5147007693826921d9f3c7521d4bb57d868a349f911db2bb35d2e988080527cce9fb2b187dd uClibc-0.9.33.2-dup3.patch
265a805fd75197782cbfa527289966eacd5453c677a33f336cdcc80ec001a4f945bfb3348e219bc3d754a9ba9f519bf09270cc17e2f23d0575649bbf867022bd avoid-forced-unwind.patch
+c95a1e96308c761dbe4d11fc7d84aee04a5abc8d8da191cc5aae407eba4fec9b7c62f9c7f8294004d7a160fc7051c3d9de64368e4c85c633609ee3dfb5d97e3c 0001-libc-stdlib-add-mkostemp-helpers.patch
+1867ca0de857afc43e430cb18bbdd279e795c73062184c18c82c8d5970fad88cd60aee8c24a1ab16595dfb5df002be19eb46f24017d5a0432358107a213f43d6 0001-stdlib-Fix-fndecl-of-mkostemp-mkostemp64.patch
ab04402abefad1f239d27d9638c1d8d76bc6a8edd77bbb8ed5a4b1445dbc44d709bb1b5214fc9a37a2208c2b6e92dd0a147eddea5d0b2e1ca3ec227432fe86eb uclibcconfig.x86
063899afb5f3c20e5dae1b613aa8963408b66ef21228df2500366163aeda71ca4163cbef8c3e53f389ba4a85b8eec5991667cdb31576141ce2ccbc1dc3d33cab uclibcconfig.x86_64
ab04402abefad1f239d27d9638c1d8d76bc6a8edd77bbb8ed5a4b1445dbc44d709bb1b5214fc9a37a2208c2b6e92dd0a147eddea5d0b2e1ca3ec227432fe86eb uclibcconfig.i486