Friday, January 01, 2021

Re: cad/opensta build failure (cmake?)

Index: Makefile
===================================================================
RCS file: /cvs/ports/cad/opensta/Makefile,v
retrieving revision 1.8
diff -u -p -u -p -r1.8 Makefile
--- Makefile 25 Sep 2020 19:00:10 -0000 1.8
+++ Makefile 1 Jan 2021 13:38:30 -0000
@@ -5,6 +5,7 @@ COMMENT = Parallax Static Timing Analyze
GH_ACCOUNT = The-OpenROAD-Project
GH_PROJECT = OpenSTA
GH_TAGNAME = v2.2.0
+REVISION = 0
PKGNAME = ${DISTNAME:L}

CATEGORIES = cad
Index: patches/patch-CMakeLists_txt
===================================================================
RCS file: patches/patch-CMakeLists_txt
diff -N patches/patch-CMakeLists_txt
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-CMakeLists_txt 1 Jan 2021 13:38:30 -0000
@@ -0,0 +1,14 @@
+$OpenBSD$
+
+Index: CMakeLists.txt
+--- CMakeLists.txt.orig
++++ CMakeLists.txt
+@@ -291,7 +291,7 @@ add_flex_bison_dependency(SdfLex SdfParser)
+
+ ################################################################
+
+-find_package(SWIG REQUIRED 3.0)
++find_package(SWIG 3.0 REQUIRED)
+ include(UseSWIG)
+
+ set(STA_SWIG_FILE app/StaApp.i)
There is indeed a mistake in find_package usage (in CMakelist.txt),
whose correct syntax is:

find_package(<package> [version] [REQUIRED])

and not:

find_package(<package> [REQUIRED] [version])

(maybe the new cmake is less forgiving...)

The proper fix has been already committed upstream, but no new release
is available yet; so we have to add a temporary patch.

diff attached, please let me know if it's OK.

Copying ports@

On 31/12/2020 13:38, Christian Weisgerber wrote:
> In my lastest amd64 bulk build, cad/opensta failed to build.
> This looks like it may have been triggered by the cmake 3.19.1 update.
>
> ------------------------------------------------------------------------
>>>> Building on amd64-1 under cad/opensta
> BDEPENDS = [devel/cmake;devel/cudd;devel/swig;devel/bison;devel/ninja;lang/tcl/8.6]
> DIST = [cad/opensta:OpenSTA-2.2.0.tar.gz]
> FULLPKGNAME = opensta-2.2.0
> RDEPENDS = [devel/cudd;lang/tcl/8.6]
> (Junk lock obtained for amd64-1 at 1609392157.61)
>>>> Running depends in cad/opensta at 1609392157.67
> last junk was in x11/kde-applications/kblackbox
> /usr/sbin/pkg_add -aI -Drepair cudd-3.0.0p0 swig-3.0.12p1 tcl-8.6.8p2
> was: /usr/sbin/pkg_add -aI -Drepair bison-3.3.2p2 cmake-3.19.1v0 cudd-3.0.0p0 ninja-1.10.2 swig-3.0.12p1 tcl-8.6.8p2
> /usr/sbin/pkg_add -aI -Drepair cudd-3.0.0p0 swig-3.0.12p1 tcl-8.6.8p2
> New and changed readme(s):
> /usr/local/share/doc/pkg-readmes/tcl-8.6
> --- +tcl-8.6.8p2 -------------------
> You may wish to add /usr/local/lib/tcl/tcl8.6/man to /etc/man.conf
>>>> Running show-prepare-results in cad/opensta at 1609392166.03
> ===> cad/opensta
> ===> opensta-2.2.0 depends on: bison-* -> bison-3.3.2p2
> ===> opensta-2.2.0 depends on: swig-* -> swig-3.0.12p1
> ===> opensta-2.2.0 depends on: tcl->=8.6,<8.7 -> tcl-8.6.8p2
> ===> opensta-2.2.0 depends on: cmake-* -> cmake-3.19.1v0
> ===> opensta-2.2.0 depends on: ninja->=1.5.1 -> ninja-1.10.2
> ===> opensta-2.2.0 depends on: cudd-* -> cudd-3.0.0p0
> ===> Verifying specs: c++ c++abi pthread tcl86 c m z cudd
> ===> found c++.5.0 c++abi.3.0 pthread.26.1 tcl86.1.8 c.96.0 m.10.1 z.5.0 cudd.0.0
> bison-3.3.2p2
> cmake-3.19.1v0
> cudd-3.0.0p0
> ninja-1.10.2
> swig-3.0.12p1
> tcl-8.6.8p2
> (Junk lock released for amd64-1 at 1609392166.90)
> distfiles size=4873166
>>>> Running patch in cad/opensta at 1609392166.96
> ===> cad/opensta
> ===> Checking files for opensta-2.2.0
> `/usr/ports/distfiles/OpenSTA-2.2.0.tar.gz' is up to date.
>>> (SHA256) OpenSTA-2.2.0.tar.gz: OK
> ===> Extracting for opensta-2.2.0
> ===> Patching for opensta-2.2.0
> ===> Compiler link: clang -> /usr/bin/clang
> ===> Compiler link: clang++ -> /usr/bin/clang++
> ===> Compiler link: cc -> /usr/bin/cc
> ===> Compiler link: c++ -> /usr/bin/c++
>>>> Running configure in cad/opensta at 1609392167.68
> ===> cad/opensta
> ===> Generating configure for opensta-2.2.0
> ===> Configuring for opensta-2.2.0
> cd /usr/obj/ports/opensta-2.2.0/OpenSTA-2.2.0/etc && perl -pi -e '$. == 1 && s!/\S*(?:/env\s+|bin/)(?:tcl|wi)sh\S*(\s+.+)?$!/usr/local/bin/tclsh8.6$1!;' -e '$. >= 3 && $. <= 30 && s!exec\s+(?:tcl|wi)sh.*$!exec /usr/local/bin/tclsh8.6 "\$0" \${1+"\$@"}!;' -e 'close ARGV if eof;' TclEncode.tcl SwigCleanup.tcl
> cd /usr/obj/ports/opensta-2.2.0/OpenSTA-2.2.0/test && perl -pi -e '$. == 1 && s!/\S*(?:/env\s+|bin/)(?:tcl|wi)sh\S*(\s+.+)?$!/usr/local/bin/tclsh8.6$1!;' -e '$. >= 3 && $. <= 30 && s!exec\s+(?:tcl|wi)sh.*$!exec /usr/local/bin/tclsh8.6 "\$0" \${1+"\$@"}!;' -e 'close ARGV if eof;' regression
> -- The CXX compiler identification is Clang 10.0.1
> -- Detecting CXX compiler ABI info
> -- Detecting CXX compiler ABI info - done
> -- Check for working CXX compiler: /usr/obj/ports/opensta-2.2.0/bin/c++ - skipped
> -- Detecting CXX compile features
> -- Detecting CXX compile features - done
> -- STA version: 2.2.0
> -- STA git sha: GITDIR-NOTFOUND
> -- System name: OpenBSD
> -- Compiler: Clang 10.0.1
> -- Build type: Release
> -- Build CXX_FLAGS:
> -- STA CXX_FLAGS:
> -- Install prefix: /usr/local
> -- Found FLEX: /usr/bin/flex (found version "2.5.39")
> -- Found BISON: /usr/local/bin/bison (found version "3.3.2")
> CMake Error at /usr/local/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:218 (message):
> Could NOT find SWIG (missing: 3.0) (found version "3.0.12")
> Call Stack (most recent call first):
> /usr/local/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:577 (_FPHSA_FAILURE_MESSAGE)
> /usr/local/share/cmake/Modules/FindSWIG.cmake:138 (find_package_handle_standard_args)
> CMakeLists.txt:294 (find_package)
>
> -- Configuring incomplete, errors occurred!
> See also "/usr/obj/ports/opensta-2.2.0/build-amd64/CMakeFiles/CMakeOutput.log".
>
> *** Error 1 in cad/opensta (/usr/ports/infrastructure/mk/bsd.port.mk:2889 'do-configure': @cd /usr/obj/ports/opensta-2.2.0/build-amd64 && /u...)
> *** Error 2 in cad/opensta (/usr/ports/infrastructure/mk/bsd.port.mk:2909 '/usr/obj/ports/opensta-2.2.0/build-amd64/.configure_done': @cd /u...)
> *** Error 2 in cad/opensta (/usr/ports/infrastructure/mk/bsd.port.mk:2587 'configure': @lock=opensta-2.2.0; export _LOCKS_HELD=" opensta-2....)
> ===> Exiting cad/opensta with an error
> *** Error 1 in /usr/ports (infrastructure/mk/bsd.port.subdir.mk:137 'configure': @: ${echo_msg:=echo}; : ${target:=configure}; for i in ; ...)
>>>> Ended at 1609392168.65
> Error: job failed with 512 on amd64-1 at 1609392168
>

--
Alessandro De Laurenzis
[mailto:just22@atlantide.mooo.com]
Web: http://www.atlantide.mooo.com
LinkedIn: http://it.linkedin.com/in/delaurenzis

No comments:

Post a Comment