17 lines
446 B
Makefile
17 lines
446 B
Makefile
SHELL := /bin/bash
|
|
|
|
GOPATH?=$(shell go env GOPATH)
|
|
curr_dir := $(patsubst %/,%,$(dir $(abspath $(lastword $(MAKEFILE_LIST)))))
|
|
rest_args := $(wordlist 2, $(words $(MAKECMDGOALS)), $(MAKECMDGOALS))
|
|
$(eval $(rest_args):;@:)
|
|
|
|
help:
|
|
|
|
# Usage:
|
|
# make generate : generate a mapper based on a template.
|
|
#
|
|
@echo
|
|
|
|
make_rules := $(shell ls $(curr_dir)/hack/make-rules | sed 's/.sh//g')
|
|
$(make_rules):
|
|
@$(curr_dir)/hack/make-rules/$@.sh $(rest_args)
|