How would one call a (sort of makeshift) lock on a door (not a shutter) that consists of a hook and eye like the one in the image below?
This is needed for a work of fiction, so a paraphrase would be fine.
It's a Cabin Hook.
cabin hook noun
Definition of CABIN HOOK
: a small hook and eye for use on cabinet doors
First Known Use of CABIN HOOK 1845
They are also used to hold outward opening doors (for example patio doors) against a wall (to stop the doors blowing closed in a strong wind).
Also used to fasten outward opening doors on boats.
I think the word you want is latch.
Lock would imply you need a key or some other device to open it.
This is not a makeshift lock!
Makeshift does not mean 'simple', 'basic' or 'primitive'! It means 'created in an emergency out of whatever materials are to hand'. For example, you might take off your white shirt and tie it to a pole to create a makeshift flag of surrender.
A 'lock' is a secure closing device operated by a key or a numerical combination. What you have in the picture is a latch; specifically a 'hook-and-eye' latch.