|
|
@ -6,43 +6,47 @@ |
|
|
|
# the ./scripts/Create-CopyPatch script. Do not edit this copyright text! |
|
|
|
# |
|
|
|
# ROCK Linux: rock-src/package/base/dietlibc/gcc23_cmd.patch |
|
|
|
# ROCK Linux is Copyright (C) 1998 - 2003 Clifford Wolf |
|
|
|
# ROCK Linux is Copyright (C) 1998 - 2004 Clifford Wolf |
|
|
|
# |
|
|
|
# This program is free software; you can redistribute it and/or modify |
|
|
|
# it under the terms of the GNU General Public License as published by |
|
|
|
# the Free Software Foundation; either version 2 of the License, or |
|
|
|
# (at your option) any later version. A copy of the GNU General Public |
|
|
|
# License can be found at Documentation/COPYING. |
|
|
|
# |
|
|
|
# Many people helped and are helping developing ROCK Linux. Please |
|
|
|
# have a look at http://www.rocklinux.org/ and the Documentation/TEAM |
|
|
|
# file for details. |
|
|
|
# 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 as published by the Free Software |
|
|
|
# Foundation; either version 2 of the License, or (at your option) any later |
|
|
|
# version. |
|
|
|
# |
|
|
|
# --- ROCK-COPYRIGHT-NOTE-END --- |
|
|
|
|
|
|
|
This patch is needed because the diet wrapper is not correctly managing the |
|
|
|
gcc-* binary names correctly. It has to get more generalized and sent upstream. |
|
|
|
gcc-* binary names correctly. |
|
|
|
|
|
|
|
- Rene Rebe <rene@rocklinux.org> |
|
|
|
|
|
|
|
--- ./diet.c.orig 2002-10-15 01:27:50.000000000 +0200
|
|
|
|
+++ ./diet.c 2002-10-15 01:32:51.000000000 +0200
|
|
|
|
@@ -104,8 +104,10 @@
|
|
|
|
--- dietlibc-0.24/diet.c 2003-10-10 15:17:46.000000000 +0200
|
|
|
|
+++ dietlibc-0.24-fixed/diet.c 2004-01-02 17:12:43.000000000 +0100
|
|
|
|
@@ -105,9 +105,15 @@
|
|
|
|
} |
|
|
|
if (!argv[1]) goto usage; |
|
|
|
{ |
|
|
|
char *tmp=strchr(argv[1],0)-2; |
|
|
|
+ char *tmp4=strchr(argv[1],0)-4;
|
|
|
|
- char *tmp=strchr(argv[1],0)-2;
|
|
|
|
+ char *tmp=strchr(argv[1],0);
|
|
|
|
char *tmp2,*tmp3; |
|
|
|
char *cc=argv[1]; |
|
|
|
+ if (tmp4<cc) tmp4="";
|
|
|
|
+ /* try to find the char string "cc" - it might contain a version info */
|
|
|
|
+ while (tmp > argv[1] && *tmp != 'c')
|
|
|
|
+ tmp--;
|
|
|
|
+ while (tmp > argv[1] && *(tmp - 1) == 'c' )
|
|
|
|
+ tmp--;
|
|
|
|
+
|
|
|
|
if (tmp<cc) goto donttouch; |
|
|
|
if ((tmp2=strstr(cc,"linux-"))) { /* cross compiling? */ |
|
|
|
int len=strlen(platform); |
|
|
|
@@ -170,7 +172,8 @@
|
|
|
|
@@ -179,7 +185,7 @@
|
|
|
|
strcpy(shortplatform,"mipsel"); |
|
|
|
} |
|
|
|
strcat(dashL,platform); |
|
|
|
- if (!strcmp(tmp,"cc")) {
|
|
|
|
+ if (!strcmp(tmp,"cc") || !strcmp(tmp4,"cc-2") ||
|
|
|
|
+ !strcmp(tmp4,"cc-3") || !strcmp(tmp4,"cc-33")) {
|
|
|
|
+ if (!strncmp(tmp,"cc", 2)) {
|
|
|
|
char **newargv; |
|
|
|
char **dest; |
|
|
|
char *a,*b,*c; |