Skip to content

Instantly share code, notes, and snippets.

@mattolenik
Created June 23, 2021 17:37
Show Gist options
  • Save mattolenik/0e21606988d9dbf99d348a63cca175df to your computer and use it in GitHub Desktop.
Save mattolenik/0e21606988d9dbf99d348a63cca175df to your computer and use it in GitHub Desktop.
Get path of makefile within make, path of file itself, not working dir
MAKEFILE_PATH := $(shell dirname $(realpath $(firstword $(MAKEFILE_LIST)))) # Keep at top of file
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment