[Rd] configure, config.site and TCLTK_CPPFLAGS

Kurt Hornik Kurt.Hornik at wu-wien.ac.at
Tue Oct 28 19:35:54 MET 2003


>>>>> Peter Kleiweg writes:

> # aldus Kurt Hornik :
>> > I am trying to configure R-1.8.0-patched (fresh rsync) for machines
>> > with the tcltk files in unorthodox locations. I specified a
>> > TCLTK_CPPFLAGS='/usr/freeware/include/' in the file config.site but it
>> > seems that a '# no special path needed' is added when running
>> > configure, causing trouble (See the excerpt from config.site below).
>> > This was working with R-1.7.1. I am not an autoconf/configure expert,
>> > so any hint is welcome.
>> 
>> Could the "no special path needed" comment be something you added in one
>> of your config files?  I cannot seem to find it in the R sources ...

> See PR#1500

Thanks.

I looked into this a bit more.  Seems that Tcl/Tk 8.4 has gotten rid of
these "comments", the Tcl ChangeLog has

2002-07-23  Mo DeJong  <mdejong at users.sourceforge.net>

        * unix/tcl.m4 (SC_PATH_X): Set XINCLUDES to "" instead
        of "# no special path needed" or "# no include files found"
        when x headers cannot be located.

It also seems that the problem is with TK_XINCLUDES only.

Our current Autoconf code in m4/R.m4 does

  if test -n "${TK_XINCLUDES}"; then
    TCLTK_CPPFLAGS="${TCLTK_CPPFLAGS} ${TK_XINCLUDES}"
  else
    TCLTK_CPPFLAGS="${TCLTK_CPPFLAGS} ${X_CFLAGS}"
  fi

so we could do something like

  if test -n "${TK_XINCLUDES}"; then
    case ${TK_XINCLUDES} in
      #*) ;;
      *) TCLTK_CPPFLAGS="${TCLTK_CPPFLAGS} ${TK_XINCLUDES}" ;;
    esac
  else
    TCLTK_CPPFLAGS="${TCLTK_CPPFLAGS} ${X_CFLAGS}"
  fi

Untested: can anyone pls try this change?

Thanks
-k



More information about the R-devel mailing list