Files
go-i2p/Makefile

69 lines
1.7 KiB
Makefile
Raw Normal View History

2024-06-25 12:03:55 -04:00
RELEASE_TAG=0.0.1
2024-06-25 12:04:18 -04:00
RELEASE_VERSION=${RELEASE_TAG}
2024-06-25 12:02:11 -04:00
RELEASE_DESCRIPTION=`cat PASTA.md`
2017-08-27 09:11:13 -04:00
REPO := $(shell dirname $(realpath $(lastword $(MAKEFILE_LIST))))
CGO_ENABLED=0
export DEBUG_I2P=debug
2017-08-27 09:11:13 -04:00
ifdef GOROOT
GO = $(GOROOT)/bin/go
endif
GO ?= $(shell which go)
ifeq ($(GOOS),windows)
EXE := $(REPO)/go-i2p.exe
else
EXE := $(REPO)/go-i2p
endif
2024-10-03 23:24:12 -04:00
#check for gofumpt
check_gofumpt:
@which gofumpt > /dev/null 2>&1 || (echo "gofumpt is required but not installed. Please install it from https://github.com/mvdan/gofumpt."; exit 1)
2017-08-27 09:11:13 -04:00
build: clean $(EXE)
$(EXE):
$(GO) build --tags netgo,osusergo -v -o $(EXE)
2017-08-27 09:11:13 -04:00
# Include test definitions
-include doc/tests/*.mk
test: test-string-all \
test-mapping-all \
test-crypto-aes-all \
test-crypto-dsa-all \
test-crypto-ed25519-all \
test-crypto-elg-all \
test-crypto-hmac-all \
test-i2np-header-all \
test-key-cert-all \
test-keys-cert-all \
test-lease-set-all \
test-noise-transport-all \
test-router-address-all \
test-router-info-all \
test-su3-all \
2024-11-30 17:43:51 -05:00
test-tunnel-all \
test-base32-encode-decode-not-mangled \
test-base64-encode-decode-not-mangled \
test-lease-all \
test-date-time-from-milliseconds
2017-08-27 09:11:13 -04:00
clean:
$(GO) clean -v
fmt:
find . -name '*.go' -exec gofumpt -w {} \;
2024-06-25 11:57:52 -04:00
info:
echo "GOROOT: ${GOROOT}"
echo "GO: ${GO}"
echo "REPO: ${REPO}"
release:
2024-06-25 12:04:18 -04:00
github-release release -u go-i2p -r go-i2p -n "${RELEASE_VERSION}" -t "${RELEASE_TAG}" -d "${RELEASE_DESCRIPTION}" -p
godoc:
2025-02-26 20:52:16 -05:00
./callgraph.sh