Lines Matching refs:c
1 # Copyright (c) 2017-2026, Lawrence Livermore National Security, LLC and other CEED contributors.
147 CXXFLAGS.gcc := $(if $(STATIC),,-fPIC) -std=c++11 -Wall -Wextra -Wno-unused-parameter -MMD -MP
151 CXXFLAGS.XL := $(if $(STATIC),,-qpic) -std=c++11 -MMD
161 cc_check_flag = $(shell $(CC) -E -Werror $(1) -x c /dev/null > /dev/null 2>&1 && echo 1)
188 SYCLFLAGS ?= $(SYCL_FLAG) -fPIC -std=c++17 $(filter-out -std=c++11,$(CXXFLAGS)) $(filter-out $(OMP_SIMD_FLAG),$(OPT))
289 libceed.c := $(filter-out interface/ceed-cuda.c interface/ceed-hip.c interface/ceed-jit-source-root-$(if $(for_install),default,install).c, $(wildcard interface/ceed*.c backends/weak/*.c gallery/*.c))
290 gallery.c := $(wildcard gallery/*/ceed*.c)
291 libceed.c += $(gallery.c)
295 ref.c := $(sort $(wildcard backends/ref/*.c))
296 blocked.c := $(sort $(wildcard backends/blocked/*.c))
297 ceedmemcheck.c := $(sort $(wildcard backends/memcheck/*.c))
298 opt.c := $(sort $(wildcard backends/opt/*.c))
299 avx.c := $(sort $(wildcard backends/avx/*.c))
300 xsmm.c := $(sort $(wildcard backends/xsmm/*.c))
302 cuda.c := $(sort $(wildcard backends/cuda/*.c))
304 cuda-ref.c := $(sort $(wildcard backends/cuda-ref/*.c))
307 cuda-shared.c := $(sort $(wildcard backends/cuda-shared/*.c))
308 cuda-gen.c := $(sort $(wildcard backends/cuda-gen/*.c))
310 cuda-all.c := interface/ceed-cuda.c $(cuda.c) $(cuda-ref.c) $(cuda-shared.c) $(cuda-gen.c)
313 hip.c := $(sort $(wildcard backends/hip/*.c))
315 hip-ref.c := $(sort $(wildcard backends/hip-ref/*.c))
318 hip-shared.c := $(sort $(wildcard backends/hip-shared/*.c))
319 hip-gen.c := $(sort $(wildcard backends/hip-gen/*.c))
321 hip-all.c := interface/ceed-hip.c $(hip.c) $(hip-ref.c) $(hip-shared.c) $(hip-gen.c)
328 magma.c := $(sort $(wildcard backends/magma/*.c))
332 tests.c := $(sort $(wildcard tests/t[0-9][0-9][0-9]-*.c))
334 tests := $(tests.c:tests/%.c=$(OBJDIR)/%$(EXE_SUFFIX))
339 examples.c := $(sort $(wildcard examples/ceed/*.c))
341 examples := $(examples.c:examples/ceed/%.c=$(OBJDIR)/%$(EXE_SUFFIX))
356 rustqfunctions.c := $(sort $(wildcard examples/rust-qfunctions/*.c))
357 rustqfunctionsexamples := $(rustqfunctions.c:examples/rust-qfunctions/%.c=$(OBJDIR)/rustqfunctions-%)
360 petscexamples.c := $(wildcard examples/petsc/*.c)
361 petscexamples := $(petscexamples.c:examples/petsc/%.c=$(OBJDIR)/petsc-%)
364 fluidsexamples.c := $(sort $(wildcard examples/fluids/*.c))
365 fluidsexamples := $(fluidsexamples.c:examples/fluids/%.c=$(OBJDIR)/fluids-%)
368 solidsexamples.c := $(sort $(wildcard examples/solids/*.c))
369 solidsexamples := $(solidsexamples.c:examples/solids/%.c=$(OBJDIR)/solids-%)
487 libceed.c += $(ref.c)
488 libceed.c += $(blocked.c)
489 libceed.c += $(opt.c)
497 libceed.c += $(ceedmemcheck.c)
504 AVX := $(filter $(AVX_FLAG),$(shell $(CC) $(CFLAGS:-M%=) -v -E -x c /dev/null 2>&1))
508 libceed.c += $(avx.c)
533 libceed.c += $(xsmm.c)
534 $(xsmm.c:%.c=$(OBJDIR)/%.o) $(xsmm.c:%=%.tidy) : CPPFLAGS += -I$(XSMM_DIR)/include
550 libceed.c += interface/ceed-cuda.c
551 libceed.c += $(cuda-all.c)
563 $(hip-all.c:%.c=$(OBJDIR)/%.o) $(hip-all.c:%=%.tidy): CPPFLAGS += $(HIPCONFIG_CPPFLAGS)
569 libceed.c += $(hip-all.c)
590 MAGMA_ARCH=$(shell nm -g $(MAGMA_DIR)/lib/libmagma.* | grep -c "hipblas")
599 libceed.c += $(magma.c)
601 $(magma.c:%.c=$(OBJDIR)/%.o) $(magma.c:%=%.tidy) : CPPFLAGS += -DADD_ -I$(MAGMA_DIR)/include -I$(CUDA_DIR)/include
613 libceed.c += $(magma.c)
615 $(magma.c:%.c=$(OBJDIR)/%.o) $(magma.c:%=%.tidy) : CPPFLAGS += $(HIPCONFIG_CPPFLAGS) -I$(MAGMA_DIR)/include -I$(ROCM_DIR)/include -DCEED_MAGMA_USE_HIP -DADD_
655 # File names *-weak.c contain weak symbol definitions, which must be listed last
659 libceed.o = $(libceed.c:%.c=$(OBJDIR)/%.o) $(libceed.cpp:%.cpp=$(OBJDIR)/%.o) $(libceed.cu:%.cu=$(OBJDIR)/%.o) $(libceed.hip:%.hip.cpp=$(OBJDIR)/%.o) $(libceed.sycl:%.sycl.cpp=$(OBJDIR)/%.o)
668 $(OBJDIR)/%.o : $(CURDIR)/%.c | $$(@D)/.DIR
669 $(call quiet,CC) $(CPPFLAGS) $(CFLAGS) $(CONFIGFLAGS) -c -o $@ $(abspath $<)
672 $(call quiet,CXX) $(CPPFLAGS) $(CXXFLAGS) -c -o $@ $(abspath $<)
675 $(call quiet,NVCC) $(filter-out -Wno-unused-function, $(CPPFLAGS)) $(NVCCFLAGS) -c -o $@ $(abspath $<)
678 $(call quiet,HIPCC) $(CPPFLAGS) $(HIPCCFLAGS) -c -o $@ $(abspath $<)
681 $(call quiet,SYCLCXX) $(SYCLFLAGS) $(CPPFLAGS) -c -o $@ $(abspath $<)
684 $(call quiet,SYCLCXX) $(SYCLFLAGS) $(CPPFLAGS) -c -o $@ $(abspath $<)
686 $(OBJDIR)/%$(EXE_SUFFIX) : tests/%.c | $$(@D)/.DIR
687 $(call quiet,LINK.c) $(CEED_LDFLAGS) -o $@ $(abspath $<) $(CEED_LIBS) $(CEED_LDLIBS) $(LDLIBS) -I./tests/test-include
692 $(OBJDIR)/%$(EXE_SUFFIX) : examples/ceed/%.c | $$(@D)/.DIR
693 $(call quiet,LINK.c) $(CEED_LDFLAGS) -o $@ $(abspath $<) $(CEED_LIBS) $(CEED_LDLIBS) $(LDLIBS)
727 $(OBJDIR)/rustqfunctions-% : examples/rust-qfunctions/%.c $(libceed) | $$(@D)/.DIR
741 $(OBJDIR)/petsc-% : examples/petsc/%.c examples/petsc/libutils.a.PHONY $(libceed) $(ceed.pc) | $$(@D)/.DIR
747 $(OBJDIR)/fluids-% : examples/fluids/%.c examples/fluids/src/*.c examples/fluids/*.h examples/fluids/include/*.h examples/fluids/problems/*.c examples/fluids/qfunctions/*.h $(libceed) $(ceed.pc) examples/fluids/Makefile | $$(@D)/.DIR
753 $(OBJDIR)/solids-% : examples/solids/%.c examples/solids/%.h \
754 examples/solids/problems/*.c examples/solids/src/*.c \
856 GIT_DESCRIBE = $(shell git -c safe.directory=$PWD describe --always --dirty 2>/dev/null || printf "unknown\n")
940 format-c :
949 format : format-c format-py format-ot
961 %.c.tidy : %.c
965 $(CLANG_TIDY) $(TIDY_OPTS) $^ -- $(CPPFLAGS) --std=c++11 -I$(CUDA_DIR)/include -I$(ROCM_DIR)/include
967 tidy-c : $(libceed.c:%=%.tidy)
970 tidy : tidy-c tidy-cpp
1055 -include $(if $(filter B,$(MAKEFLAGS)),,$(libceed.c:%.c=$(OBJDIR)/%.d) $(tests.c:tests/%.c=$(OBJDIR)/%.d))