refactor: 移除旧子进程模式的 main.* 源文件,Makefile 只编译 DLL
- 删除 engines/c/main.c, engines/cpp/main.cpp, engines/fortran/main.f90 - Makefile 移除 all/exe 构建目标,默认只编译 DLL
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
# engines/cpp/Makefile
|
||||
# 编译 DLL(主程序通过 ctypes 直接调用)
|
||||
|
||||
CXX = g++
|
||||
SRCS = main.cpp
|
||||
LIB_SRC = dynamics_lib.cpp
|
||||
|
||||
UNAME_S := $(shell uname -s 2>/dev/null || echo Windows)
|
||||
@@ -15,8 +15,6 @@ else
|
||||
STATIC_FLAGS =
|
||||
endif
|
||||
|
||||
TARGET = build/dynamics_cpp.exe
|
||||
|
||||
ifeq ($(UNAME_S),Linux)
|
||||
DLL_TARGET = build/dynamics_cpp.so
|
||||
DLL_FLAGS = -shared -fPIC
|
||||
@@ -30,14 +28,10 @@ endif
|
||||
|
||||
.PHONY: all dll clean
|
||||
|
||||
all: $(TARGET)
|
||||
all: dll
|
||||
|
||||
dll: $(DLL_TARGET)
|
||||
|
||||
$(TARGET): $(SRCS) | build
|
||||
$(CXX) $(CXXFLAGS) $(STATIC_FLAGS) -o $@ $(SRCS)
|
||||
@echo " === C++ engine built: $@ ==="
|
||||
|
||||
$(DLL_TARGET): $(LIB_SRC) | build
|
||||
$(CXX) $(CXXFLAGS) $(STATIC_FLAGS) $(DLL_FLAGS) -o $@ $(LIB_SRC)
|
||||
@echo " === C++ DLL built: $@ ==="
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user