Alexander Mai wrote:
> On Mon, 03 Sep 2001 18:20:28 +0200, Danny Backx wrote:
>
>
>>Alexander Mai wrote:
>>
>>>Could we have this in a file different then configure.in,
>>>and then manually create Xm.h from the Makefile just when
>>>this file would be touched?
>>>
>>Sounds horrible.
>>
>
> Hey, that's one of those "ingenious" features of my good old
> Makefiles used on OS/2 :-)
> There a rebuild is even triggered if changing compiler
> flags that might effect the output substantially ...
> And so to speak my set of dependencies is even superior
> to the auto* -based one.
>
>
>>The auto-tools do have a way to avoid rebuilding "config.h".
>>Can we use that ?
>>
One way is to do something like this for the headerfiles:
AC_CONFIG_FILES([include/Motif-1.2/Xm/Xm.h.tmp:include/Motif-1.2/Xm/Xm.h.in],
[if cmp -s include/Motif-1.2/Xm/Xm.h.tmp
include/Motif-1.2/Xm/Xm.h 2>/dev/null
then
AC_MSG_NOTICE([include/Motif-1.2/Xm/Xm.h is unchanged])
AC_MSG_NOTICE([deleting include/Motif-1.2/Xm/Xm.h.tmp])
rm -f include/Motif-1.2/Xm/Xm.h.tmp
else
AC_MSG_NOTICE([updating include/Motif-1.2/Xm/Xm.h])
rm -f include/Motif-1.2/Xm/Xm.h
mv include/Motif-1.2/Xm/Xm.h.tmp
include/Motif-1.2/Xm/Xm.h
fi])
Karsten Jensen