The way your model is structure produces a conflict on the tempclk
signal. The assignment
tempclk <= '0';
is providing a constant '0' driver while the main: process is driving
a different value. The main: process's driving value is initially
'U', so the combined resolved value of tempclk will be 'X'.
The simplest solution is to eliminate the tempclk <= '0' assignment
and instead, initialize the tempclk signal in it's declaration:
signal tempclk : std_logic := '0';
This will reduce the number of drivers from 2 to 1.
-Brian