# ------------------------------------- # Define general includes and libraries # ------------------------------------- $(info We Have Selected Arch $(ARCH) $(ARCHFLAG) $(ARCHDIR) ) $(info ) include ../../Makefile.common # ------------------------------------- # Define local includes and libraries # ------------------------------------- INCLUDES_LOCAL = -I../../leocat/trunk/include \ -I./include \ -I./src CC_FLAGS_LOCAL = $(INCLUDES_LOCAL) CCC_FLAGS_LOCAL = $(INCLUDES_LOCAL) # ------------------------------------- # C++ source and object files # ------------------------------------- #-- Algorithm Source files CPP_SRC_DIR = src CPP_SRC = $(CPP_SRC_DIR)/alg29.cpp \ $(CPP_SRC_DIR)/getcoord.cpp $(info CPP_SRC = $(CPP_SRC)) $(info ) #-- Algorithm Object files CPP_OBJS_DIR = $(ARCHDIR)/src CPP_OBJS = $(CPP_SRC:${CPP_SRC_DIR}/%.cpp=${CPP_OBJS_DIR}/%.o) $(info CPP_OBJS = $(CPP_OBJS)) $(info ) # --------------- # Dummy dependencies for the C++ source files # --------------- $(CPP_SRC) : # ----------------------- # C++ suffix rules # ----------------------- $(CPP_OBJS_DIR)/%.o : $(CPP_SRC_DIR)/%.cpp $(info ) $(CC) $(CC_FLAGS) $(CC_FLAGS_LOCAL) -o $@ $< # ------------------------------------- # C source and object files # ------------------------------------- #-- Algorithm Source files C_SRC_DIR = src C_SRC = $(C_SRC_DIR)/Antarctic_day.c \ $(C_SRC_DIR)/NightSnow_Inv_check.c \ $(C_SRC_DIR)/bl_int.c \ $(C_SRC_DIR)/check_bits.c \ $(C_SRC_DIR)/check_elem_edge.c \ $(C_SRC_DIR)/check_line_edge.c \ $(C_SRC_DIR)/check_reg_uniformity.c \ $(C_SRC_DIR)/chk_coast.c \ $(C_SRC_DIR)/chk_land.c \ $(C_SRC_DIR)/chk_land_night.c \ $(C_SRC_DIR)/chk_shallow_water.c \ $(C_SRC_DIR)/chk_spatial2.c \ $(C_SRC_DIR)/chk_spatial_var.c \ $(C_SRC_DIR)/chk_sunglint.c \ $(C_SRC_DIR)/cithr.c \ $(C_SRC_DIR)/clear_bit.c \ $(C_SRC_DIR)/collect_inputs.c \ $(C_SRC_DIR)/conf_test.c \ $(C_SRC_DIR)/conf_test_dble.c \ $(C_SRC_DIR)/create_250m_cm.c \ $(C_SRC_DIR)/create_cloud_mask.c \ $(C_SRC_DIR)/day_snow.c \ $(C_SRC_DIR)/get_b1_thresholds.c \ $(C_SRC_DIR)/get_cloud_adj.c \ $(C_SRC_DIR)/get_cm_thresholds.c \ $(C_SRC_DIR)/get_nl_thresholds.c \ $(C_SRC_DIR)/get_pn_thresholds.c \ $(C_SRC_DIR)/get_pxldat.c \ $(C_SRC_DIR)/get_regdif.c \ $(C_SRC_DIR)/get_regstd.c \ $(C_SRC_DIR)/get_sg_thresholds.c \ $(C_SRC_DIR)/get_stats.c \ $(C_SRC_DIR)/get_thr_values.c \ $(C_SRC_DIR)/land_day_250m.c \ $(C_SRC_DIR)/land_day.c \ $(C_SRC_DIR)/land_night.c \ $(C_SRC_DIR)/landday.c \ $(C_SRC_DIR)/landday_coast.c \ $(C_SRC_DIR)/landday_desert.c \ $(C_SRC_DIR)/landday_desert_c.c \ $(C_SRC_DIR)/landnight.c \ $(C_SRC_DIR)/massage_snowice.c \ $(C_SRC_DIR)/modis_cm_main.c \ $(C_SRC_DIR)/modis_planck_routines.c \ $(C_SRC_DIR)/night_snow.c \ $(C_SRC_DIR)/noncloud_obs_tests.c \ $(C_SRC_DIR)/ocean_day.c \ $(C_SRC_DIR)/ocean_night.c \ $(C_SRC_DIR)/perform_cloud_tests.c \ $(C_SRC_DIR)/perform_250m_tests.c \ $(C_SRC_DIR)/polar_day.c \ $(C_SRC_DIR)/polar_night.c \ $(C_SRC_DIR)/polarday_coast.c \ $(C_SRC_DIR)/polarday_desert.c \ $(C_SRC_DIR)/polarday_desert_c.c \ $(C_SRC_DIR)/polarday_land.c \ $(C_SRC_DIR)/polarday_ocean.c \ $(C_SRC_DIR)/polarday_snow.c \ $(C_SRC_DIR)/polarnight_land.c \ $(C_SRC_DIR)/polarnight_ocean.c \ $(C_SRC_DIR)/polarnight_snow.c \ $(C_SRC_DIR)/prepare_metadata.c \ $(C_SRC_DIR)/proc_path.c \ $(C_SRC_DIR)/read_thresholds_file.c \ $(C_SRC_DIR)/save_250m_info.c \ $(C_SRC_DIR)/set_bit.c \ $(C_SRC_DIR)/set_confdnc.c \ $(C_SRC_DIR)/set_qa_flags.c \ $(C_SRC_DIR)/snow_mask.c \ $(C_SRC_DIR)/spatial_var.c \ $(C_SRC_DIR)/swap_bytes.c \ $(C_SRC_DIR)/thin_cirrus_tests.c \ $(C_SRC_DIR)/trispc.c \ $(C_SRC_DIR)/water_day.c \ $(C_SRC_DIR)/water_day_250m.c \ $(C_SRC_DIR)/water_night.c $(info C_SRC = $(C_SRC)) $(info ) #-- Algorithm Object files C_OBJS_DIR = $(ARCHDIR)/src C_OBJS = $(C_SRC:${C_SRC_DIR}/%.c=${C_OBJS_DIR}/%.o) $(info C_OBJS = $(C_OBJS)) $(info ) # --------------- # Dummy dependencies for the C source files # --------------- $(C_SRC) : # ----------------------- # C suffix rules # ----------------------- $(C_OBJS_DIR)/%.o : $(C_SRC_DIR)/%.c $(info ) $(CCC) $(CCC_FLAGS) $(CCC_FLAGS_LOCAL) -o $@ $< # ------------------------------------- # Compile targets # ------------------------------------- ARLIB = libAlg29.a arlib : $(ARCHDIR)/$(ARLIB) # --------------- # Target rules # --------------- $(ARCHDIR)/$(ARLIB) : $(FOBJS) $(CPP_OBJS) $(C_OBJS) $(info ) ar -r $(ARCHDIR)/$(ARLIB) $(CPP_OBJS) $(C_OBJS) $(FOBJS) $(info ) $(COPY) $(ARCHDIR)/$(ARLIB) $(ALGLIB)/$(ARLIB) # -------- # Clean up # -------- clean: $(REMOVE) $(CPP_OBJS) $(C_OBJS) $(FOBJS) $(ARCHDIR)/$(ARLIB) $(ALGLIB)/$(ARLIB)