diff --git a/Makefile.in b/Makefile.in index 6972bda98..3a1f2b202 100644 --- a/Makefile.in +++ b/Makefile.in @@ -36,6 +36,8 @@ prefix = @prefix@ exec_prefix = @exec_prefix@ srcdir = @srcdir@ datarootdir = @datarootdir@ +VERSION_MAJOR = @VERSION_MAJOR@ +VERSION_MINOR = @VERSION_MINOR@ SUBDIRS = ivlpp vhdlpp vvp vpi tgt-null tgt-stub tgt-vvp \ tgt-vhdl tgt-vlog95 tgt-pcb tgt-blif tgt-sizer driver @@ -166,7 +168,7 @@ clean: $(foreach dir,$(SUBDIRS),$(MAKE) -C $(dir) $@ && ) true rm -f *.o parse.cc parse.h lexor.cc rm -f ivl.exp iverilog-vpi.man iverilog-vpi.pdf iverilog-vpi.ps - rm -f iverilog_man.ps iverilog_man.pdf iverilog_man_`./version.exe %M_%n`.pdf + rm -f iverilog_man.ps iverilog_man.pdf iverilog_man_$(VERSION_MAJOR)_$(VERSION_MINOR).pdf rm -f parse.output syn-rules.output dosify$(BUILDEXT) ivl@EXEEXT@ check.vvp rm -f lexor_keyword.cc libivl.a libvpi.a iverilog-vpi syn-rules.cc rm -rf dep @@ -279,9 +281,8 @@ lexor_keyword.o: lexor_keyword.cc parse.h lexor_keyword.cc: $(srcdir)/lexor_keyword.gperf gperf -o -i 7 -C -k 1-4,6,9,$$ -H keyword_hash -N check_identifier -t $< > $@ || (rm -f $@ ; false) -iverilog-vpi.man: $(srcdir)/iverilog-vpi.man.in version.exe - ./version.exe `head -1 $<`'\n' > $@ - tail -n +2 $< >> $@ +iverilog-vpi.man: $(srcdir)/iverilog-vpi.man.in + # generated by autoconf iverilog-vpi.ps: iverilog-vpi.man $(MAN) -t ./$< > $@ @@ -292,9 +293,9 @@ iverilog-vpi.pdf: iverilog-vpi.ps iverilog_man.ps: driver/iverilog.man vvp/vvp.man iverilog-vpi.man $(GROFF) -man -rC1 -rD1 -T ps $^ > $@ -iverilog_man.pdf: iverilog_man.ps version.exe +iverilog_man.pdf: iverilog_man.ps $(PS2PDF) $< $@ - cp $@ iverilog_man_`./version.exe %M_%n`.pdf + cp $@ iverilog-vpi.man_$(VERSION_MAJOR)_$(VERSION_MINOR).pdf # For VERSION_TAG in driver/main.c, first try git-describe, then look for a # release_tag.h file in the source tree (included in snapshots and releases), diff --git a/configure.ac b/configure.ac index 0521a8441..7b64c6897 100644 --- a/configure.ac +++ b/configure.ac @@ -7,6 +7,8 @@ AC_SUBST([VERSION_MAJOR], [VER_MAJOR]) AC_SUBST([VERSION_MINOR], [VER_MINOR]) AC_SUBST([VERSION_EXTRA], [" (VER_EXTRA)"]) AC_SUBST([VERSION], ["VER_MAJOR.VER_MINOR (VER_EXTRA)"]) +# used in res.rc +AC_SUBST([PRODUCTVERSION], ["VER_MAJOR,VER_MINOR,0,0"]) AC_CONFIG_SRCDIR([netlist.h]) AC_CONFIG_HEADERS([config.h]) @@ -374,5 +376,5 @@ then AC_MSG_ERROR(cannot configure white space in libdir: $libdir) fi AC_MSG_RESULT(ok) -AC_CONFIG_FILES([Makefile ivlpp/Makefile vhdlpp/Makefile vvp/Makefile vpi/Makefile driver/Makefile driver-vpi/Makefile cadpli/Makefile libveriuser/Makefile tgt-null/Makefile tgt-stub/Makefile tgt-vvp/Makefile tgt-vhdl/Makefile tgt-fpga/Makefile tgt-verilog/Makefile tgt-pal/Makefile tgt-vlog95/Makefile tgt-pcb/Makefile tgt-blif/Makefile tgt-sizer/Makefile version_base.h]) +AC_CONFIG_FILES([Makefile ivlpp/Makefile vhdlpp/Makefile vvp/Makefile vpi/Makefile driver/Makefile driver-vpi/Makefile cadpli/Makefile libveriuser/Makefile tgt-null/Makefile tgt-stub/Makefile tgt-vvp/Makefile tgt-vhdl/Makefile tgt-fpga/Makefile tgt-verilog/Makefile tgt-pal/Makefile tgt-vlog95/Makefile tgt-pcb/Makefile tgt-blif/Makefile tgt-sizer/Makefile version_base.h iverilog-vpi.man driver/iverilog.man driver-vpi/res.rc vvp/vvp.man]) AC_OUTPUT diff --git a/driver-vpi/Makefile.in b/driver-vpi/Makefile.in index bb8d66bc2..2403101e4 100644 --- a/driver-vpi/Makefile.in +++ b/driver-vpi/Makefile.in @@ -95,9 +95,8 @@ else endif # Windows specific... -res.rc: $(srcdir)/res.rc.in ../version.exe - sed -e 's;@PRODUCTVERSION@;'`../version.exe '%M,%n,0,0'`';' \ - $(srcdir)/res.rc.in > $@ +res.rc: $(srcdir)/res.rc.in + # generated by autoconf res.o: res.rc $(WINDRES) -i res.rc -o res.o diff --git a/driver/Makefile.in b/driver/Makefile.in index 38ab633a9..2ff6a9176 100644 --- a/driver/Makefile.in +++ b/driver/Makefile.in @@ -102,9 +102,8 @@ main.o: main.c globals.h $(srcdir)/../version_base.h ../version_tag.h Makefile | cflexor.o: cflexor.c cfparse.h -iverilog.man: $(srcdir)/iverilog.man.in ../version.exe - ../version.exe `head -1 $<`'\n' > $@ - tail -n +2 $< >> $@ +iverilog.man: $(srcdir)/iverilog.man.in + # generated by autoconf iverilog.ps: iverilog.man $(MAN) -t ./$< > $@ diff --git a/driver/iverilog.man.in b/driver/iverilog.man.in index 21dbf72dc..4ff682a48 100644 --- a/driver/iverilog.man.in +++ b/driver/iverilog.man.in @@ -1,4 +1,4 @@ -.TH iverilog 1 "Jan 13th, 2026" "" "Version %M.%n%E" +.TH iverilog 1 "Jan 13th, 2026" "" "Version @VERSION@" .SH NAME iverilog - Icarus Verilog compiler diff --git a/iverilog-vpi.man.in b/iverilog-vpi.man.in index 23741e1c2..13a85a586 100644 --- a/iverilog-vpi.man.in +++ b/iverilog-vpi.man.in @@ -1,4 +1,4 @@ -.TH iverilog-vpi 1 "Jan 13th, 2026" "" "Version %M.%n%E" +.TH iverilog-vpi 1 "Jan 13th, 2026" "" "Version @VERSION@" .SH NAME iverilog-vpi - Compile front end for VPI modules diff --git a/vvp/Makefile.in b/vvp/Makefile.in index 941ffdee1..eb674cbd4 100644 --- a/vvp/Makefile.in +++ b/vvp/Makefile.in @@ -185,9 +185,8 @@ parse%cc parse%h: $(srcdir)/parse%y lexor.cc: $(srcdir)/lexor.lex $(LEX) -s -o$@ $< -vvp.man: $(srcdir)/vvp.man.in ../version.exe - ../version.exe `head -1 $<`'\n' > $@ - tail -n +2 $< >> $@ +vvp.man: $(srcdir)/vvp.man.in + # generated by autoconf vvp.ps: vvp.man $(MAN) -t ./$< > $@ diff --git a/vvp/vvp.man.in b/vvp/vvp.man.in index c7d64d9b4..8da9ef816 100644 --- a/vvp/vvp.man.in +++ b/vvp/vvp.man.in @@ -1,4 +1,4 @@ -.TH vvp 1 "Jan 13th, 2026" "" "Version %M.%n %E" +.TH vvp 1 "Jan 13th, 2026" "" "Version @VERSION@" .SH NAME vvp - Icarus Verilog vvp runtime engine