Skip to content

Commit

Permalink
Merge pull request #27 from ddavila0/add_XrootdPluginVersion
Browse files Browse the repository at this point in the history
Adding XrootD major version to the shared file name (software-4093)
  • Loading branch information
ddavila0 authored Jun 26, 2020
2 parents 87637cb + 267cbbc commit f7010cf
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 8 deletions.
4 changes: 2 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
sudo: required
env:
- REPO_NAME=${TRAVIS_REPO_SLUG#*/}
- REPO_NAME=${TRAVIS_REPO_SLUG#*/} KOJI_BUILD_TAG=osg-3.5-el7-build

git:
depth: false
Expand All @@ -17,4 +17,4 @@ before_install:
- sudo docker pull opensciencegrid/osg-build

script:
- docker run -v $(pwd):/$REPO_NAME -e REPO_NAME=$REPO_NAME --cap-add=SYS_ADMIN opensciencegrid/osg-build build-from-github
- docker run -v $(pwd):/$REPO_NAME -e REPO_NAME=$REPO_NAME -e KOJI_BUILD_TAG=osg-3.5-el7-build --cap-add=SYS_ADMIN opensciencegrid/osg-build build-from-github
10 changes: 8 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,12 @@ find_package( Hdfs REQUIRED )
find_package( Jvm REQUIRED )
find_package( Dl REQUIRED )

if(NOT XROOTD_PLUGIN_VERSION)
find_program(XROOTD_CONFIG_EXECUTABLE xrootd-config)
exec_program(${XROOTD_CONFIG_EXECUTABLE} ARGS "--plugin-version" OUTPUT_VARIABLE XROOTD_PLUGIN_VERSION RETURN_VALUE RETVAR)
set(XROOTD_PLUGIN_VERSION ${XROOTD_PLUGIN_VERSION} CACHE INTERNAL "")
endif()

include (FindPkgConfig)
pkg_check_modules(LIBCRYPTO REQUIRED libcrypto)
pkg_check_modules(ZLIB REQUIRED zlib)
Expand Down Expand Up @@ -42,11 +48,11 @@ include_directories( "${PROJECT_SOURCE_DIR}" "${XROOTD_INCLUDES}" )

add_library(XrdHdfs MODULE src/XrdHdfsBootstrap.cc src/XrdHdfsChecksum.cc src/XrdHdfsChecksumCalc.cc)
target_link_libraries(XrdHdfs ${XROOTD_UTILS} ${DL_LIB} ${LIBCRYPTO_LIBRARIES} ${ZLIB_LIBRARIES})
set_target_properties(XrdHdfs PROPERTIES LINK_FLAGS "-Wl,--version-script=${CMAKE_SOURCE_DIR}/src/export-lib-symbols")
set_target_properties(XrdHdfs PROPERTIES OUTPUT_NAME "XrdHdfs-${XROOTD_PLUGIN_VERSION}" LINK_FLAGS "-Wl,--version-script=${CMAKE_SOURCE_DIR}/src/export-lib-symbols")

add_library(XrdHdfsReal MODULE src/XrdHdfs.cc src/XrdHdfsConfig.cc src/XrdHdfs.hh src/XrdHdfsChecksum.cc src/XrdHdfsChecksumCalc.cc)
target_link_libraries(XrdHdfsReal ${HDFS_LIB} ${XROOTD_UTILS} ${LIBCRYPTO_LIBRARIES} ${ZLIB_LIBRARIES})
set_target_properties(XrdHdfsReal PROPERTIES LINK_FLAGS "-Wl,--version-script=${CMAKE_SOURCE_DIR}/src/export-lib-symbols")
set_target_properties(XrdHdfsReal PROPERTIES OUTPUT_NAME "XrdHdfsReal-${XROOTD_PLUGIN_VERSION}" LINK_FLAGS "-Wl,--version-script=${CMAKE_SOURCE_DIR}/src/export-lib-symbols")

add_executable(xrootd_hdfs_envcheck src/XrdHdfsEnvCheck.cc)

Expand Down
12 changes: 8 additions & 4 deletions rpm/xrootd-hdfs.spec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Name: xrootd-hdfs
Version: 2.1.7
Release: 6%{?dist}
Release: 7%{?dist}
Summary: HDFS plugin for xrootd

Group: System Environment/Development
Expand Down Expand Up @@ -62,9 +62,9 @@ rm $RPM_BUILD_ROOT%{_bindir}/xrootd_hdfs_envcheck

%files
%defattr(-,root,root,-)
%{_libdir}/libXrdHdfs.so
%{_libdir}/libXrdHdfs.so.*
%{_libdir}/libXrdHdfsReal.so
%{_libdir}/libXrdHdfs-*.so
%{_libdir}/libXrdHdfs-*.so.*
%{_libdir}/libXrdHdfsReal-*.so
%{_sysconfdir}/xrootd/xrootd.sample.hdfs.cfg
%{_libexecdir}/xrootd-hdfs/xrootd_hdfs_envcheck
%config(noreplace) %{_sysconfdir}/sysconfig/xrootd-hdfs
Expand All @@ -74,6 +74,10 @@ rm $RPM_BUILD_ROOT%{_bindir}/xrootd_hdfs_envcheck
%{_includedir}/XrdHdfs.hh

%changelog
* Wed Jun 10 2020 Diego Davila <[email protected]> - 2.1.7-7
- Adding XrootD major version to the shared file name
- building against XrootD-4.12.2 (software-4093)

* Fri Apr 24 2020 Edgar Fajardo <[email protected]> - 2.1.7-6
- Rebuild for xrootd 4.12 (SOFTWARE-4063)

Expand Down

0 comments on commit f7010cf

Please sign in to comment.