Development of a hybrid permanent-magnet undulator prototype for free electron lasers