@@ -171,16 +171,18 @@ else
171171 endif
172172endif
173173
174- # Define SEDI.
175- # When calling "sed -i" on macOS, it is obligatory to specify a string (e.g., .bak) after -i as the
176- # extension for saving a backup. If the string is "", then no backup will be saved. If no string is
177- # specified, then an error will be raised, saying "invalid command code".
178- SEDI :=
179- ifeq ($(OSTYPE), MAC)
180- SEDI = @sed -i ""
181- else
182- SEDI = @sed -i
183- endif
174+ ## Define SEDI.
175+ ## When calling "sed -i" on macOS and FreeBSD, it is obligatory to specify a string (e.g., .bak)
176+ ## after -i as the extension for saving a backup. If the string is "", then no backup will be saved.
177+ ## If no string is specified, then an error will be raised, saying "invalid command code".
178+ #SEDI :=
179+ #ifeq ($(OSTYPE), MAC)
180+ # SEDI := sed -i ""
181+ #else ifeq ($(OSTYPE), FREEBSD)
182+ # SEDI := sed -i ""
183+ #else
184+ # SEDI := sed -i
185+ #endif
184186
185187## Define NPROCS to be the number of processors available to make tests in parallel.
186188#NPROCS :=
@@ -609,22 +611,6 @@ source_%: $(SRC_DIRS)
609611 fi
610612 @printf "Done.\n"
611613
612- # Adapt the header file for the test.
613- # Zaikun 20230411: Instead of modifying the header file, we should use the -D option of the
614- # preprocessors (cpp or fpp). See the definition of $(EXTRA_FLAGS) for details.
615- #header_%: IK = $(shell expr 8 \* $$(echo $@ | sed "s/.*_i//" | sed "s/_.*//"))
616- #header_%: RP = $(shell expr 8 \* $$(echo $@ | sed "s/.*_r//" | sed "s/_.*//"))
617- #header_%: DBG = $(shell echo $@ | sed "s/.*_d//" | sed "s/_.*//")
618- #header_%: QPAVLB = $(shell expr $$(echo $@ | sed "s/.*_r//" | sed "s/_.*//") / 16)
619- #header_%: source_%
620- # @if [[ -z "$(FINTRFH)" ]] ; then printf "\nfintrf.h is not available. Skip the test.\n"; exit 0; fi
621- # @printf "\nPreparing the header file for the test.\n"
622- # $(SEDI) "0,/^#define PRIMA_QP_AVAILABLE [0-9]*/s//#define PRIMA_QP_AVAILABLE $(QPAVLB)/" $(HEADERS)
623- # $(SEDI) "0,/^#define PRIMA_INTEGER_KIND [0-9]*/s//#define PRIMA_INTEGER_KIND $(IK)/" $(HEADERS)
624- # $(SEDI) "0,/^#define PRIMA_REAL_PRECISION [0-9]*/s//#define PRIMA_REAL_PRECISION $(RP)/" $(HEADERS)
625- # $(SEDI) "0,/^#define PRIMA_DEBUGGING [0-9]*/s//#define PRIMA_DEBUGGING $(DBG)/" $(HEADERS)
626- # @printf "Done.\n"
627-
628614
629615####################################################################################################
630616# Cleaning up.
0 commit comments