Skip to content

Commit 751dfd0

Browse files
authored
Merge pull request #9028 from fgaray/bazel_build
Some fixes for python libraries bindings when building in bazel
2 parents a6bbc93 + ea1557f commit 751dfd0

File tree

3 files changed

+9
-0
lines changed

3 files changed

+9
-0
lines changed

src/par/src/partitionmgr-py.i

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,10 @@
1313

1414
namespace std
1515
{
16+
#ifndef SWIG_VECTOR_INT
17+
#define SWIG_VECTOR_INT
1618
%template(vector_int) std::vector<int>;
19+
#endif
1720
%template(vector_float) std::vector<float>;
1821
}
1922
#endif

src/pdn/src/PdnGen-py.i

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,10 @@ using namespace pdn;
2929
// before these definitions
3030
namespace std {
3131
%template() std::pair<int, bool>;
32+
#ifndef SWIG_VECTOR_INT
33+
#define SWIG_VECTOR_INT
3234
%template(split_cuts_stuff) std::vector<int>;
35+
#endif
3336
%template(stuff) std::array<int, 4>;
3437
%template(split_map) std::map<odb::dbTechLayer *, std::pair<int, bool>>;
3538
%template(grid_list) std::vector<pdn::Grid *>;

src/stt/src/SteinerTreeBuilder-py.i

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,10 @@
1818
%include <std_vector.i>
1919

2020
namespace std {
21+
#ifndef SWIG_VECTOR_INT
22+
#define SWIG_VECTOR_INT
2123
%template(xy) vector<int>;
24+
#endif
2225
}
2326

2427
%include "stt/SteinerTreeBuilder.h"

0 commit comments

Comments
 (0)