if [ x"$1"x = x"--deps"x ]; then
sudo ./install-deps.sh
fi
-if [ -x /usr/bin/getopt ] && [ x"`/usr/bin/getopt -v`"x == x" --"x ]; then
- echo fix getopt path
- echo Native FreeBSD getopt is not compatible with the Linux getopt that is
- echo expected with Ceph.
- echo Easiest is to rename/remove /usr/bin/getopt.
- echo mv /usr/bin/getopt /usr/bin/getopt.freebsd
- exit 1
-fi
if [ x"$CEPH_DEV"x != xx ]; then
BUILDOPTS="$BUILDOPTS V=1 VERBOSE=1"
-D WITH_SYSTEM_BOOST=ON \
-D WITH_LTTNG=OFF \
-D WITH_BLKID=OFF \
- -D WITH_FUSE=OFF \
+ -D WITH_FUSE=ON \
-D WITH_KRBD=OFF \
-D WITH_XFS=OFF \
-D WITH_KVS=OFF \
- -D WITH_MANPAGE=ON \
-D CEPH_MAN_DIR=man \
-D WITH_LIBCEPHFS=OFF \
-D WITH_CEPHFS=OFF \
-D WITH_EMBEDDED=OFF \
+ -D WITH_MGR=YES \
2>&1 | tee cmake.log
-cd build
-gmake -j$NPROC $BUILDOPTS
-gmake check
+echo start building
+date
+(cd build; gmake -j$NPROC $BUILDOPTS )
+(cd build; gmake -j$NPROC $BUILDOPTS ceph-disk)
+(cd build; gmake -j$NPROC $BUILDOPTS ceph-detect-init)
+
+echo start testing
+date
+(cd build; ctest -j$NPROC || ctest --rerun-failed --output-on-failure)
add_definitions("-DCEPH_LIBDIR=\"${CMAKE_INSTALL_FULL_LIBDIR}\"")
add_definitions("-DCEPH_PKGLIBDIR=\"${CMAKE_INSTALL_FULL_PKGLIBDIR}\"")
add_definitions("-DHAVE_CONFIG_H -D__CEPH__ -D_REENTRANT -D_THREAD_SAFE -D__STDC_FORMAT_MACROS")
+add_definitions("-D_FILE_OFFSET_BITS=64")
if(LINUX)
- add_definitions("-D_GNU_SOURCE -D_FILE_OFFSET_BITS=64")
+ add_definitions("-D_GNU_SOURCE")
endif()
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wtype-limits -Wignored-qualifiers -Winit-self")
add_library(parse_secret_objs OBJECT ${parse_secret_files})
endif()
+add_subdirectory(client)
+
if(WITH_LIBCEPHFS)
- add_subdirectory(client)
set(libcephfs_srcs libcephfs.cc)
add_library(cephfs ${CEPH_SHARED} ${libcephfs_srcs})
target_link_libraries(cephfs LINK_PRIVATE client ceph-common
install(TARGETS ceph-syn DESTINATION bin)
install(TARGETS mount.ceph DESTINATION ${CMAKE_INSTALL_SBINDIR})
-
- if(WITH_FUSE)
- set(ceph_fuse_srcs
- ceph_fuse.cc
- client/fuse_ll.cc)
- add_executable(ceph-fuse ${ceph_fuse_srcs})
- target_link_libraries(ceph-fuse ${ALLOC_LIBS} ${FUSE_LIBRARIES}
- client common global-static)
- set_target_properties(ceph-fuse PROPERTIES COMPILE_FLAGS "-I${FUSE_INCLUDE_DIRS}")
- install(TARGETS ceph-fuse DESTINATION bin)
- install(PROGRAMS mount.fuse.ceph DESTINATION ${CMAKE_INSTALL_SBINDIR})
- endif(WITH_FUSE)
endif(WITH_LIBCEPHFS)
+if(WITH_FUSE)
+ set(ceph_fuse_srcs
+ ceph_fuse.cc
+ client/fuse_ll.cc)
+ add_executable(ceph-fuse ${ceph_fuse_srcs})
+ target_link_libraries(ceph-fuse ${ALLOC_LIBS} ${FUSE_LIBRARIES}
+ client common global-static)
+ set_target_properties(ceph-fuse PROPERTIES COMPILE_FLAGS "-I${FUSE_INCLUDE_DIRS}")
+ install(TARGETS ceph-fuse DESTINATION bin)
+ install(PROGRAMS mount.fuse.ceph DESTINATION ${CMAKE_INSTALL_SBINDIR})
+endif(WITH_FUSE)
+
add_subdirectory(journal)
if(WITH_RBD)