Skip to content

Commit db7a03d

Browse files
authored
keep flang-classic on MacOS from trying to create an executable instead of a library
1 parent 0e04710 commit db7a03d

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

exports/Makefile

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -142,10 +142,14 @@ ifneq (,$(filter 1 2,$(NOFORTRAN)))
142142
else
143143
ifeq ($(F_COMPILER), INTEL)
144144
$(FC) $(FFLAGS) $(LDFLAGS) -all-load -headerpad_max_install_names -install_name "$(CURDIR)/../$(INTERNALNAME)" -dynamiclib -o ../$(LIBDYNNAME) $< -Wl,-exported_symbols_list,osx.def
145+
else
146+
ifeq ($(F_COMPILER), FLANG)
147+
$(FC) $(FFLAGS) $(LDFLAGS) -fno-fortran-main -Mnomain -all_load -headerpad_max_install_names -install_name "$(CURDIR)/../$(INTERNALNAME)" -dynamiclib -o ../$(LIBDYNNAME) $< -Wl,-exported_symbols_list,osx.def $(FEXTRALIB)
145148
else
146149
$(FC) $(FFLAGS) $(LDFLAGS) -all_load -headerpad_max_install_names -install_name "$(CURDIR)/../$(INTERNALNAME)" -dynamiclib -o ../$(LIBDYNNAME) $< -Wl,-exported_symbols_list,osx.def $(FEXTRALIB)
147150
endif
148151
endif
152+
endif
149153

150154
dllinit.$(SUFFIX) : dllinit.c
151155
$(CC) $(CFLAGS) -c -o $(@F) -s $<

0 commit comments

Comments
 (0)