mirror of
https://git.haproxy.org/git/haproxy.git/
synced 2026-02-04 00:41:41 +01:00
Collecting captures of /sys isn't sufficient for NUMA development because haproxy detects the number of CPUs at boot time and will not be able to inspect more than this number. Let's just have a small utility to report a fake number of CPUs, that will be loaded using LD_PRELOAD. It checks the NCPU variable if it exists and will present this number of CPUs, or if it does not exist, will expose the maximum supported number.
16 lines
238 B
Makefile
16 lines
238 B
Makefile
include ../../include/make/verbose.mk
|
|
|
|
CC = cc
|
|
OPTIMIZE = -O2 -g
|
|
DEFINE =
|
|
INCLUDE =
|
|
OBJS = ncpu.so
|
|
|
|
all: $(OBJS)
|
|
|
|
%.so: %.c
|
|
$(cmd_CC) $(OPTIMIZE) $(DEFINE) $(INCLUDE) -fPIC -shared -o $@ $^
|
|
|
|
clean:
|
|
rm -f $(OBJS) *.[oas] *~
|