cmake support for /opt/local CUDD install
This commit is contained in:
parent
20ab0a1f23
commit
37df007eca
|
|
@ -399,6 +399,7 @@ set(STA_TCL_FILES
|
||||||
dcalc/DelayCalc.tcl
|
dcalc/DelayCalc.tcl
|
||||||
parasitics/Parasitics.tcl
|
parasitics/Parasitics.tcl
|
||||||
sdf/Sdf.tcl
|
sdf/Sdf.tcl
|
||||||
|
tcl/Compatibility.tcl
|
||||||
verilog/Verilog.tcl
|
verilog/Verilog.tcl
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -431,12 +432,10 @@ endif()
|
||||||
################################################################
|
################################################################
|
||||||
#
|
#
|
||||||
# Locate CUDD bdd packagte
|
# Locate CUDD bdd packagte
|
||||||
|
# -DCUDD=0 to not use CUDD.
|
||||||
# CUDD variable has precidence over environment variable.
|
# Look for library in CUDD/lib, CUDD/cudd/lib
|
||||||
if("${CUDD}" STREQUAL "")
|
# Look for header in CUDD/include, CUDD/cudd/include
|
||||||
set(CUDD $ENV{CUDD})
|
#
|
||||||
endif()
|
|
||||||
|
|
||||||
if("${CUDD}" STREQUAL "" OR "${CUDD}" STREQUAL "0")
|
if("${CUDD}" STREQUAL "" OR "${CUDD}" STREQUAL "0")
|
||||||
set(CUDD_INCLUDE "")
|
set(CUDD_INCLUDE "")
|
||||||
set(CUDD_LIB "")
|
set(CUDD_LIB "")
|
||||||
|
|
@ -444,12 +443,28 @@ if("${CUDD}" STREQUAL "" OR "${CUDD}" STREQUAL "0")
|
||||||
set(CUDD 0)
|
set(CUDD 0)
|
||||||
message(STATUS "CUDD library: not found")
|
message(STATUS "CUDD library: not found")
|
||||||
else()
|
else()
|
||||||
set(CUDD_INCLUDE ${CUDD}/include)
|
find_library(CUDD_LIB NAMES cudd PATHS ${CUDD}/lib ${CUDD}/lib/cudd)
|
||||||
find_library(CUDD_LIB NAMES cudd PATHS ${CUDD}/lib)
|
|
||||||
if (CUDD_LIB)
|
if (CUDD_LIB)
|
||||||
|
message(STATUS "CUDD library: ${CUDD_LIB}")
|
||||||
|
get_filename_component(CUDD_LIB_DIR "${CUDD_LIB}" PATH)
|
||||||
|
get_filename_component(CUDD_LIB_PARENT1 "${CUDD_LIB_DIR}" PATH)
|
||||||
|
get_filename_component(CUDD_LIB_PARENT2 "${CUDD_LIB_PARENT1}" PATH)
|
||||||
|
find_file(CUDD_HEADER cudd.h
|
||||||
|
PATHS ${CUDD}/include ${CUDD_LIB_PARENT2}/include/cudd)
|
||||||
|
if (CUDD_HEADER)
|
||||||
|
get_filename_component(CUDD_INCLUDE "${CUDD_HEADER}" PATH)
|
||||||
|
message(STATUS "CUDD header: ${CUDD_HEADER}")
|
||||||
# CUDD referenced by StaConfig.hh.cmake
|
# CUDD referenced by StaConfig.hh.cmake
|
||||||
set(CUDD 1)
|
set(CUDD 1)
|
||||||
message(STATUS "CUDD library: ${CUDD_LIB}")
|
else()
|
||||||
|
message(STATUS "CUDD header: not found")
|
||||||
|
endif()
|
||||||
|
else()
|
||||||
|
set(CUDD_INCLUDE "")
|
||||||
|
set(CUDD_LIB "")
|
||||||
|
set(CUDD_FOUND FALSE)
|
||||||
|
set(CUDD 0)
|
||||||
|
message(STATUS "CUDD library: not found")
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
|
|
||||||
29
README.md
29
README.md
|
|
@ -86,20 +86,20 @@ bison 1.35 3.0.4 2.3
|
||||||
flex 2.5.4 2.6.4 2.5.35
|
flex 2.5.4 2.6.4 2.5.35
|
||||||
```
|
```
|
||||||
|
|
||||||
These packages are optional:
|
These packages are **optional**:
|
||||||
|
|
||||||
```
|
```
|
||||||
libz 1.1.4 1.2.5 1.2.8
|
libz 1.1.4 1.2.5 1.2.8
|
||||||
cudd 2.4.1 3.0.0
|
cudd 2.4.1 3.0.0
|
||||||
```
|
```
|
||||||
|
|
||||||
CUDD is a binary decision diageram (BDD) package that is used to improve conditional timing arc handling. It is available [here](https://www.davidkebo.com/source/cudd_versions/cudd-3.0.0.tar.gz) or [here](https://sourceforge.net/projects/cudd-mirror/).
|
CUDD is a binary decision diageram (BDD) package that is used to improve conditional timing arc handling. OpenSTA does not require it to be installed. It is available [here](https://www.davidkebo.com/source/cudd_versions/cudd-3.0.0.tar.gz) or [here](https://sourceforge.net/projects/cudd-mirror/).
|
||||||
|
|
||||||
Note that the file hierarchy of the CUDD installation changed with version 3.0.
|
Note that the file hierarchy of the CUDD installation changed with version 3.0.
|
||||||
Some changes to the CMake are required to support older versions.
|
Some changes to CMakeLists.txt are required to support older versions.
|
||||||
|
|
||||||
You may use the `--prefix ` option to `configure` to install in a location other than
|
When building CUDD you may use the `--prefix ` option to `configure` to
|
||||||
the default (`/usr/local/lib`).
|
install in a location other than the default (`/usr/local/lib`).
|
||||||
```
|
```
|
||||||
cd $HOME/cudd-3.0.0
|
cd $HOME/cudd-3.0.0
|
||||||
mkdir $HOME/cudd
|
mkdir $HOME/cudd
|
||||||
|
|
@ -107,6 +107,21 @@ mkdir $HOME/cudd
|
||||||
make
|
make
|
||||||
make install
|
make install
|
||||||
```
|
```
|
||||||
|
To not use CUDD specify `CUDD=0`.
|
||||||
|
Cmake looks for the CUDD library in `CUDD/lib, CUDD/cudd/lib`
|
||||||
|
and for the header in `CUDD/include, CUDD/cudd/include`.
|
||||||
|
```
|
||||||
|
# equivalent to -DCUDD=0
|
||||||
|
cmake ..
|
||||||
|
or
|
||||||
|
cmake .. -DCUDD=0
|
||||||
|
or
|
||||||
|
# look in ~/cudd/lib, ~/cudd/include
|
||||||
|
cmake .. -DCUDD=$HOME/cudd
|
||||||
|
or
|
||||||
|
# look in /usr/local/lib/cudd, /usr/local/include/cudd
|
||||||
|
cmake .. -DCUDD=/usr/local
|
||||||
|
```
|
||||||
|
|
||||||
The Zlib library is an optional. If CMake finds libz, OpenSTA can
|
The Zlib library is an optional. If CMake finds libz, OpenSTA can
|
||||||
read Verilog, SDF, SPF, and SPEF files compressed with gzip.
|
read Verilog, SDF, SPF, and SPEF files compressed with gzip.
|
||||||
|
|
@ -121,7 +136,7 @@ git clone https://xp-dev.com/git/opensta
|
||||||
cd opensta
|
cd opensta
|
||||||
mkdir build
|
mkdir build
|
||||||
cd build
|
cd build
|
||||||
cmake .. -DCUDD=$HOME/cudd
|
cmake ..
|
||||||
make
|
make
|
||||||
```
|
```
|
||||||
The default build type is release to compile optimized code.
|
The default build type is release to compile optimized code.
|
||||||
|
|
@ -135,7 +150,7 @@ CMAKE_BUILD_TYPE DEBUG|RELEASE
|
||||||
CMAKE_CXX_FLAGS - additional compiler flags
|
CMAKE_CXX_FLAGS - additional compiler flags
|
||||||
TCL_LIB - path to tcl library
|
TCL_LIB - path to tcl library
|
||||||
TCL_HEADER - path to tcl.h
|
TCL_HEADER - path to tcl.h
|
||||||
CUDD - path to cudd installation ($HOME/cudd if following install shown above)
|
CUDD - path to cudd installation
|
||||||
ZLIB_ROOT - path to zlib
|
ZLIB_ROOT - path to zlib
|
||||||
CMAKE_INSTALL_PREFIX
|
CMAKE_INSTALL_PREFIX
|
||||||
```
|
```
|
||||||
|
|
|
||||||
|
|
@ -14,22 +14,6 @@
|
||||||
// You should have received a copy of the GNU General Public License
|
// You should have received a copy of the GNU General Public License
|
||||||
// along with this program. If not, see <https://www.gnu.org/licenses/>.
|
// along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
// OpenSTA, Static Timing Analyzer
|
|
||||||
// Copyright (c) 2019, Parallax Software, Inc.
|
|
||||||
//
|
|
||||||
// This program is free software: you can redistribute it and/or modify
|
|
||||||
// it under the terms of the GNU General Public License as published by
|
|
||||||
// the Free Software Foundation, either version 3 of the License, or
|
|
||||||
// (at your option) any later version.
|
|
||||||
//
|
|
||||||
// This program is distributed in the hope that it will be useful,
|
|
||||||
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
||||||
// GNU General Public License for more details.
|
|
||||||
//
|
|
||||||
// You should have received a copy of the GNU General Public License
|
|
||||||
// along with this program. If not, see <https://www.gnu.org/licenses/>.
|
|
||||||
|
|
||||||
#ifndef STA_GENCLKS_H
|
#ifndef STA_GENCLKS_H
|
||||||
#define STA_GENCLKS_H
|
#define STA_GENCLKS_H
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue