1 Index: dietlibc-0.32/diet.c
2 ===================================================================
3 --- dietlibc-0.32.orig/diet.c 2009-03-17 00:17:58.000000000 +0100
4 +++ dietlibc-0.32/diet.c 2009-10-02 14:12:14.306929201 +0200
11 + if (!strcmp(argv[1],"ccache")) {
16 char *tmp=strchr(cc,0)-2;
18 if (tmp<cc) goto donttouch;
20 if (tmp3<tmp2) tmp2=tmp3;
21 if (tmp2-cc>90) error("platform name too long!\n");
22 shortplatform=platform+len;
23 - memmove(shortplatform,argv[1],(size_t)(tmp2-cc));
24 + memmove(shortplatform,cc,(size_t)(tmp2-cc));
25 platform[tmp2-cc+len]=0;
26 if (shortplatform[0]=='i' && shortplatform[2]=='8' && shortplatform[3]=='6') shortplatform[1]='3';
32 + if (strcmp(argv[1],"ccache") == 0) {
36 if (!strcmp(argv[2],"-V")) {
39 } else if (!memcmp(argv[2],"-V",2)) {
47 if (_link) { *dest++=(char*)nostdlib; *dest++=dashstatic; *dest++=dashL; }
51 if (_link) { *dest++=d; }
53 - for (i=2; i<argc; ++i) {
54 + if (strcmp(argv[1],"ccache") == 0) {
59 + for (i; i<argc; ++i) {
60 + if (strstr(argv[i],"isystem") != NULL)
63 if (!strcmp(argv[i],"-pthread")) {
64 *dest++="-D_REENTRANT";
65 if (_link) *dest++="-lpthread";
74 if (compile || _link) {