i'm new to makefile and i would like to perform several operations.

my current makefile is as follows:

```
OBJECTS=radio_listener.o radio_app_comm_func.o
TARGET_EXECUTABLE=radio_listener

# Default target
all: ${TARGET_EXECUTABLE}

# Compile all required .o files this way
%.o: %.c
    @echo "Compiling $<"
    @gcc -c -g -m32 $< -o $@ 

# Compile target exe by combining all objects
${TARGET_EXECUTABLE}: ${OBJECTS}
    @echo "Linking $@"
    @gcc ${OBJECTS} -g -m32 -o $@

# Cleanup rule
clean:
    @echo "Cleaning up..."
    @rm -f *.o ${TARGET_EXECUTABLE}
    @echo "Done."

.PHONY: clean all

```

**1.** Say I execute 'make'. then change a MACRO define in **radio\_app\_comm\_*types*.h**.

radio\_app\_comm\_types.h is included in **radio\_app\_comm\_func.h**.

after changing the MACRO, and executing 'make' again, i get *"Nothing to be done for 'all'*.

Obviously i somehow need to tell my Makefile, that radio\_app\_comm\_func.h, is dependent on radio\_app\_comm\_types.h. 

How to do this?

**2.** The 2nd thing that interest me, is how to use the same Makefile, dor different executables.

Currently i have only **radio\_listener** , but i plan on adding **radio\_control**,**radio\_server**, which their *h files* will also include **radio\_app\_comm\_func.h**, and maybe some other h files (in order to use the relevant .c files of them.

How can i achieve this?
I'm looking to implement a flow as follows:

***a)*** Executing **make**, will compile all relevant files for each of the exe's, and in the end will create 3 different executables for me - **radio\_listener, radio\_control, radio\_server**

***b)*** Executing **make server** (for example), will compile all relevant files that are needed **only** for **radio\_server** (including looking for changes, say, in **radio\_app\_comm\_types.h**) and finally will create only 1 executable - **radio\_server** for me

***c)*** Executing **make controller** ...compile all needed for radio\_control, etc (you get my meaning i guess)

I'm working on Ubuntu x64 system, if that's relevant.

Any help will be much appreciated. 

Thank you.