[installer][target] add debug logging. refactor code so we can actually get gui updates