fix ktest bug: isDefinitionKompiled check -d argument and default value of -d of programs should be set using -d of kompile
Merge pull request #1052 from osa1/ktest-bugfix

a ktest bug