[yosys] 20/38: Added "yosys-config --build modname.so cppsources.."

Ruben Undheim rubund-guest at moszumanska.debian.org
Mon Feb 9 19:36:47 UTC 2015


This is an automated email from the git hooks/post-receive script.

rubund-guest pushed a commit to tag upstream/0.5.0
in repository yosys.

commit bbfc1bd7cf8dfe345a9593fe120648374811b6d3
Author: Clifford Wolf <clifford at clifford.at>
Date:   Sun Feb 8 00:14:07 2015 +0100

    Added "yosys-config --build modname.so cppsources.."
---
 misc/yosys-config.in | 14 ++++++++++++--
 1 file changed, 12 insertions(+), 2 deletions(-)

diff --git a/misc/yosys-config.in b/misc/yosys-config.in
index 8f8dd06..defb09c 100644
--- a/misc/yosys-config.in
+++ b/misc/yosys-config.in
@@ -3,7 +3,8 @@
 help() {
 	{
 		echo ""
-		echo "Usage: $0 [-exec] [--prefix pf] args.."
+		echo "Usage: $0 [--exec] [--prefix pf] args.."
+		echo "       $0 --build modname.so cppsources.."
 		echo ""
 		echo "Replecement args:"
 		echo "    --cxx         @CXX@"
@@ -15,10 +16,14 @@ help() {
 		echo ""
 		echo "All other args are passed trhough as they are."
 		echo ""
-		echo "Use -exec to call a command instead of generating output. Example usage:"
+		echo "Use --exec to call a command instead of generating output. Example usage:"
 		echo ""
 		echo "  yosys-config --exec --cxx --cxxflags --ldflags -o plugin.so -shared plugin.cc --ldlibs"
 		echo ""
+		echo "The above command can be abbreviated as:"
+		echo ""
+		echo "  yosys-config --build plugin.so plugin.cc"
+		echo ""
 		echo "Use --prefix to change the prefix for the special args from '--' to"
 		echo "something else. Example:"
 		echo ""
@@ -37,6 +42,11 @@ if [ $# -eq 0 ]; then
 	help
 fi
 
+if [ "$1" == "--build" ]; then
+	modname="$2"; shift 2
+	set -- --exec --cxx --cxxflags --ldflags -o "$modname" -shared "$@" --ldlibs
+fi
+
 prefix="--"
 get_prefix=false
 exec_mode=false

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/yosys.git



More information about the debian-science-commits mailing list