-
Notifications
You must be signed in to change notification settings - Fork 1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
makefile: upload actions announce error when remote machine not set makefile: report destination directories when installing/uploading synchronizing makefiles for linux examples RF24_config.h - changed detection of makefile build minor configure/makefile improvements
- Loading branch information
1 parent
87b5545
commit 46824af
Showing
8 changed files
with
89 additions
and
168 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
############################################################################# | ||
# | ||
# Makefile for librf24 examples on Linux | ||
# | ||
# License: GPL (General Public License) | ||
# Author: gnulnulf <arco@appeltaart.mine.nu> | ||
# Date: 2013/02/07 (version 1.0) | ||
# | ||
# Description: | ||
# ------------ | ||
# use make all and make install to install the examples | ||
# | ||
|
||
SOURCES = ${PROGRAMS:=.cpp} | ||
|
||
all: ${PROGRAMS} | ||
|
||
${PROGRAMS}: ${SOURCES} | ||
${CXX} ${CFLAGS} -I${HEADER_DIR}/.. -I.. -L${LIB_DIR} -l${LIB} $@.cpp -o $@ | ||
|
||
clean: | ||
@echo "[Cleaning]" | ||
rm -rf $(PROGRAMS) | ||
|
||
install: all | ||
@echo "[Installing examples to $(EXAMPLES_DIR)]" | ||
@mkdir -p $(EXAMPLES_DIR) | ||
@for prog in $(PROGRAMS); do \ | ||
install -m 0755 $$prog $(EXAMPLES_DIR); \ | ||
done | ||
|
||
upload: all | ||
@echo "[Uploading examples to ${REMOTE}:${REMOTE_EXAMPLES_DIR}]" | ||
ifeq ($(REMOTE),) | ||
@echo "[ERROR] Remote machine not configured. Run configure with respective arguments." | ||
@exit 1 | ||
endif | ||
@ssh -q -t -p ${REMOTE_PORT} ${REMOTE} "mkdir -p ${REMOTE_EXAMPLES_DIR}" | ||
@ssh -q -t -p ${REMOTE_PORT} ${REMOTE} "mkdir -p /tmp/RF24_examples" | ||
@scp -q -P ${REMOTE_PORT} ${PROGRAMS} ${REMOTE}:/tmp/RF24_examples | ||
@for prog in $(PROGRAMS); do \ | ||
ssh -q -t -p ${REMOTE_PORT} ${REMOTE} "sudo install -m 0755 /tmp/RF24_examples/$${prog} ${REMOTE_EXAMPLES_DIR}"; \ | ||
done | ||
@ssh -q -t -p ${REMOTE_PORT} ${REMOTE} "rm -rf /tmp/RF24_examples" | ||
|
||
.PHONY: install upload |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
46824af
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
#231