When Enclave is uninstalled using
apt-get remove enclave systemd sets the enclave service as masked. Masked services cannot be started manually nor by the system at boot time.
The next time Enclave is installed on the same system, apt is unable to start the Enclave service and the installation fails.
To fix this, first check that the service is masked
$ sudo systemctl status enclave
Loaded: masked (Reason: Unit enclave.service is masked.)
Active: inactive (dead)
If the service is masked, we can use
systemctl to unmask it
$ sudo systemctl unmask enclave
Now the service is unmasked try the installation again and then manually start the service
$ sudo apt-get install enclave
$ sudo systemctl start enclave
We will fix this in a future release.