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

seafile-server failing on ARC #9255

Closed
neheb opened this issue Jun 18, 2019 · 6 comments · Fixed by #9278
Closed

seafile-server failing on ARC #9255

neheb opened this issue Jun 18, 2019 · 6 comments · Fixed by #9278

Comments

@neheb
Copy link
Contributor

neheb commented Jun 18, 2019

Maintainer: @commodo

https://downloads.openwrt.org/snapshots/faillogs/arc_arc700/packages/seafile-server/compile.txt

One way I've found to solve this issue is with PKG_SSP:=0. I can't test this as glib2 doesn't build on my setup for some reason.

@commodo
Copy link
Contributor

commodo commented Jun 19, 2019

Tried PKG_SSP:=0
Does not work.

This can be fixed either here, but it may make sense fix this in core.
Thing is, ARC uses uClibc by default, which requires TARGET_LDFLAGS += -lssp be added.

Something like this, seems to work

+ifdef CONFIG_GCC_LIBSSP
+  TARGET_LDFLAGS += -lssp
+endif

I'll try to see about maybe adding this to include/hardening.mk.
But I need to rebuild from scratch to make sure this is fine all the way.

@commodo
Copy link
Contributor

commodo commented Jun 19, 2019

FWIW, there is some insight in this commit openwrt/openwrt@241e6dd

@neheb
Copy link
Contributor Author

neheb commented Jun 19, 2019

Interesting...

My solution to this problem is here: https://github.com/openwrt/packages/blob/master/utils/powertop/Makefile#L43

I reverted and added -lssp to LDFLAGS and that works as well. I wonder if this also fails with glibc...

@commodo
Copy link
Contributor

commodo commented Jun 20, 2019

Adding the patch in include/hardening.mk also works.
After looking around the current packages, I am not completely sure about patching this in core.
There are only 2-3 packages [in the OpenWrt project] that may benefit from this [i.e. patching this in core]; maybe there may be a few others, but I am not sure.

I'll just patch seafile-server only then.

commodo added a commit to commodo/packages that referenced this issue Jun 20, 2019
Fixes: openwrt#9255

This seems to fail the build for this package only.
So, this change patches the build, to add `-lssp` to the LDFLAGS of this
package, in case the build uses GCC's libssp.

Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
yousong pushed a commit that referenced this issue Jun 20, 2019
Fixes: #9255

This seems to fail the build for this package only.
So, this change patches the build, to add `-lssp` to the LDFLAGS of this
package, in case the build uses GCC's libssp.

Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
neheb pushed a commit that referenced this issue Jun 20, 2019
Fixes: #9255

This seems to fail the build for this package only.
So, this change patches the build, to add `-lssp` to the LDFLAGS of this
package, in case the build uses GCC's libssp.

Signed-off-by: Alexandru Ardelean <ardeleanalex@gmail.com>
@neheb
Copy link
Contributor Author

neheb commented Jun 20, 2019

I backported this to 19.07. Hope you don't mind.

@commodo
Copy link
Contributor

commodo commented Jun 20, 2019

No worries from me.

Thanks :)
Alex

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants