forwarding fix compiling ZunePaint on 64bit (and with certain compilers where cmp_nod...
[AROS-Ports.git] / devel / cflow / cflow-1.5-aros.diff
blob40ebc423bc1f0acb3d8ba52c723722ca7eced6b5
1 diff -Naur cflow-1.5-orig/src/rc.c cflow-1.5/src/rc.c
2 --- cflow-1.5-orig/src/rc.c 2017-08-01 00:22:09.440756945 +0200
3 +++ cflow-1.5/src/rc.c 2017-08-01 00:26:02.641823593 +0200
4 @@ -115,7 +115,11 @@
5 if (env)
6 parse_rc(&xargc, &xargv, env);
7 else {
8 +#if defined(__AROS__)
9 + char *home = "PROGDIR:";
10 +#else
11 char *home = getenv("HOME");
12 +#endif
13 if (home) {
14 int len = strlen(home);
15 char *buf = malloc(len + sizeof(LOCAL_RC)
16 @@ -123,8 +127,10 @@
17 if (!buf)
18 return;
19 strcpy(buf, home);
20 +#if !defined(__AROS__)
21 if (home[len-1] != '/')
22 buf[len++] = '/';
23 +#endif
24 strcpy(buf+len, LOCAL_RC);
25 parse_rc(&xargc, &xargv, buf);
26 free(buf);