roadlabs / chromiumembedded

Automatically exported from code.google.com/p/chromiumembedded
0 stars 1 forks source link

Linux: Support Debian 7 by linking an older glibc version when building on Ubuntu #1575

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Attempt to run a binary distribution on Debian 7 that was built using Ubuntu 
14.

What is the expected output? What do you see instead?
It should run successfully. Instead, get the following error:

./../Release/libcef.so: undefined reference to `memcpy@GLIBC_2.14'

Please use labels and text to provide additional information.
There are a few potential options for resolving this issue:

1. Link the CEF build against an older version of libc.so (e.g. copied from a 
Debian 7 system).

2. Use the wrap capability to force usage of the older memcpy version:

A. Create `memcpy.c` and add it to the project:

#include <string.h>

/* some systems do not have newest memcpy@@GLIBC_2.14 - stay with old good one 
*/
asm (".symver memcpy, memcpy@GLIBC_2.2.5");

void *__wrap_memcpy(void *dest, const void *src, size_t n) {
    return memcpy(dest, src, n);
}

B. Link the resulting program with `-Wl,--wrap=memcpy`.

Related reading:
http://stackoverflow.com/questions/8823267/linking-against-older-symbol-version-
in-a-so-file
https://blogs.gnome.org/tvb/2013/12/14/application-bundles-revisited/

The challenge will be finding a minimally intrusive technique for getting CEF 
and all Chromium dependencies to link using the new approach.

Original issue reported on code.google.com by magreenb...@gmail.com on 11 Mar 2015 at 8:14

GoogleCodeExporter commented 9 years ago
CEF can also be built on Debian 7 systems. Instructions are here: 
https://code.google.com/p/chromiumembedded/wiki/BuildingOnDebian7

Original comment by magreenb...@gmail.com on 11 Mar 2015 at 9:38

GoogleCodeExporter commented 9 years ago
CEF is transitioning from Google Code to Bitbucket project hosting. If you 
would like to continue receiving notifications on this issue please add 
yourself as a Watcher at the new location: 
https://bitbucket.org/chromiumembedded/cef/issue/1575

Original comment by magreenb...@gmail.com on 14 Mar 2015 at 3:39