# Makefile for building the Go module APP_NAME := maddy-hostux-check-password # Set the source directory SRC_DIR := . # Go files SRC := $(wildcard $(SRC_DIR)/*.go) # Build directory BUILD_DIR := ./build # Set the Go compiler GO := go # Flags for go build BUILD_FLAGS := -o $(BUILD_DIR)/$(APP_NAME) -tags netgo -ldflags "-s -w -extldflags '-static'" .PHONY: all build clean all: build build: $(BUILD_DIR)/$(APP_NAME) $(BUILD_DIR)/$(APP_NAME): $(SRC) @mkdir -p $(BUILD_DIR) $(GO) build $(BUILD_FLAGS) $(SRC_DIR) clean: rm -rf $(BUILD_DIR)