mirror of
git://projects.qi-hardware.com/cae-tools.git
synced 2025-04-21 12:27:27 +03:00
Make new/run/pov/disp are now configurable when invoking make.
Example: make NAME=lcdframe D=0.8 TOP=front BOTTOM=back new - solidify/Makefile (new, run, pov, disp): test run targets can now be configured by setting make variables on the command line - solidify/main.pov: renamed to template.pov and changed all occurrences of "batcvr" to "NAME" - solidify/Makefile: generate main.pov from template.pov
This commit is contained in:
@@ -53,27 +53,39 @@ spotless: clean
|
||||
|
||||
# ----- Experimental execution ------------------------------------------------
|
||||
|
||||
NAME=baseframe
|
||||
TOP=top
|
||||
BOTTOM=bottom
|
||||
D=0.86
|
||||
|
||||
PRJ=http://projects.qi-hardware.com/index.php/p/ben-scans/source/tree/master
|
||||
DIR=$(PRJ)/data/csv
|
||||
FACE_A=$(DIR)/ben-batcvr-outside-100um.txt.bz2
|
||||
FACE_B=$(DIR)/ben-batcvr-inside-100um.txt.bz2
|
||||
D=1.16
|
||||
FACE_A=$(DIR)/ben-$(NAME)-$(TOP)-100um.txt.bz2
|
||||
FACE_B=$(DIR)/ben-$(NAME)-$(BOTTOM)-100um.txt.bz2
|
||||
|
||||
|
||||
.PHONY: new run pov disp
|
||||
|
||||
# always regenerate main.pov, e.g., if NAME is changed via the command line
|
||||
.PHONY: main.pov
|
||||
|
||||
|
||||
new: solidify
|
||||
rm -f batcvr.sfy
|
||||
./solidify batcvr.sfy $(FACE_A) $(FACE_B) $(D) >batcvr.inc
|
||||
rm -f $(NAME).sfy
|
||||
./solidify $(NAME).sfy $(FACE_A) $(FACE_B) $(D) >$(NAME).inc
|
||||
|
||||
run: solidify
|
||||
./solidify batcvr.sfy >batcvr.inc
|
||||
./solidify $(NAME).sfy >$(NAME).inc
|
||||
|
||||
pov:
|
||||
povray +A +P -W1280 -H1024 main.pov
|
||||
pov: main.pov
|
||||
povray +A +P -W1280 -H900 main.pov
|
||||
|
||||
disp:
|
||||
display main.png
|
||||
|
||||
main.pov: template.pov
|
||||
sed 's/NAME/$(NAME)/' template.pov >$@ || { rm -f $@; exit 1; }
|
||||
|
||||
# ----- Dependencies ----------------------------------------------------------
|
||||
|
||||
# compile and generate dependencies, from fped, based on
|
||||
|
||||
Reference in New Issue
Block a user