Skip to content

Commit

Permalink
[guix] Add exprtk package.
Browse files Browse the repository at this point in the history
  • Loading branch information
bilke authored and endJunction committed Nov 1, 2023
1 parent 4b7fa51 commit 4f7a690
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 9 deletions.
23 changes: 23 additions & 0 deletions .guix/modules/ogs-package.scm
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
#:use-module (guix)
#:use-module (guix packages)
#:use-module (guix build-system cmake)
#:use-module (guix build-system copy)
#:use-module (guix download)
#:use-module (guix git-download)
#:use-module ((guix licenses) #:prefix license:)
Expand Down Expand Up @@ -70,6 +71,7 @@
#:cmake ,cmake)) ;for newer CMake version
(inputs (list boost
eigen
exprtk
hdf5
iphreeqc
json-modern-cxx
Expand Down Expand Up @@ -281,6 +283,27 @@
`(#:tests? #f)
)))

(define exprtk
(package
(name "exprtk")
(home-page "https://www.partow.net/programming/exprtk/index.html")
(synopsis "C++ Mathematical Expression Parsing And Evaluation Library")
(description "")
(license license:expat)
(version "0.0.2")
(source (origin
(method git-fetch)
(uri (git-reference
(url "https://github.com/ArashPartow/exprtk.git")
(commit version)))
(sha256
(base32
"1w92qlfjpcan38d88fak3avq81lkcpai5mqpbvrsfv04mi5nfpk5"))))
(build-system copy-build-system)
(arguments
'(#:install-plan '(("exprtk.hpp" "include/")))
)))

;; return package
ogs

Expand Down
2 changes: 1 addition & 1 deletion ThirdParty/collection
Submodule collection updated from 860959 to a60702
20 changes: 12 additions & 8 deletions scripts/cmake/Dependencies.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -282,15 +282,19 @@ endif()
# find_package(ParaView REQUIRED)
# endif()
# ~~~
CPMAddPackage(
NAME exprtk
GIT_REPOSITORY https://gitlab.opengeosys.org/ogs/libs/exprtk.git
GIT_TAG 2a5c62b93c9661470e69be572f22d821308b6f61
DOWNLOAD_ONLY YES
)
if(exprtk_ADDED)
if(GUIX_BUILD)
add_library(exprtk INTERFACE IMPORTED)
target_include_directories(exprtk SYSTEM INTERFACE ${exprtk_SOURCE_DIR})
else()
CPMAddPackage(
NAME exprtk
GIT_REPOSITORY https://gitlab.opengeosys.org/ogs/libs/exprtk.git
GIT_TAG 2a5c62b93c9661470e69be572f22d821308b6f61
DOWNLOAD_ONLY YES
)
if(exprtk_ADDED)
add_library(exprtk INTERFACE IMPORTED)
target_include_directories(exprtk SYSTEM INTERFACE ${exprtk_SOURCE_DIR})
endif()
endif()

if(GUIX_BUILD)
Expand Down

0 comments on commit 4f7a690

Please sign in to comment.