Skip to content

Commit

Permalink
Merge with development
Browse files Browse the repository at this point in the history
  • Loading branch information
lwesterhof authored Dec 14, 2023
2 parents 1b6e939 + 9c19366 commit 44261f9
Show file tree
Hide file tree
Showing 13 changed files with 1,569 additions and 300 deletions.
26 changes: 17 additions & 9 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
cmake_minimum_required(VERSION 2.8.12)
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}/CMakeModules")

find_package(IRODS 4.2.11 EXACT REQUIRED)
find_package(IRODS 4.2.12 EXACT REQUIRED)

message(STATUS "Building for irods-server version ${IRODS_VERSION}")

Expand All @@ -12,7 +12,7 @@ message(STATUS "Building for irods-server version ${IRODS_VERSION}")
# irods-externals-clang-runtime3.8-0
# irods-externals-clang6.0-0

set(UU_RELEASE_VERSION "0.8.2")
set(UU_RELEASE_VERSION "0.8.3")

set(CMAKE_CXX_COMPILER ${IRODS_EXTERNALS_FULLPATH_CLANG}/bin/clang++)

Expand All @@ -36,6 +36,7 @@ add_compile_options(-std=c++17
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -stdlib=libc++")
link_libraries(c++abi)
include_directories("${IRODS_EXTERNALS_FULLPATH_CLANG}/include/c++/v1")
include_directories("${IRODS_EXTERNALS_FULLPATH_JSON}/include")
include_directories("/usr/include/irods")

set(BOOST_ROOT "${IRODS_EXTERNALS_FULLPATH_BOOST}")
Expand All @@ -52,27 +53,34 @@ include_directories(SYSTEM ${JANSSON_INCLUDE_DIRS})
find_package(uuid REQUIRED)
include_directories(SYSTEM ${UUID_INCLUDE_DIR})

find_package(LibArchive REQUIRED)
include_directories(SYSTEM ${LibArchive_INCLUDE_DIRS})

include_directories(SYSTEM "/usr/include/irods")

add_library(msiSetUpperCaseWhereQuery SHARED src/msiSetUpperCaseWhereQuery.cc)
add_library(msiStrToUpper SHARED src/msiStrToUpper.cc)
add_library(msiRegisterEpicPID SHARED src/msiRegisterEpicPID.cc)
add_library(msiArchiveCreate SHARED src/msiArchiveCreate.cc)
add_library(msiArchiveExtract SHARED src/msiArchiveExtract.cc)
add_library(msiArchiveIndex SHARED src/msiArchiveIndex.cc)
add_library(msi_json_arrayops SHARED src/msi_json_arrayops.cc)
add_library(msi_json_objops SHARED src/msi_json_objops.cc)
add_library(msi_add_avu SHARED src/msi_add_avu.cpp)
add_library(msi_rmw_avu SHARED src/msi_rmw_avu.cpp)

target_link_libraries(msiStrToUpper LINK_PUBLIC ${Boost_LIBRARIES})
target_link_libraries(msiRegisterEpicPID LINK_PUBLIC ${CURL_LIBRARIES} ${JANSSON_LIBRARIES} ${UUID_LIBRARIES})
target_link_libraries(msiArchiveCreate LINK_PUBLIC ${LibArchive_LIBRARIES} ${JANSSON_LIBRARIES} )
target_link_libraries(msiArchiveExtract LINK_PUBLIC ${LibArchive_LIBRARIES} ${JANSSON_LIBRARIES} )
target_link_libraries(msiArchiveIndex LINK_PUBLIC ${LibArchive_LIBRARIES} ${JANSSON_LIBRARIES} )
target_link_libraries(msi_json_arrayops LINK_PUBLIC ${JANSSON_LIBRARIES} ${Boost_LIBRARIES})
target_link_libraries(msi_json_objops LINK_PUBLIC ${JANSSON_LIBRARIES} ${Boost_LIBRARIES})
target_link_libraries(msi_add_avu LINK_PUBLIC ${Boost_LIBRARIES})
target_link_libraries(msi_rmw_avu LINK_PUBLIC ${Boost_LIBRARIES})

install(TARGETS
msiSetUpperCaseWhereQuery
msiStrToUpper
msiRegisterEpicPID
msiArchiveCreate
msiArchiveExtract
msiArchiveIndex
msi_json_arrayops
msi_json_objops
msi_add_avu
Expand Down Expand Up @@ -117,9 +125,9 @@ set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "Miscellaneous iRODS microservices develop

set(CPACK_RESOURCE_FILE_README "${CMAKE_CURRENT_SOURCE_DIR}/README.md")

set(CPACK_RPM_PACKAGE_RELEASE "1")
set(CPACK_RPM_PACKAGE_RELEASE "0")
set(CPACK_RPM_PACKAGE_LICENSE "LGPLv3")
set(CPACK_RPM_PACKAGE_REQUIRES "irods-server = ${IRODS_VERSION}, boost-locale >= 1.51, libcurl >= 7.29.0, libxml2 >= 2.9.1, libxslt >= 1.1.28, jansson >= 2.10")
set(CPACK_RPM_PACKAGE_REQUIRES "irods-server = ${IRODS_VERSION}, boost-locale >= 1.51, libcurl >= 7.29.0, libxml2 >= 2.9.1, libxslt >= 1.1.28, jansson >= 2.10, libarchive >= 3.1.2")
set(CPACK_RPM_PACKAGE_CONFLICTS "rit-irods-microservices, irods-microservice-plugins-loadmeta")
set(CPACK_RPM_PACKAGE_URL "https://github.com/UtrechtUniversity/irods-uu-microservices")
set(CPACK_RPM_PACKAGE_AUTOREQ 0)
Expand Down
15 changes: 11 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ Miscellaneous iRODS microservices developed or modified by Utrecht University.

## Included microservices
Developed at Utrecht University:
* msiStrToUpper: Returns an uppercase string
* msiSetUpperCaseWhereQuery: Set the UPPERCASE flag on a irods query.
* msiRegisterEpicPID: Register an EPIC PID

Developed at Donders Institute:
* msi\_json\_objops: get, add and set values in a json object
Expand All @@ -17,14 +16,21 @@ Developed at Maastricht University:
* msi\_add\_avu: Microservice to add AVU
* msi\_rmw\_avu: Microservice to remove AVU

Developed at Wageningen University & Research:
* msiArchiveCreate: create an archive
* msiArchiveExtract: extract from an archive
* msiArchiveIndex: index an archive

## Installation
iRODS UU microservices can be installed using the packages provided on the
[releases page](https://github.com/UtrechtUniversity/irods-uu-microservices/releases).

You can also build the microservices yourself, see [Building from source](#building-from-source).

## Building from source
To build from source, the following build-time dependencies must be installed:
This repository includes a Vagrant configuration for building irods-uu-microservices from source on either CentOS 7 (for the RPM package) or Ubuntu 18.04 LTS (for the DEB package). It can be found in vagrant/build. In order to build a package using Vagrant, edit the .env file in the Vagrant build directory. Adjust the BOXNAME and IRODS_VERSION vars as needed. Then run vagrant up to provision the VM. The VM has all dependencies pre-installed, as well as a clone of the irods-uu-microservices repository. Log in on the VM using vagrant ssh and create the package (see below).

To build from source without using the Vagrant configuration, the following build-time dependencies must be installed (package names may differ on your platform):

- `make`
- `gcc-c++`
Expand All @@ -37,10 +43,11 @@ To build from source, the following build-time dependencies must be installed:
- `libcurl-devel`
- `libuuid-devel`
- `jansson-devel`
- `libarchive-devel`
- `rpmdevtools` (if you are creating an RPM)

```
sudo yum install make gcc-c++ irods-devel irods-externals-cmake3.5.2-0 irods-externals-clang6.0-0 boost-devel boost-locale openssl-devel libcurl-devel jansson-devel libuuid-devel rpmdevtools
sudo yum install make gcc-c++ irods-devel irods-externals-cmake3.5.2-0 irods-externals-clang6.0-0 boost-devel boost-locale openssl-devel libcurl-devel jansson-devel libuuid-devel libarchive-devel rpmdevtools
```

Follow these instructions to build from source:
Expand Down
Loading

0 comments on commit 44261f9

Please sign in to comment.