blob: ab95652ecdde334f9b51c2e9594766ba9ee03c03 [file] [log] [blame]
Norman Jamese2765102015-08-19 22:00:55 -05001CC=gcc
2OBJS = objects/pflash/progress.o objects/pflash/ast-sf-ctrl.o
3OBJS += objects/pflash/libflash/libflash.o objects/pflash/libflash/libffs.o
4OBJS += objects/pflash/arm_io.o
5LIBS=/gsa/ausgsa/home/n/j/njames/openbmc
6HOME = /media/sf_vbox/openbmc
7CFLAGS=$(shell pkg-config --libs --cflags gtk+-2.0 glib-2.0)
8
9%.o: interfaces/%.c
Norman Jamesddb97382015-08-27 21:31:31 -050010 $(CC) -c -o obj/$@ $< -I$(HOME) -I$(HOME)/includes $(CFLAGS)
Norman Jamese2765102015-08-19 22:00:55 -050011
12%.o: objects/%.c
Norman Jamesddb97382015-08-27 21:31:31 -050013 $(CC) -c -o obj/$@ $< -I$(HOME) -I$(HOME)/includes -I$(HOME)/objects/pflash $(CFLAGS)
14
15%.o: includes/%.c
16 $(CC) -c -o obj/$@ $< -I$(HOME) -I$(HOME)/includes -I$(HOME)/objects/pflash $(CFLAGS)
Norman Jamese2765102015-08-19 22:00:55 -050017
18%.o: objects/pflash/%.c
19 $(CC) -c -o obj/$@ $< -I$(HOME) -I$(HOME)/objects/pflash $(CFLAGS)
20
Norman James471ab592015-08-30 22:29:40 -050021power_control: control.o power_control_obj.o gpio.o
22 $(CC) -o bin/$@.exe obj/gpio.o obj/control.o obj/power_control_obj.o $(CFLAGS)
Norman Jamese2765102015-08-19 22:00:55 -050023
Norman Jamesddb97382015-08-27 21:31:31 -050024chassis_identify: led.o chassis_identify_obj.o gpio.o
25 $(CC) -o bin/$@.exe obj/gpio.o obj/led.o obj/chassis_identify_obj.o $(CFLAGS)
Norman Jamese2765102015-08-19 22:00:55 -050026
Norman James90baede2015-09-02 20:32:49 -050027sensor_ambient: sensor.o sensor_threshold.o sensor_temperature_ambient_obj.o
28 $(CC) -o bin/$@.exe obj/sensor_threshold.o obj/sensor.o obj/sensor_temperature_ambient_obj.o $(CFLAGS)
Norman Jamese2765102015-08-19 22:00:55 -050029
Norman Jamesddb97382015-08-27 21:31:31 -050030button_power: button.o button_power_obj.o gpio.o
Norman James1d08cef2015-08-25 07:15:58 -050031 $(CC) -o bin/$@.exe obj/button.o obj/button_power_obj.o $(CFLAGS)
Norman Jamese2765102015-08-19 22:00:55 -050032
33sensor_host_status: sensor.o sensor_host_status_obj.o
Norman James1d08cef2015-08-25 07:15:58 -050034 $(CC) -o bin/$@.exe obj/sensor.o obj/sensor_host_status_obj.o $(CFLAGS)
Norman Jamese2765102015-08-19 22:00:55 -050035
Norman James9e6acf92015-09-08 07:00:04 -050036sensor_occ: sensor.o sensor_occ_obj.o
37 $(CC) -o bin/$@.exe obj/sensor.o obj/sensor_occ_obj.o $(CFLAGS)
38
Norman James471ab592015-08-30 22:29:40 -050039control_host: control.o control_host_obj.o gpio.o
40 $(CC) -o bin/$@.exe obj/gpio.o obj/control.o obj/control_host_obj.o $(CFLAGS)
Norman Jamese2765102015-08-19 22:00:55 -050041
42flash_bios: pflash.o flash.o flash_bios_obj.o
Norman James1d08cef2015-08-25 07:15:58 -050043 $(CC) -o bin/$@.exe obj/flash.o obj/flash_bios_obj.o $(OBJS) $(CFLAGS)
Norman Jamese2765102015-08-19 22:00:55 -050044
Norman James471ab592015-08-30 22:29:40 -050045fan: fru.o fan_generic_obj.o gpio.o
46 $(CC) -o bin/$@.exe obj/gpio.o obj/fru.o obj/fan_generic_obj.o $(CFLAGS)
47
48fru_generic: fru.o fru_generic_obj.o
49 $(CC) -o bin/$@.exe obj/fru.o obj/fru_generic_obj.o $(CFLAGS)
50
Norman James90baede2015-09-02 20:32:49 -050051fru_board: fru.o fru_board_obj.o
52 $(CC) -o bin/$@.exe obj/fru.o obj/fru_board_obj.o $(CFLAGS)
Norman James471ab592015-08-30 22:29:40 -050053
54
Norman James9e6acf92015-09-08 07:00:04 -050055host_watchdog: watchdog.o host_watchdog_obj.o
56 $(CC) -o bin/$@.exe obj/watchdog.o obj/host_watchdog_obj.o $(CFLAGS)