when you instantiate a component, if you have created a component for it (you do not need to declare the component btw), you simply instantiate it like this:
add : adder
generic map (....etc
PS, I notice in your component you have no generic, but on the entity you do. You wil need to fix this or you will get an error when you try and map the component to the entity (hence why components are fairly redundant).
Direct instantiation is done like this:
Code:
add : entity work.adder
generic map (
...etc
for the other errors, you have used positional association with signals that do not exist. in your testbench the signals are A1, B1 etc, so the map should be:
Code:
add : adder
generic map (32)
port map (A1, B1, Cin, Sum1, Cout);
but even better, used named association:
Code:
add : entity work.adder
generic map (N => 32)
port map(
A => A1,
B => B1,
Cin => Cin,
Sum => Sum1,
Cout => Cout
);