[ < ][]   [Contents][Index]

5.3 Linking rule

The rule used for the linking of the model file is not in the ‘Makefile.miniker’ file but should be provided in the user ‘Makefile’ for more flexibility. The default rule uses the variables miniker_user_objects for additional object files and LDADD for additionnal linking flags and files, those variables are there to be changed by the user.

The object files required by the Miniker code are in the make variable miniker_principal_objects, this variable is also used. The value of the variables FC for the Fortran compiler, FFLAGS for the Fortran compiler flags and LDFLAGS for the linker flags should be set to right values; LIBS should also be right and hold the link flags and link files required to compile the Miniker model. These variables are set by by ./configure during configuration (see Configuration) and used in the default rule:

$(model_file): $(miniker_user_objects) $(miniker_principal_objects)
	$(FC) $(FFLAGS) $(LDFLAGS) $^ $(LDADD) $(LIBS) -o $@

In case this isn’t right it may be freely changed. You should certainly refer to the Top in GNU Make Manual manual to understand what that rule exactly means and make your own.


[Contents][Index]