Skip to content
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

Makefile.am: Fix underlinking #50

Merged
merged 1 commit into from
Nov 29, 2016
Merged

Makefile.am: Fix underlinking #50

merged 1 commit into from
Nov 29, 2016

Conversation

sardemff7
Copy link
Contributor

No description provided.

$(top_builddir)/libmypaint.la \
$(top_builddir)/gegl/libmypaint-gegl.la \
$(top_builddir)/tests/libmypaint-tests.a
$(top_builddir)/gegl/libmypaint-gegl.la
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does ordering matter here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes. Try adding -Wl,--no-undefined to your `LDFLAGS’ and test with and without this patch. :-)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Strictly speaking, shouldn't $(GEGL_LIBS) be last?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh, strictly speaking, yes.

@achadwick
Copy link
Member

Hi there - what underlinking problem does this solve? We already use LIBS = @LIBS since 78ac562 and -no-undefined since bf3cd0c.

$ ldd -r .libs/libmypaint.so >/dev/null
[no output]

But that's only the "direct" case, of course.

@sardemff7
Copy link
Contributor Author

Here are the logs:
without the patch
with the first part (without the reordering)
I use -Wl,--as-needed too, and note that -no-undefined is not very strong, libtool often ignore it.

You’re right about $(LIBS) but it is good practice to avoid putting everything in that an relying on the default values. *_LIBADD (and not *_LIBS, nor *_LDADD since you are building libs here) is cleaner.

Also, LIBS contains -lm as you use AC_SEARCH_LIBS.

I started an Autotools usage cleanup, but you do use a lot of shortcuts, so a simple fix will do for now. :-)

Signed-off-by: Quentin Glidic <[email protected]>
@achadwick achadwick merged commit 3ed8f6a into mypaint:master Nov 29, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants