Same failure here for quite a while. Attached is a git format patch incorporating the suggested fix from the kde-core-devel ml in a hopefully correct mannor.
(Sorry if I didn't choose the correct bugzilla product, I couldn't find kde-workspace and since it seems to be related to kwin and Martin answered on the ml I chose kwin.)
Steps to Reproduce:
1. try to compile KDE/4.9 branch.
Created attachment 72569 [details]
Thanks for the patch, but it's already fixed as of git commit cb90b1e6a1125d41b55a7a608b1d917f84306070
In which branch has it been fixed? It doesn't seem to be in KDE/4.9, is this on purpose?
Git commit d929ac6da7adf6eea0452ed28bf55fd8ac16614a by Martin Gräßlin, on behalf of Guy Maurel.
Committed on 12/07/2012 at 19:22.
Pushed by graesslin into branch 'KDE/4.9'.
Cherry-Picked from cb90b1e6a1125d41b55a7a608b1d917f84306070
M +1 -0 kwin/scripting/workspace_wrapper.h