Skip to content

Commit

Permalink
[octave] add features
Browse files Browse the repository at this point in the history
  • Loading branch information
talregev committed Jan 29, 2025
1 parent fc97d3e commit 45ec47a
Show file tree
Hide file tree
Showing 4 changed files with 155 additions and 15 deletions.
91 changes: 79 additions & 12 deletions ports/octave/portfile.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,74 @@ if(VCPKG_HOST_IS_OSX)
message("${PORT} currently requires the following programs from the system package manager:\n gsed\n\nIt can be installed with brew gnu-sed")
endif()

if("arpack" IN_LIST FEATURES)
set(ARPACK_OPTION "yes")
else()
set(ARPACK_OPTION "no")
endif()

if("camd" IN_LIST FEATURES)
set(CAMD_OPTION "yes")
else()
set(CAMD_OPTION "no")
endif()

if("ccolamd" IN_LIST FEATURES)
set(CCOLAMD_OPTION "yes")
else()
set(CCOLAMD_OPTION "no")
endif()

if("cholmod" IN_LIST FEATURES)
set(CHOLMOD_OPTION "yes")
else()
set(CHOLMOD_OPTION "no")
endif()

if("colamd" IN_LIST FEATURES)
set(COLAMD_OPTION "yes")
else()
set(COLAMD_OPTION "no")
endif()

if("cxsparse" IN_LIST FEATURES)
set(CXSPARSE_OPTION "yes")
else()
set(CXSPARSE_OPTION "no")
endif()

if("klu" IN_LIST FEATURES)
set(KLU_OPTION "yes")
else()
set(KLU_OPTION "no")
endif()

if("umfpack" IN_LIST FEATURES)
set(UMFPACK_OPTION "yes")
else()
set(UMFPACK_OPTION "no")
endif()

if("hdf5" IN_LIST FEATURES)
set(HDF5_OPTION "yes")
else()
set(HDF5_OPTION "no")
endif()

if("fltk" IN_LIST FEATURES)
set(FLTK_OPTION "yes")
else()
set(FLTK_OPTION "no")
endif()

if("portaudio" IN_LIST FEATURES)
set(PORTAUDIO_OPTION "yes")
else()
set(PORTAUDIO_OPTION "no")
endif()

vcpkg_add_to_path("${CURRENT_INSTALLED_DIR}/tools/fltk")

vcpkg_configure_make(
SOURCE_PATH "${SOURCE_PATH}"
AUTOCONFIG
Expand All @@ -46,26 +114,25 @@ vcpkg_configure_make(
--enable-lib-visibility-flags
--enable-relocate-all
--with-amd=no
--with-arpack=no
--with-arpack=${ARPACK_OPTION}
--with-bz2=no
--with-camd=no
--with-ccolamd=no
--with-cholmod=no
--with-colamd=no
--with-cxsparse=no
--with-camd=${CAMD_OPTION}
--with-ccolamd=${CCOLAMD_OPTION}
--with-cholmod=${CHOLMOD_OPTION}
--with-colamd=${COLAMD_OPTION}
--with-cxsparse=${CXSPARSE_OPTION}
--with-curl=no
--with-cxsparse=no
--with-fftw3 # yes
--with-fftw3f # yes
--with-fltk=no
--with-fltk=${FLTK_OPTION}
--with-fontconfig=no
--with-freetype=no
--with-glpk # yes
--with-hdf5=no
--with-klu=no
--with-hdf5=${HDF5_OPTION}
--with-klu=${KLU_OPTION}
--with-magick=no
--with-opengl # yes
--with-portaudio=no
--with-portaudio=${PORTAUDIO_OPTION}
--with-pcre2 # yes
--with-qhull_r=no
--with-qrupdate=no
Expand All @@ -76,7 +143,7 @@ vcpkg_configure_make(
--with-suitesparseconfig=no
--with-sundials_ida=no
--with-sundials_nvecserial=no
--with-umfpack=no
--with-umfpack=${UMFPACK_OPTION}
--with-z # yes
)
vcpkg_install_make()
Expand Down
72 changes: 70 additions & 2 deletions ports/octave/vcpkg.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "octave",
"version": "9.3.0",
"port-version": 1,
"port-version": 2,
"description": "High-level interpreted language, primarily intended for numerical computations.",
"homepage": "https://octave.org/",
"documentation": "https://docs.octave.org/latest/",
Expand All @@ -17,5 +17,73 @@
"pcre2",
"readline",
"zlib"
]
],
"features": {
"arpack": {
"description": "arpack support",
"dependencies": [
"arpack-ng"
]
},
"camd": {
"description": "suitesparse-camd support",
"dependencies": [
"suitesparse-camd"
]
},
"ccolamd": {
"description": "suitesparse-ccolamd support",
"dependencies": [
"suitesparse-ccolamd"
]
},
"cholmod": {
"description": "suitesparse-cholmod support",
"dependencies": [
"suitesparse-cholmod"
]
},
"colamd": {
"description": "suitesparse-colamd support",
"dependencies": [
"suitesparse-colamd"
]
},
"cxsparse": {
"description": "suitesparse-cxsparse support",
"dependencies": [
"suitesparse-cxsparse"
]
},
"fltk": {
"description": "fltk support",
"dependencies": [
"fltk"
]
},
"hdf5": {
"description": "hdf5 support",
"dependencies": [
"hdf5"
]
},
"klu": {
"description": "suitesparse-klu support",
"dependencies": [
"suitesparse-klu"
]
},
"portaudio": {
"description": "portaudio support",
"dependencies": [
"portaudio"
]
},
"umfpack": {
"description": "suitesparse-umfpack support",
"dependencies": [
"suitesparse-umfpack"
]
}
}
}
2 changes: 1 addition & 1 deletion versions/baseline.json
Original file line number Diff line number Diff line change
Expand Up @@ -6554,7 +6554,7 @@
},
"octave": {
"baseline": "9.3.0",
"port-version": 1
"port-version": 2
},
"octomap": {
"baseline": "1.10.0",
Expand Down
5 changes: 5 additions & 0 deletions versions/o-/octave.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "1c7ff7cade4733c5a5719f008d86cdfa477926f8",
"version": "9.3.0",
"port-version": 2
},
{
"git-tree": "cc528d9865bd5b487ad0b152cdedc809b64e497f",
"version": "9.3.0",
Expand Down

0 comments on commit 45ec47a

Please sign in to comment.