From 17ca75f405da6e71a3dc763dd9965943e585217e Mon Sep 17 00:00:00 2001 From: Dengda98 Date: Sat, 9 May 2026 18:19:58 +0800 Subject: [PATCH] STYLE: update information in logo window --- pygrt/C_extension/Makefile | 3 ++- pygrt/C_extension/include/grt/common/logo.h | 6 +++--- pygrt/C_extension/include/grt/common/version.h | 5 +++++ 3 files changed, 10 insertions(+), 4 deletions(-) diff --git a/pygrt/C_extension/Makefile b/pygrt/C_extension/Makefile index 23c676a2..d4d83917 100644 --- a/pygrt/C_extension/Makefile +++ b/pygrt/C_extension/Makefile @@ -8,6 +8,7 @@ LIBS_NAME := lib$(LNAME).a LIBD_NAME := lib$(LNAME).so VERSION := v$(shell cat version ) +DATE := $(shell date +%Y-%m-%d) # link options for FFTW @@ -47,7 +48,7 @@ CFLAGS2 := # at least for now, it's not a big problem. CFLAGS := -O3 -std=gnu99 \ -fPIC -Wall -Wextra -I$(shell realpath $(INC_DIR)) $(CFLAGS2) \ - -DGRT_VERSION=\"$(VERSION)\" -D_GNU_SOURCE $(ARCH) $(FOMPFLAGS) + -DGRT_VERSION=\"$(VERSION)\" -DGRT_DATE=\"$(DATE)\" -D_GNU_SOURCE $(ARCH) $(FOMPFLAGS) # -fdump-tree-all -g -ffast-math -O3 -fno-associative-math -march=native -mtune=native # -Wconversion -Wsign-conversion -Wfloat-conversion -Wcast-qual -Wcast-align diff --git a/pygrt/C_extension/include/grt/common/logo.h b/pygrt/C_extension/include/grt/common/logo.h index 5f148060..a543ad44 100644 --- a/pygrt/C_extension/include/grt/common/logo.h +++ b/pygrt/C_extension/include/grt/common/logo.h @@ -44,14 +44,14 @@ printf(BOLD_GREEN "\n" "║ Code Homepage: https://github.com/Dengda98/PyGRT ║\n" "║ License: GPL-3.0 license ║\n" "║ Version: %-20s ║\n" +"║ Last Update: %-20s ║\n" "║ ║\n" "║ ║\n" "║ A Command-Line Tool for Computing Synthetic Seismograms ║\n" "║ in Horizontally Layered Halfspace Model, ║\n" -"║ using Generalized Reflection-Transmission Method(GRTM) ║\n" -"║ and Discrete Wavenumber Method(DWM). ║\n" +"║ based on Generalized Reflection-Transmission Method (GRTM) ║\n" "║ ║\n" "╚═══════════════════════════════════════════════════════════════╝\n" -DEFAULT_RESTORE, GRT_VERSION); +DEFAULT_RESTORE, GRT_VERSION, GRT_DATE); } \ No newline at end of file diff --git a/pygrt/C_extension/include/grt/common/version.h b/pygrt/C_extension/include/grt/common/version.h index 94e75841..59f77f79 100644 --- a/pygrt/C_extension/include/grt/common/version.h +++ b/pygrt/C_extension/include/grt/common/version.h @@ -13,3 +13,8 @@ #define GRT_VERSION "none" ///< 默认值,编译时会被替换 #endif + +#ifndef GRT_DATE +#define GRT_DATE "none" ///< 默认值,编译时会被替换 + +#endif \ No newline at end of file