mirror of
https://gitlab.com/manzerbredes/paper-lowrate-iot.git
synced 2025-05-01 09:27:45 +00:00
25 lines
644 B
Makefile
25 lines
644 B
Makefile
|
|
EXEC=simulator
|
|
|
|
##### NS3 g++ Arguments
|
|
NS3_ARGS= -D NS3_LOG_ENABLE -L ${NS3_PATH}/build/lib -I ${NS3_PATH}/build/
|
|
NS3_ARGS+=$(addprefix -l, $(subst lib,,$(subst .so,,$(notdir $(wildcard ${NS3_PATH}/build/lib/*.so)))))
|
|
|
|
##### Source Files
|
|
SRC=main.cc modules/platform.cc modules/energy.cc modules/callbacks.cc
|
|
|
|
|
|
all: $(EXEC)
|
|
|
|
|
|
$(EXEC): $(SRC)
|
|
@echo -e "\e[32mDon't forget to define NS3_PATH env variable !\e[0m"
|
|
g++ $(NS3_ARGS) $(SRC) -o $@
|
|
@echo -e "\e[32mRun the following command before running $(EXEC):\e[0m"
|
|
@echo -e "\e[32mexport LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:${NS3_PATH}/build/lib\e[0m"
|
|
|
|
clean:
|
|
- rm $(EXEC)
|
|
|
|
|
|
.PHONY: clean
|