[make] turn on gcc optimizations
[gen] fix faulty timeout setting for mosquitto_loop