-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
set rpath for external libsemigroups #954
Conversation
I've left |
Thanks @dimpase |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems to do exactly what is desired, happy to approve. @fingolfin could you please also have a quick look at this if you have the time?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! The principle seems fine to me, but I have some minor remarks on details.
@@ -53,6 +55,8 @@ AC_DEFUN([AX_CHECK_LIBSEMIGROUPS], [ | |||
else | |||
LIBSEMIGROUPS_VERSION="$(pkg-config --modversion libsemigroups)" | |||
AC_MSG_NOTICE([using external libsemigroups $LIBSEMIGROUPS_VERSION]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
indentation looks odd here (maybe tabs versus spaces), but that was of course already there before this PR, so not an objection to this PR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(Indeed, this whole file mixes tabs and spaces liberally. Probably best to ignore this for this PR)
m4/ax_check_libsemigroup.m4
Outdated
[AC_MSG_NOTICE([ignoring flag --with-external-libsemigroups, the Semigroups configure file | ||
was created on a system without m4 macros for pkg-config available...])]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this should be undone, it causes the error to change from
...
checking for awk... awk
configure: using included libsemigroups...
configure: error: libsemigroups is required, clone or download the repo from https://github.com/libsemigroups/libsemigroups into this directory
which is sensibly wrapped in my terminal, to
checking for awk... awk
configure: using included libsemigroups...
configure: error: libsemigroups is required, clone or download the repo from
https://github.com/libsemigroups/libsemigroups into this directory
which is rather weird.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed, I think this change should be undone.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are no two equal terminals, besides, such long lines of code aren't helping.
I can try to make sure the output is formatted better.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Have you tested the message? It was perfectly legible for me before your changes but not anymore afterwards. Was the experience different for you?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I changed it to avoid extra-long lines in the source, most of all.
m4/ax_check_libsemigroup.m4
Outdated
[AC_MSG_ERROR([libsemigroups is required, clone or download the repo from | ||
https://github.com/libsemigroups/libsemigroups into this directory])])]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should also be undone, IMHO
PKG_CHECK_VAR([LIBSEMIGROUPS_RPATH], [libsemigroups], [libdir], | ||
[AC_SUBST([LIBSEMIGROUPS_RPATH],[-Wl,-rpath,${LIBSEMIGROUPS_RPATH}])]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's the core of the change. Looks OK to me.
@@ -138,7 +138,7 @@ gen/%.$(GAP_OBJEXT): %.s Makefile | |||
# build rule for linking all object files together into a kernel extension | |||
$(KEXT_SO): $(KEXT_OBJS) | |||
@mkdir -p $(@D) | |||
$(QUIET_GAC)$(GAP_CXX) -o $@ $(GAP_LDFLAGS) $(GAC_LDFLAGS) $(KEXT_OBJS) $(KEXT_LDFLAGS) | |||
$(QUIET_GAC)$(GAP_CXX) -o $@ $(GAP_LDFLAGS) $(GAC_LDFLAGS) $(KEXT_OBJS) $(KEXT_LDFLAGS) $(LIBSEMIGROUPS_RPATH) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd say this should rather be added to KEXT_LDFLAGS
, that'll be better in the long run. But for now, either works shrug
bdc9239
to
eb71082
Compare
Thanks @fingolfin, @dimpase I just rebased onto |
It's up to you. I'd rather move the 2nd lines of these long error messages a bit to the left, |
You can also wrap the messages in |
which terminals do you know that do not wrap long too lines? In any case, I am sure the message can be improved, but the current form in this PR isn't an improvement anywhere: on terminals that do wrap around it is worse, on terminals that don't it would also be worse, as they still couldn't see most of the second line. |
I think with the change I just pushed they will be again printed as one line - but split in the source. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me now, thanks!
set rpath for external
libsemigroups
, so thatLD_LIBRARY_PATH
is not needed iflibsemigroups
is installed to a non-standard location