[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
CVS gsasl/lib/gl
From: |
gsasl-commit |
Subject: |
CVS gsasl/lib/gl |
Date: |
Wed, 29 Sep 2004 01:17:23 +0200 |
Update of /home/cvs/gsasl/lib/gl
In directory dopio:/tmp/cvs-serv18485/gl
Modified Files:
Makefile.am dummy.c strdup.c strdup.h
Log Message:
Use new GNULib.
--- /home/cvs/gsasl/lib/gl/Makefile.am 2004/09/26 07:19:16 1.7
+++ /home/cvs/gsasl/lib/gl/Makefile.am 2004/09/28 23:17:23 1.8
@@ -10,7 +10,7 @@
# Generated by gnulib-tool.
#
# Invoked as: gnulib-tool --import
-# Reproduce by: gnulib-tool --import --dir=. --lib=libgl --source-base=gl
--m4-base=gl/m4 --libtool dummy strdup
+# Reproduce by: gnulib-tool --import --dir=. --lib=libgl --source-base=gl
--m4-base=gl/m4 --libtool true dummy strdup
AUTOMAKE_OPTIONS = 1.8 gnits
--- /home/cvs/gsasl/lib/gl/dummy.c 2004/08/03 22:12:36 1.3
+++ /home/cvs/gsasl/lib/gl/dummy.c 2004/09/28 23:17:23 1.4
@@ -1,20 +1,20 @@
/* A dummy file, to prevent empty libraries from breaking builds.
Copyright (C) 2004 Simon Josefsson
- This program is free software; you can redistribute it and/or modify it
- under the terms of the GNU Library General Public License as published
- by the Free Software Foundation; either version 2, or (at your option)
- any later version.
+ This file 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.
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
+ This file 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
- Library General Public License for more details.
+ Lesser General Public License for more details.
- You should have received a copy of the GNU Library General Public
- License along with this program; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
- USA. */
+ You should have received a copy of the GNU Lesser General Public
+ License License along with this file; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA */
/* Some systems, reportedly OpenBSD and Mac OS X, refuse to create
libraries without any object files. You might get an error like:
--- /home/cvs/gsasl/lib/gl/strdup.c 2004/09/26 07:19:16 1.4
+++ /home/cvs/gsasl/lib/gl/strdup.c 2004/09/28 23:17:23 1.5
@@ -1,34 +1,44 @@
-/* Copyright (C) 1991, 1996, 1997, 1998, 2002 Free Software Foundation, Inc.
- Copyright (C) 2004 Simon Josefsson
+/* Copyright (C) 1991, 1996, 1997, 1998, 2002, 2003, 2004 Free Software
+ Foundation, Inc.
- The file 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.
+ This file is part of the GNU C Library.
- This file is distributed in the hope that it will be useful,
+ This program 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, or (at your option)
+ any later version.
+
+ This program 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.
+ 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 this file; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
- USA. */
+ You should have received a copy of the GNU Lesser General Public License
along
+ with this program; if not, write to the Free Software Foundation,
+ Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#ifdef HAVE_CONFIG_H
# include <config.h>
#endif
-/* Get malloc. */
-#include <stdlib.h>
+#ifndef _LIBC
+/* Get specification. */
+# include "strdup.h"
+#endif
-/* Get strlen, memcpy. */
+#include <stdlib.h>
#include <string.h>
+#undef __strdup
+#undef strdup
+
+#ifndef weak_alias
+# define __strdup strdup
+#endif
+
/* Duplicate S, returning an identical malloc'd string. */
char *
-strdup (const char *s)
+__strdup (const char *s)
{
size_t len = strlen (s) + 1;
void *new = malloc (len);
@@ -38,3 +48,9 @@
return (char *) memcpy (new, s, len);
}
+#ifdef libc_hidden_def
+libc_hidden_def (__strdup)
+#endif
+#ifdef weak_alias
+weak_alias (__strdup, strdup)
+#endif
--- /home/cvs/gsasl/lib/gl/strdup.h 2004/09/26 07:19:16 1.4
+++ /home/cvs/gsasl/lib/gl/strdup.h 2004/09/28 23:17:23 1.5
@@ -1,27 +1,27 @@
-/* Copyright (C) 2004 Simon Josefsson
+/* strdup.h -- duplicate a string
+ Copyright (C) 2004 Free Software Foundation, Inc.
- The file 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.
+ This program 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, or (at your option)
+ any later version.
- This file is distributed in the hope that it will be useful,
+ This program 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.
+ 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 this file; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
- USA. */
+ You should have received a copy of the GNU Lesser General Public License
+ along with this program; if not, write to the Free Software Foundation,
+ Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#ifndef STRDUP_H_
-# define STRDUP_H_
+#define STRDUP_H_
-/* Get strdup, if available. */
+/* Get strdup declaration, if available. */
#include <string.h>
-#if defined HAVE_DECL_STRDUP && !HAVE_DECL_STRDUP
+#if defined HAVE_DECL_STRDUP && !HAVE_DECL_STRDUP && !defined strdup
/* Duplicate S, returning an identical malloc'd string. */
extern char *strdup (const char *s);
#endif