diff options
author | 2023-03-01 18:59:09 +0100 | |
---|---|---|
committer | 2023-03-01 18:59:09 +0100 | |
commit | 89f4c3aadd95a267403d47ac30b3d237cfb5bd5a (patch) | |
tree | 25259c2b71b20cb561b239ef8347e2009d3ef2fd | |
parent | 0873e1f108c1e3122a854778df73c221b9609cf9 (diff) | |
download | acme-scripts-89f4c3aadd95a267403d47ac30b3d237cfb5bd5a.tar.gz acme-scripts-89f4c3aadd95a267403d47ac30b3d237cfb5bd5a.zip |
Clean Makefile
-rw-r--r-- | Makefile | 22 |
1 files changed, 9 insertions, 13 deletions
@@ -1,23 +1,19 @@ INSTALL_DIR=~/bin/acme -BUILD_DIR=build -.SUFFIXES: .sh .o +SRC != ls -1 *.sh +OBJ = ${SRC:.sh=} +TGT = ${OBJ:%=${INSTALL_DIR}/%} -SOURCES!=ls *.sh -OBJECTS=${SOURCES:.sh=} -D!=echo $(OBJECTS) | sed "s|^|$(INSTALL_DIR)/|g" | sed "s| | $(INSTALL_DIR)/|g" +all: ${OBJ} .sh: - chmod +x ${.IMPSRC} - ln -s ${.CURDIR}/${.IMPSRC} ${.TARGET} - -build: $(OBJECTS) + ln -sf `realpath $<` $@ clean: - find ${.CURDIR} -type l -exec rm -f '{}' \; + rm -f ${OBJ} -install: build - find ${.CURDIR} -type l -exec cp -R -P '{}' ${INSTALL_DIR}/ \; +install: ${OBJ} + mv ${OBJ} ${INSTALL_DIR}/ uninstall: - rm -f $(D) + rm -f ${TGT} |