Skip to content

Commit

Permalink
Fix prefix in buildenv + documentation improvement
Browse files Browse the repository at this point in the history
  • Loading branch information
kamahen authored and JanWielemaker committed Dec 30, 2023
1 parent d0ac863 commit fb455aa
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 7 deletions.
3 changes: 2 additions & 1 deletion library/build/tools.pl
Original file line number Diff line number Diff line change
Expand Up @@ -341,7 +341,8 @@
def_environment(VAR, Value, Options) :-
env_name(module_ext, VAR, Options),
current_prolog_flag(shared_object_extension, Value).
def_environment('PREFIX', Value, _) :-
def_environment(VAR, Value, Options) :-
env_name(prefix, VAR, Options),
prolog_install_prefix(Value).

swipl_libraries_dir(Dir) :-
Expand Down
14 changes: 8 additions & 6 deletions library/prolog_pack.pl
Original file line number Diff line number Diff line change
Expand Up @@ -80,14 +80,16 @@
makes installed packages available as libraries.
To make changes to a package:
* Clone the git repo,t go into the repo and run:
* Clone the git repo, then go into the repo and run:
`?- pack_install(.).`
This builds the pack locally and creates a symlink to make it available.
This builds the pack locally and creates a symlink to make it
available. It will also write a file `buildenv.sh` that you can
source to get the environment for running a normal `make` (this is
done only if there is a `configure` step; i.e., if there is a
`configure.in` or `configure` file).
* `(source ./buildenv.sh` && make)` to rebuild
* `?- pack_rebuild(package_name).`
This runs `make distclean` and `make` with the right environment. It will also
write a file `buildendv.sh` that you can source to get the environment
for running a normal `make` (this is done only if there is a `configure`
step; i.e., if there is a `configure.in` or `configure`.
This runs `make distclean` and `make` with the right environment.
* The build process also supports `cmake`.
Once you have made the changes, you should edit the `pack.pl` file
Expand Down

0 comments on commit fb455aa

Please sign in to comment.