# --- T2-COPYRIGHT-NOTE-BEGIN --- # T2 SDE: package/*/embutils/xx-readlink.patch # Copyright (C) 2006 - 2023 The T2 SDE Project # # This Copyright note is generated by scripts/Create-CopyPatch, # more information can be found in the files COPYING and README. # # This patch file is dual-licensed. It is available under the license the # patched project is licensed under, as long as it is an OpenSource license # as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms # of the GNU General Public License version 2 as used by the T2 SDE. # --- T2-COPYRIGHT-NOTE-END --- A tiny readlnk I need (advanced features of the installer). - Rene Rebe diff -urN embutils-0.17/readlink.c embutils-0.17-patched/readlink.c --- embutils-0.17/readlink.c 1970-01-01 01:00:00.000000000 +0100 +++ embutils-0.17-patched/readlink.c 2005-12-19 00:13:23.000000000 +0100 @@ -0,0 +1,19 @@ + +#include +#include + +int main(int argc,char *argv[]) { + + char buf[PATH_MAX]; + int i; + + for (i=1; i 0) { + write(1,buf,n); + write(1,"\n",1); + return 0; + } + } + return 1; +} --- ./Makefile~ 2006-11-05 11:54:48.000000000 +0100 +++ ./Makefile 2006-11-05 11:54:53.000000000 +0100 @@ -15,5 +15,5 @@ printenv chrootuid renice \ -free losetup switch_root +free losetup switch_root readlink OS:=$(shell uname) ifeq ($(OS),Linux)