@@ -24,6 +24,7 @@ ENABLE_VERIFIC_LIBERTY := 0
2424ENABLE_COVER := 1
2525ENABLE_LIBYOSYS := 0
2626ENABLE_ZLIB := 1
27+ ENABLE_HELP_SOURCE := 0
2728
2829# python wrappers
2930ENABLE_PYOSYS := 0
@@ -109,18 +110,16 @@ PLUGIN_LINKFLAGS += -L"$(LIBDIR)"
109110PLUGIN_LIBS := -lyosys_exe
110111endif
111112
113+ ifeq ($(ENABLE_HELP_SOURCE ) ,1)
114+ CXXFLAGS += -DYOSYS_ENABLE_HELP_SOURCE
115+ endif
116+
112117PKG_CONFIG ?= pkg-config
113118SED ?= sed
114119BISON ?= bison
115120STRIP ?= strip
116121AWK ?= awk
117122
118- ifneq ($(shell :; command -v rsync),)
119- RSYNC_CP ?= rsync -rc
120- else
121- RSYNC_CP ?= cp -ru
122- endif
123-
124123ifeq ($(OS ) , Darwin)
125124PLUGIN_LINKFLAGS += -undefined dynamic_lookup
126125LINKFLAGS += -rdynamic
@@ -160,7 +159,7 @@ ifeq ($(OS), Haiku)
160159CXXFLAGS += -D_DEFAULT_SOURCE
161160endif
162161
163- YOSYS_VER := 0.55 +0
162+ YOSYS_VER := 0.56 +0
164163YOSYS_MAJOR := $(shell echo $(YOSYS_VER ) | cut -d'.' -f1)
165164YOSYS_MINOR := $(shell echo $(YOSYS_VER ) | cut -d'.' -f2 | cut -d'+' -f1)
166165YOSYS_COMMIT := $(shell echo $(YOSYS_VER ) | cut -d'+' -f2)
@@ -183,7 +182,7 @@ endif
183182OBJS = kernel/version_$(GIT_REV ) .o
184183
185184bumpversion :
186- sed -i " /^YOSYS_VER := / s/+[0-9][0-9]*$$ /+` git log --oneline 60f126c .. | wc -l` /;" Makefile
185+ sed -i " /^YOSYS_VER := / s/+[0-9][0-9]*$$ /+` git log --oneline 9c447ad .. | wc -l` /;" Makefile
187186
188187ABCMKARGS = CC="$(CXX ) " CXX="$(CXX ) " ABC_USE_LIBSTDCXX=1 ABC_USE_NAMESPACE=abc VERBOSE=$(Q )
189188
@@ -532,7 +531,6 @@ LIBS_VERIFIC += -Wl,--whole-archive $(patsubst %,$(VERIFIC_DIR)/%/*-linux.a,$(VE
532531endif
533532endif
534533
535-
536534ifeq ($(ENABLE_COVER ) ,1)
537535CXXFLAGS += -DYOSYS_ENABLE_COVER
538536endif
@@ -627,12 +625,14 @@ endif
627625$(eval $(call add_include_file,libs/sha1/sha1.h))
628626$(eval $(call add_include_file,libs/json11/json11.hpp))
629627$(eval $(call add_include_file,passes/fsm/fsmdata.h))
628+ $(eval $(call add_include_file,passes/techmap/libparse.h))
630629$(eval $(call add_include_file,frontends/ast/ast.h))
631630$(eval $(call add_include_file,frontends/ast/ast_binding.h))
632631$(eval $(call add_include_file,frontends/blif/blifparse.h))
633632$(eval $(call add_include_file,backends/rtlil/rtlil_backend.h))
634633
635634OBJS += kernel/driver.o kernel/register.o kernel/rtlil.o kernel/log.o kernel/calc.o kernel/yosys.o kernel/io.o kernel/gzip.o
635+ OBJS += kernel/log_help.o
636636OBJS += kernel/binding.o kernel/tclapi.o
637637OBJS += kernel/cellaigs.o kernel/celledges.o kernel/cost.o kernel/satgen.o kernel/scopeinfo.o kernel/qcsat.o kernel/mem.o kernel/ffmerge.o kernel/ff.o kernel/yw.o kernel/json.o kernel/fmt.o kernel/sexpr.o
638638OBJS += kernel/drivertools.o kernel/functional.o
@@ -867,6 +867,7 @@ MK_TEST_DIRS += tests/arch/nexus
867867MK_TEST_DIRS += tests/arch/quicklogic/pp3
868868MK_TEST_DIRS += tests/arch/quicklogic/qlf_k6n10f
869869MK_TEST_DIRS += tests/arch/xilinx
870+ MK_TEST_DIRS += tests/bugpoint
870871MK_TEST_DIRS += tests/opt
871872MK_TEST_DIRS += tests/sat
872873MK_TEST_DIRS += tests/sim
@@ -980,6 +981,12 @@ unit-test: libyosys.so
980981clean-unit-test :
981982 @$(MAKE ) -C $(UNITESTPATH ) clean
982983
984+ install-dev : $(PROGRAM_PREFIX ) yosys-config share
985+ $(INSTALL_SUDO ) mkdir -p $(DESTDIR )$(BINDIR )
986+ $(INSTALL_SUDO ) cp $(PROGRAM_PREFIX ) yosys-config $(DESTDIR )$(BINDIR )
987+ $(INSTALL_SUDO ) mkdir -p $(DESTDIR )$(DATDIR )
988+ $(INSTALL_SUDO ) cp -r share/. $(DESTDIR )$(DATDIR ) /.
989+
983990install : $(TARGETS ) $(EXTRA_TARGETS )
984991 $(INSTALL_SUDO ) mkdir -p $(DESTDIR )$(BINDIR )
985992 $(INSTALL_SUDO ) cp $(filter-out libyosys.so,$(TARGETS ) ) $(DESTDIR )$(BINDIR )
@@ -1027,19 +1034,8 @@ ifeq ($(ENABLE_PYOSYS),1)
10271034endif
10281035endif
10291036
1030- # also others, but so long as it doesn't fail this is enough to know we tried
1031- docs/source/cmd/abc.rst : $(TARGETS ) $(EXTRA_TARGETS )
1032- $(Q ) mkdir -p docs/source/cmd
1033- $(Q ) mkdir -p temp/docs/source/cmd
1034- $(Q ) cd temp && ./../$(PROGRAM_PREFIX ) yosys -p ' help -write-rst-command-reference-manual'
1035- $(Q ) $(RSYNC_CP ) temp/docs/source/cmd docs/source
1036- $(Q ) rm -rf temp
1037- docs/source/cell/word_add.rst : $(TARGETS ) $(EXTRA_TARGETS )
1038- $(Q ) mkdir -p docs/source/cell
1039- $(Q ) mkdir -p temp/docs/source/cell
1040- $(Q ) cd temp && ./../$(PROGRAM_PREFIX ) yosys -p ' help -write-rst-cells-manual'
1041- $(Q ) $(RSYNC_CP ) temp/docs/source/cell docs/source
1042- $(Q ) rm -rf temp
1037+ docs/source/generated/cmds.json : docs/source/generated $(TARGETS ) $(EXTRA_TARGETS )
1038+ $(Q ) ./$(PROGRAM_PREFIX ) yosys -p ' help -dump-cmds-json $@'
10431039
10441040docs/source/generated/cells.json : docs/source/generated $(TARGETS ) $(EXTRA_TARGETS )
10451041 $(Q ) ./$(PROGRAM_PREFIX ) yosys -p ' help -dump-cells-json $@'
@@ -1056,6 +1052,15 @@ docs/source/generated/functional/rosette.diff: backends/functional/smtlib.cc bac
10561052PHONY : docs/gen/functional_ir
10571053docs/gen/functional_ir : docs/source/generated/functional/smtlib.cc docs/source/generated/functional/rosette.diff
10581054
1055+ docs/source/generated/% .log : docs/source/generated $(TARGETS ) $(EXTRA_TARGETS )
1056+ $(Q ) ./$(PROGRAM_PREFIX ) yosys -qQT -h ' $*' -l $@
1057+
1058+ docs/source/generated/chformal.cc : passes/cmds/chformal.cc docs/source/generated
1059+ $(Q ) cp $< $@
1060+
1061+ PHONY : docs/gen/chformal
1062+ docs/gen/chformal : docs/source/generated/chformal.log docs/source/generated/chformal.cc
1063+
10591064PHONY : docs/gen docs/usage docs/reqs
10601065docs/gen : $(TARGETS )
10611066 $(Q ) $(MAKE ) -C docs gen
@@ -1091,7 +1096,7 @@ docs/reqs:
10911096 $(Q ) $(MAKE ) -C docs reqs
10921097
10931098.PHONY : docs/prep
1094- docs/prep : docs/source/cmd/abc.rst docs/source/generated/cells .json docs/gen docs/usage docs/gen/functional_ir
1099+ docs/prep : docs/source/generated/cells.json docs/source/generated/cmds .json docs/gen docs/usage docs/gen/functional_ir docs/gen/chformal
10951100
10961101DOC_TARGET ?= html
10971102docs : docs/prep
@@ -1115,7 +1120,7 @@ clean:
11151120 rm -f tests/tools/cmp_tbdata
11161121 rm -f $(addsuffix /run-test.mk,$(MK_TEST_DIRS ) )
11171122 -$(MAKE ) -C docs clean
1118- rm -rf docs/source/cmd docs/ util/__pycache__
1123+ rm -rf docs/util/__pycache__
11191124 rm -f * .whl
11201125 rm -f libyosys.so
11211126
@@ -1222,5 +1227,5 @@ echo-cxx:
12221227
12231228FORCE :
12241229
1225- .PHONY : all top-all abc test install install-abc docs clean mrproper qtcreator coverage vcxsrc
1230+ .PHONY : all top-all abc test install-dev install install-abc docs clean mrproper qtcreator coverage vcxsrc
12261231.PHONY : config-clean config-clang config-gcc config-gcc-static config-gprof config-sudo
0 commit comments