Skip to content

Use old memcpy for wrappers#5007

Merged
nicolasnoble merged 5 commits intogrpc:masterfrom
ctiller:memcpy3
Feb 2, 2016
Merged

Use old memcpy for wrappers#5007
nicolasnoble merged 5 commits intogrpc:masterfrom
ctiller:memcpy3

Conversation

@ctiller
Copy link
Copy Markdown
Member

@ctiller ctiller commented Feb 2, 2016

@nathanielmanistaatgoogle, @soltanmm, @jtattermusch, @murgatroid99 - PTAL

If LDFLAGS=-Wl,-wrap,memcpy is passed, we link against memcpy from libc2.2.5, otherwise we link against whatever is in the libc on the machine.

Additionally, for Python:
Set visibility=hidden for all symbols, and make the module initializer non-hidden. This will prevent crashes should another library load a (potentially incompatible) openssl.

@soltanmm
Copy link
Copy Markdown
Contributor

soltanmm commented Feb 2, 2016

setup.py changes lgtm

@nicolasnoble
Copy link
Copy Markdown
Contributor

I'll do the ruby change later on.

nicolasnoble added a commit that referenced this pull request Feb 2, 2016
Use old memcpy for wrappers
@nicolasnoble nicolasnoble merged commit 9e9e2f7 into grpc:master Feb 2, 2016
@jtattermusch
Copy link
Copy Markdown
Contributor

Seems to kill C# x86 artifact build

https://grpc-testing.appspot.com/view/Artifacts/job/gRPC_build_artifacts/90/architecture=x86,language=csharp,platform=linux/console

[LD]      Linking /var/local/git/grpc/libs/opt/libgpr.so.0.13.0.0
/usr/bin/ld: /var/local/git/grpc/libs/opt/libgpr.so.0.13.0.0: No symbol version section for versioned symbol `memcpy@GLIBC_2.2.5'
/usr/bin/ld: final link failed: Nonrepresentable section on output
collect2: error: ld returned 1 exit status

@jtattermusch
Copy link
Copy Markdown
Contributor

How to reproduce:
tools/run_tests/task_runner.py -f artifact csharp linux x86

@jtattermusch
Copy link
Copy Markdown
Contributor

@jtattermusch
Copy link
Copy Markdown
Contributor

On mac:

ld: unknown option: -wrap
clang: error: linker command failed with exit code 1 (use -v to see invocation)

@ctiller
Copy link
Copy Markdown
Member Author

ctiller commented Feb 2, 2016

Mac should be easy (adding some conditional)

On Tue, Feb 2, 2016 at 1:49 PM Jan Tattermusch notifications@github.com
wrote:

On mac:

ld: unknown option: -wrap
clang: error: linker command failed with exit code 1 (use -v to see invocation)


Reply to this email directly or view it on GitHub
#5007 (comment).

@lock lock bot locked as resolved and limited conversation to collaborators Jan 28, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants