Linking globals named 'glewExperimental': symbol multiply defined!

383 views
Skip to first unread message

wolfviking0

unread,
Jan 21, 2014, 10:14:01 AM1/21/14
to emscripte...@googlegroups.com

Hi,


I just update the last incoming branch for update my project, and I have some trouble when I build some sample.


/Users/aliot/Desktop/webcl/compilo/llvm/3.2/bin/llvm-link: link error in '/tmp/tmpqtmZzd/gltools_4.o': Linking globals named 'glewExperimental': symbol multiply defined!

Traceback (most recent call last):

  File "../../emscripten/emcc", line 1789, in <module>

    shared.Building.link(linker_inputs, in_temp(target_basename + '.bc'), force_archive_contents = len(filter(lambda temp: not temp.endswith(STATICLIB_ENDINGS), temp_files)) == 0)

  File "/Users/aliot/Desktop/webcl/webcl-translator/emscripten/tools/shared.py", line 1152, in link

    assert os.path.exists(target) and (output is None or 'Could not open input file' not in output), 'Linking error: ' + output

AssertionError: Linking error: 

make: *** [attractor_sample] Error 1

imac-de-anthony:webcl aliot$ 


What does that means ???


Need change some settings ???


Best 


Tony

Jukka Jylänki

unread,
Jan 21, 2014, 10:34:26 AM1/21/14
to emscripte...@googlegroups.com
This is a very recent regression. Several people have reported it already, so I just went ahead and pushed a workaround to incoming. See https://github.com/kripken/emscripten/commit/19a38d059bd6da1402edd3dc13c8485025059fa7 . That workaround is ok atm since glewExperimental is ignored in emscripten anyways, so static linkage won't cause trouble in this one.

The proper fix would be to have it extern and link that variable in from its own compilation unit, but currently I don't think we have that kind of machinery in place for linking js libraries, so will have to settle for that.


2014/1/21 wolfviking0 <anthon...@gmail.com>

--
You received this message because you are subscribed to the Google Groups "emscripten-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to emscripten-disc...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Alon Zakai

unread,
Jan 21, 2014, 4:11:07 PM1/21/14
to emscripte...@googlegroups.com
We handle externs ok in js libraries, for example errno is an extern int and we define it in library.js. Probably better to do that I think.

- Alon

Reply all
Reply to author
Forward
0 new messages