cfengine/core — pull request #1047 by tzz (2013-10-28 15:48:21+00:00)
Title: datastate() function to provide the container used by default templates

This PR is to enable us to use the new `DefaultTemplateData` state function, which is the default used for Mustache templates when they are not given a data container. It enables us to acceptance-test Mustache templates and the state data for CFEngine.

I get compilation errors:

```
evalfunction.c: At top level:
./data_lib.h:30:14: warning: 'DefaultTemplateData' used but never defined [enabled by default]
CCLD libpromises.la
/usr/lib/gcc/x86_64-pc-linux-gnu/4.6.3/../../../../x86_64-pc-linux-gnu/bin/ld: .libs/evalfunction.o: warning: relocation against `DefaultTemplateData' in readonly section `.text'.
/usr/lib/gcc/x86_64-pc-linux-gnu/4.6.3/../../../../x86_64-pc-linux-gnu/bin/ld: .libs/evalfunction.o: relocation R_X86_64_PC32 against symbol `DefaultTemplateData' can not be used when making a shared object; recompile with -fPIC
/usr/lib/gcc/x86_64-pc-linux-gnu/4.6.3/../../../../x86_64-pc-linux-gnu/bin/ld: final link failed: Bad value
```

and I'm not sure if a new `data_lib.[ch]` is the right place for this function. Please let me know and I'll redo. Also an acceptance test for this new function is still TODO for me.