His pursuers were hard on his heels, so he hid in a thicket hard by. The first use of "hard" means close in time and the second use means close in distance. Was there an early use of "hard" just to mean close? Does a hard-edge abstraction refer to a painting in which changes occur close by? (This last question, seems to be a stretch, but I've never heard anyone talk about a hard-edge knife.) I know "hard on his heels" sounds like close in distance, but that's not how it's used: cf. Cambridge Dictionary Online come/follow hard/hot on the heels of sth "to happen very soon after something"
It is not the word "hard" but the word "by" that means "close to", as evidenced by this excerpt from etymonline.com:
by (prep.) - Old English be- (unstressed) or bi (stressed) "near, in, by, during, about," from Proto-Germanic *bi "around, about" (source also of Old Saxon and Old Frisian bi "by near," Middle Dutch bie, Dutch bij, German bei "by, at, near," Gothic bi "about"), from *umbi (cognate with second element in PIE *ambhi "around;" see ambi-).
In light of this, "hard" is likely meant as an intensifier, indicating that the thicket in your example sentence is very close to the man being pursued. This sense of the word "hard" is in turn evidenced by this excerpt from etymonline.com:
hard (adj.) - Old English heard "solid and firm, not soft," also, "difficult to endure, carried on with great exertion," also, of persons, "severe, rigorous, harsh, cruel," from Proto-Germanic *hardu- (source also of Old Saxon hard, Old Frisian herd, Dutch hard, Old Norse harðr "hard," Old High German harto "extremely, very," German hart, Gothic hardus "hard"), from PIE *kortu- (source also of Greek kratos "strength," kratys "strong"), suffixed form of root *kar-/*ker- "hard."