"printf("line: %d \n", __LINE__);" does not work on System Workbench
I guess that you never have printf works before on the board, do you?
If you wish your printf shows on you debug console, that means you need setting to enable your semihosting on your code, your build settings and your debugger settings.