Commit 0fbd5569 authored by Alexandre Julliard's avatar Alexandre Julliard

libport: Add a stub replacement for symlink().

parent 921e6624
......@@ -17787,6 +17787,7 @@ esac
for ac_func in \
_pclose \
_popen \
......@@ -17851,6 +17852,7 @@ for ac_func in \
strtold \
strtoll \
strtoull \
symlink \
tcgetattr \
thr_kill2 \
timegm \
......
......@@ -1417,6 +1417,7 @@ AC_CHECK_FUNCS(\
strtold \
strtoll \
strtoull \
symlink \
tcgetattr \
thr_kill2 \
timegm \
......
......@@ -765,6 +765,9 @@
/* Define to 1 if `st_mtim' is member of `struct stat'. */
#undef HAVE_STRUCT_STAT_ST_MTIM
/* Define to 1 if you have the `symlink' function. */
#undef HAVE_SYMLINK
/* Define to 1 if you have the <syscall.h> header file. */
#undef HAVE_SYSCALL_H
......
......@@ -341,6 +341,10 @@ int strcasecmp(const char *str1, const char *str2);
# endif
#endif /* !defined(HAVE_STRCASECMP) */
#ifndef HAVE_SYMLINK
int symlink(const char *from, const char *to);
#endif
#ifndef HAVE_USLEEP
int usleep (unsigned int useconds);
#endif /* !defined(HAVE_USLEEP) */
......
......@@ -29,6 +29,7 @@ C_SRCS = \
strcasecmp.c \
strerror.c \
strncasecmp.c \
symlink.c \
usleep.c
all: $(MODULE)
......
/*
* symlink function
*
* Copyright 2008 Alexandre Julliard
*
* This 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.
*
* This 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 this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
#include "config.h"
#include "wine/port.h"
#include <errno.h>
#include <stdio.h>
#ifdef HAVE_UNISTD_H
# include <unistd.h>
#endif
#ifndef HAVE_SYMLINK
int symlink( const char *from, const char *to )
{
errno = ENOSYS;
return -1;
}
#endif /* HAVE_SYMLINK */
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment