build: robust pack handler - if gcc is not enabled, use uglify-js