Skip to content

Commit

Permalink
#28 - add Makefile and target for listing targets
Browse files Browse the repository at this point in the history
  • Loading branch information
kittlerm committed Nov 1, 2022
1 parent 9b9783c commit d210ca7
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 2 deletions.
15 changes: 15 additions & 0 deletions CAD/src/build_manual/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
STL_DIR=../../src/build_manual/stl
#AMF_DIR=../../amf
IMG_DIR=png
SRC_DIR=../../src/build_manual/src
# DEP_DIR=../../dep
# GCD_DIR=../../gcode
# INI_DIR=../../slicing
GIT_ROOT=../../../
# FIXME: this should be '.' and STL files should be taken from ../../stl
OUTPUT_FOLDER=./src/build_manual/
NAME_PREFIX=TF-G2_bman
# FIXME: --no_render
PROCESSOR3D_PARAM=--no_gcode --no_amf

include ../../../utils/Makefile
22 changes: 20 additions & 2 deletions utils/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,9 @@ prepare_config:

default: $(AMF_TARGETS)
$(AMF_DIR)/%.amf: $(SRC_DIR)/%.scad
@echo "\n\n"
@echo -e "\n\n"
@echo $<
@echo "\n"
@echo -e "\n"
-processor3D \
--output_folder $(GIT_ROOT)/$(OUTPUT_FOLDER) \
--name_prefix $(NAME_PREFIX) \
Expand All @@ -38,6 +38,24 @@ $(AMF_DIR)/%.amf: $(SRC_DIR)/%.scad
finish:
cd $(GIT_ROOT)/CAD/slicing/; rm ./*.ini 2> /dev/null

PRINT_TARGETS =
ifdef AMF_DIR
PRINT_TARGETS += targets-amf
endif
ifdef GCD_DIR
PRINT_TARGETS += targets-gcd
endif

targets: ${PRINT_TARGETS}

targets-amf:
@echo "AMF_TARGETS:"
@echo " $(AMF_TARGETS)" | sed 's# #\n #g'

targets-gcd:
@echo "GCD_TARGETS:"
@echo " $(GCD_TARGETS)" | sed 's# #\n #g'

# gdefault: $(TARGETS)
# $(GCD_DIR)/%.gcode: $(SRC_DIR)/%.scad
# # @echo ============== $<
Expand Down

0 comments on commit d210ca7

Please sign in to comment.