From 5d4bdf33681ad680b252246b208d53a556921b31 Mon Sep 17 00:00:00 2001 From: Zach Kelling Date: Sat, 3 Jan 2026 06:55:59 -0800 Subject: [PATCH] build: CGO_ENABLED=1 default for C++/GPU backends - CGO_ENABLED?=1 allows C++/GPU acceleration by default - Allow CGO_ENABLED=0 override for pure Go builds --- Makefile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Makefile b/Makefile index 5b83f597..af263386 100644 --- a/Makefile +++ b/Makefile @@ -10,9 +10,12 @@ BUILD_DIR := build # Go build flags GOARCH := $(shell go env GOARCH) GOOS := $(shell go env GOOS) +CGO_ENABLED ?= 1 CGO_CFLAGS := -O -D__BLST_PORTABLE__ LDFLAGS := -X github.com/luxfi/netrunner/cmd.Version=$(VERSION) -X github.com/luxfi/netrunner/cmd.Commit=$(COMMIT) -X github.com/luxfi/netrunner/cmd.BuildDate=$(BUILD_DATE) +export CGO_ENABLED + # Default target .PHONY: all all: build