Skip to content

Commit 301ca4a

Browse files
committed
CMakeLists cleanup
1 parent 93d2e51 commit 301ca4a

File tree

1 file changed

+14
-15
lines changed

1 file changed

+14
-15
lines changed

src/python/library/CMakeLists.txt

Lines changed: 14 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,6 @@ if(WIN32)
9696
cshm
9797
${WHEEL_DEPENDS}
9898
)
99-
10099
if (${TRITON_ENABLE_PERF_ANALYZER})
101100
set(perf_analyzer_arg --perf-analyzer ${CMAKE_INSTALL_PREFIX}/bin/perf_analyzer)
102101
endif()
@@ -117,10 +116,10 @@ if(WIN32)
117116
DEPENDS
118117
"${windows_wheel_stamp_file}"
119118
)
120-
#
121-
# Linux specific Wheel file. Compatible with x86, x64 and aarch64
122-
#
123-
if (NOT WIN32)
119+
else()
120+
#
121+
# Linux specific Wheel file. Compatible with x86, x64 and aarch64
122+
#
124123
# Can generate linux specific wheel file on linux systems only.
125124
set(LINUX_WHEEL_DEPENDS
126125
cshm
@@ -147,20 +146,25 @@ if (NOT WIN32)
147146
DEPENDS
148147
"${linux_wheel_stamp_file}"
149148
)
150-
endif() # NOT WIN32
149+
endif() # WIN32
151150

152151
if(${TRITON_ENABLE_PYTHON_GRPC})
153152
add_dependencies(
154153
generic-client-wheel
155154
grpc-service-py-library proto-py-library
156155
)
157156

158-
if (NOT WIN32)
157+
if (WIN32)
158+
add_dependencies(
159+
windows-client-wheel
160+
grpc-service-py-library proto-py-library
161+
)
162+
else()
159163
add_dependencies(
160164
linux-client-wheel
161165
grpc-service-py-library proto-py-library
162-
)
163-
endif() # NOT WIN32
166+
)
167+
endif() # WIN32
164168

165169
file(
166170
GLOB generated-py
@@ -180,14 +184,9 @@ if(WIN32)
180184
CODE "file(GLOB _Wheel \"${CMAKE_CURRENT_BINARY_DIR}/windows/triton*.whl\")"
181185
CODE "file(INSTALL \${_Wheel} DESTINATION \"${CMAKE_INSTALL_PREFIX}/python\")"
182186
)
183-
elseif(NOT WIN32)
184-
install(
185-
CODE "file(GLOB _Wheel \"${CMAKE_CURRENT_BINARY_DIR}/linux/triton*.whl\")"
186-
CODE "file(INSTALL \${_Wheel} DESTINATION \"${CMAKE_INSTALL_PREFIX}/python\")"
187-
)
188187
else()
189188
install(
190-
CODE "file(GLOB _Wheel \"${CMAKE_CURRENT_BINARY_DIR}/generic/triton*.whl\")"
189+
CODE "file(GLOB _Wheel \"${CMAKE_CURRENT_BINARY_DIR}/linux/triton*.whl\")"
191190
CODE "file(INSTALL \${_Wheel} DESTINATION \"${CMAKE_INSTALL_PREFIX}/python\")"
192191
)
193192
endif() # NOT WIN32

0 commit comments

Comments
 (0)