nitc :: MModule :: makefile_path
private fun makefile_path: nullable String do
var file = location.file
if file == null then return null
var dir = file.filename.dirname
var makefile = (dir / "Makefile")
if not makefile.file_exists then return null
for line in makefile.to_path.read_lines do
if line.has_prefix("{name}:") then return makefile
end
return null
end
src/nitpackage.nit:437,2--449,4