Skip to content

Commit

Permalink
Add conditional for nvfortran
Browse files Browse the repository at this point in the history
  • Loading branch information
minhqdao committed Feb 26, 2024
1 parent 9f5b509 commit e5b4177
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,11 @@ all: $(STATIC)

$(STATIC): $(SRC)
mkdir -p $(MOD-DIR) $(OBJ-DIR)
$(FC) $(FFLAGS) -c $(SRC) -J$(MOD-DIR) -o $(OBJ-DIR)/$(FILENAME).o
ifeq ($(FC),nvfortran)
$(FC) $(FFLAGS) -c $(SRC) -module $(MOD-DIR) -o $(OBJ-DIR)/$(FILENAME).o
else
$(FC) $(FFLAGS) -c $(SRC) -J$(MOD-DIR) -o $(OBJ-DIR)/$(FILENAME).o
endif
$(AR) $(ARFLAGS) $(STATIC) $(OBJ-DIR)/$(FILENAME).o

test: $(TEST-SRC) $(STATIC)
Expand Down

0 comments on commit e5b4177

Please sign in to comment.