Skip to content

Commit

Permalink
Relax FindGuile.cmake
Browse files Browse the repository at this point in the history
* config/FindGuile.cmake: Do not require GUILE_ROOT_DIR since I'm not using
  it. Even though guile-config is available, guile-config --variable=prefix
  guile-3.0 fails somehow...
  • Loading branch information
lloda committed Jul 13, 2023
1 parent 02fd1de commit 30d0ba8
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
9 changes: 8 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,18 @@ Except for the tests and for the pair of functions `ra->array` / `array->ra`, `n
> cmake . && make test
```

or manually

```
> $GUILE -L mod test/everything.scm
> ...
```

The manual is at [lloda.github.io/guile-newra](https://lloda.github.io/guile-newra), and you can find some larger examples in `examples/`.

To install the library, put `mod/newra` and `mod/newra.scm` somewhere in your Guile load path, and use it with `(import (newra))`.

`newra` can use [`guile-ffi-blis`](https://github.com/lloda/guile-ffi-blis) for some functions (`ra-fill!` in the current version), which can provide a considerable speed up for operations with arrays of types `s32`, `u32`, `f32`, `s64`, `u64`, `f64`, `c32`, or `c64`. It can also be slower — there isn't a good heuristic yet. Run the benchmarks with
`newra` can use [`guile-ffi-blis`](https://github.com/lloda/guile-ffi-blis) for some functions (`ra-fill!` in the current version), to provide a considerable speed up for operations with arrays of types `s32`, `u32`, `f32`, `s64`, `u64`, `f64`, `c32`, or `c64`. It can also be slower — there isn't a good heuristic yet. Run the benchmarks with

```
> $GUILE -L mod bench/bench.scm
Expand Down
4 changes: 3 additions & 1 deletion config/FindGuile.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,8 @@ if (GUILE_CONFIG_EXECUTABLE)
endif ()

message ("* GUILE_EXECUTABLE: ${GUILE_EXECUTABLE}")
message ("* GUILE_CONFIG_EXECUTABLE: ${GUILE_CONFIG_EXECUTABLE}")
message ("* GUILE_ROOT: ${GUILE_ROOT}")
message ("* GUILE_ROOT_DIR: ${GUILE_ROOT_DIR}")
message ("* GUILE_INCLUDE_DIRS: ${GUILE_INCLUDE_DIRS}")
message ("* GUILE_LIBRARIES: ${GUILE_LIBRARIES}")
Expand All @@ -99,7 +101,7 @@ message ("* GUILE_VERSION_STRING: ${GUILE_VERSION_STRING}")
# handle REQUIRED and QUIET options
include (FindPackageHandleStandardArgs)
find_package_handle_standard_args (Guile
REQUIRED_VARS GUILE_EXECUTABLE GUILE_ROOT_DIR GUILE_INCLUDE_DIRS GUILE_LIBRARIES
REQUIRED_VARS GUILE_EXECUTABLE GUILE_INCLUDE_DIRS GUILE_LIBRARIES
VERSION_VAR GUILE_VERSION_STRING)

mark_as_advanced (GUILE_INCLUDE_DIR GUILE_LIBRARY)

0 comments on commit 30d0ba8

Please sign in to comment.