File tree Expand file tree Collapse file tree 2 files changed +21
-0
lines changed Expand file tree Collapse file tree 2 files changed +21
-0
lines changed Original file line number Diff line number Diff line change @@ -167,6 +167,20 @@ else
167
167
fi
168
168
fi
169
169
170
+ if [ $( uname) = " Darwin" ]; then
171
+ if test -f $INSTALL_DIR /bin/mongoc-stat; then
172
+ echo " mongoc-stat shouldn't have been installed"
173
+ exit 1
174
+ fi
175
+ else
176
+ if test ! -f $INSTALL_DIR /bin/mongoc-stat; then
177
+ echo " mongoc-stat missing!"
178
+ exit 1
179
+ else
180
+ echo " mongoc-stat check ok"
181
+ fi
182
+ fi
183
+
170
184
if [ " $BUILD_SAMPLE_WITH_CMAKE " ]; then
171
185
# Test our CMake package config file with CMake's find_package command.
172
186
EXAMPLE_DIR=$SRCROOT /src/libmongoc/examples/cmake/find_package
Original file line number Diff line number Diff line change @@ -597,6 +597,13 @@ endif ()
597
597
add_executable (mongoc-stat ${PROJECT_SOURCE_DIR} /../../src/tools/mongoc-stat.c )
598
598
target_link_libraries (mongoc-stat mongoc_shared )
599
599
600
+ # mongoc-stat works if shared memory performance counters are enabled.
601
+ if (ENABLE_SHM_COUNTERS STREQUAL "ON" )
602
+ install (PROGRAMS ${PROJECT_BINARY_DIR} /mongoc-stat
603
+ DESTINATION ${CMAKE_INSTALL_BINDIR}
604
+ )
605
+ endif ()
606
+
600
607
function (mongoc_add_test test use_shared )
601
608
if (ENABLE_TESTS )
602
609
add_executable (${test} ${ARGN} )
You can’t perform that action at this time.
0 commit comments