|
1 | 1 | diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
|
2 |
| -index 99752d275..74a1ef540 100755 |
| 2 | +index 3383cc173..79e66cecb 100755 |
3 | 3 | --- a/src/CMakeLists.txt
|
4 | 4 | +++ b/src/CMakeLists.txt
|
5 |
| -@@ -244,7 +244,6 @@ add_subdirectory(cts) |
| 5 | +@@ -168,6 +168,8 @@ message(STATUS "boost: ${Boost_VERSION}") |
| 6 | + find_package(Python3 COMPONENTS Development REQUIRED) |
| 7 | + option(BUILD_PYTHON "Build the Python3 interface" ON) |
| 8 | + |
| 9 | ++option(BUILD_MPL2 "Build MPL2 macro placer" ON) |
| 10 | ++ |
| 11 | + option(ALLOW_WARNINGS "Flag to allow compilation with compiler warnings: on by default" ON) |
| 12 | + if (NOT ALLOW_WARNINGS) |
| 13 | + add_compile_options( |
| 14 | +@@ -250,7 +252,9 @@ add_subdirectory(cts) |
6 | 15 | add_subdirectory(grt)
|
7 | 16 | add_subdirectory(tap)
|
8 | 17 | add_subdirectory(mpl)
|
9 | 18 | -add_subdirectory(mpl2)
|
| 19 | ++if ((NOT ${CMAKE_SYSTEM_NAME} MATCHES "Darwin") AND BUILD_MPL2) |
| 20 | ++ add_subdirectory(mpl2) |
| 21 | ++endif() |
10 | 22 | add_subdirectory(rcx)
|
11 | 23 | add_subdirectory(psm)
|
12 | 24 | add_subdirectory(par)
|
13 |
| -@@ -309,7 +308,6 @@ target_link_libraries(openroad |
14 |
| - drt |
15 |
| - dst |
16 |
| - mpl |
17 |
| -- mpl2 |
18 |
| - psm |
19 |
| - ant |
20 |
| - par |
21 |
| -diff --git a/src/OpenRoad.cc b/src/OpenRoad.cc |
22 |
| -index dcf1ae707..0f0341ddb 100644 |
23 |
| ---- a/src/OpenRoad.cc |
24 |
| -+++ b/src/OpenRoad.cc |
25 |
| -@@ -57,7 +57,6 @@ |
26 |
| - #include "gui/MakeGui.h" |
27 |
| - #include "ifp//MakeInitFloorplan.hh" |
28 |
| - #include "mpl/MakeMacroPlacer.h" |
29 |
| --#include "mpl2/MakeMacroPlacer.h" |
30 |
| - #include "odb/cdl.h" |
31 |
| - #include "odb/db.h" |
32 |
| - #include "odb/defin.h" |
33 |
| -@@ -160,7 +159,6 @@ OpenRoad::~OpenRoad() |
34 |
| - deleteTritonCts(tritonCts_); |
35 |
| - deleteTapcell(tapcell_); |
36 |
| - deleteMacroPlacer(macro_placer_); |
37 |
| -- deleteMacroPlacer2(macro_placer2_); |
38 |
| - deleteOpenRCX(extractor_); |
39 |
| - deleteTritonRoute(detailed_router_); |
40 |
| - deleteReplace(replace_); |
41 |
| -@@ -213,7 +211,6 @@ void OpenRoad::init(Tcl_Interp* tcl_interp) |
42 |
| - tritonCts_ = makeTritonCts(); |
43 |
| - tapcell_ = makeTapcell(); |
44 |
| - macro_placer_ = makeMacroPlacer(); |
45 |
| -- macro_placer2_ = makeMacroPlacer2(); |
46 |
| - extractor_ = makeOpenRCX(); |
47 |
| - detailed_router_ = makeTritonRoute(); |
48 |
| - replace_ = makeReplace(); |
49 |
| -@@ -247,7 +244,6 @@ void OpenRoad::init(Tcl_Interp* tcl_interp) |
50 |
| - initTritonCts(this); |
51 |
| - initTapcell(this); |
52 |
| - initMacroPlacer(this); |
53 |
| -- initMacroPlacer2(this); |
54 |
| - initOpenRCX(this); |
55 |
| - initPad(this); |
56 |
| - initRestructure(this); |
| 25 | +@@ -325,12 +329,12 @@ target_link_libraries(openroad |
| 26 | + ${CMAKE_THREAD_LIBS_INIT} |
| 27 | + ) |
| 28 | + |
| 29 | +-if (NOT ${CMAKE_SYSTEM_NAME} MATCHES "Darwin") |
| 30 | ++if ((NOT ${CMAKE_SYSTEM_NAME} MATCHES "Darwin") AND BUILD_MPL2) |
| 31 | + # mpl2 aborts with link error on darwin so do not link it. |
| 32 | + target_link_libraries(openroad mpl2) |
| 33 | + target_compile_definitions(openroad PRIVATE ENABLE_MPL2) |
| 34 | + else() |
| 35 | +- message(STATUS "Removing MPL2 to avoid run time fatal error.") |
| 36 | ++ message(STATUS "MPL2 macro placer disabled.") |
| 37 | + endif() |
| 38 | + |
| 39 | + # tclReadline |
0 commit comments