bugGnash - The GNU Flash player - Bugs: bug #36642, extensions don't load (FileIO test...

 
 

bug #36642: extensions don't load (FileIO test failing)

Submitter:  Sandro Santilli <strk>
Submitted:  Tue 12 Jun 2012 05:24:36 PM UTC
   
 
Category:  core Severity:  3 - Normal
Release:  master Status:  Works For Me
Privacy:  Public Assigned to:  strk
Open/Closed:  Closed
* Mandatory Fields

Add a New Comment Rich Markup
   

Jump to the original submission

Sat 28 Sep 2013 09:06:17 PM UTC, comment #23: 

Fixed the build part by not allowing enabling of extensions with visibility activated:

http://git.savannah.gnu.org/cgit/gnash.git/commit/?id=4828707774728393761efea26b84e2e525024352

As for the runtime part, extensions will always be disabled when building with them disabled...

Closing this out.

Sandro Santilli <strk>
Group Member
Sat 28 Sep 2013 07:41:59 PM UTC, comment #22: 

Ok, proposal.

When building with hidden visibility the builder would get a WARNING about plugins being unsupported with that kind of build and runner would get an ERROR if extensions are requested to be activated by RC directive.

How do you like it ?

Sandro Santilli <strk>
Group Member
Sat 28 Sep 2013 05:53:18 PM UTC, comment #21: 

For your information, the same plugin works fine when loaded by a Gnash executable built with no hidden symbols, so the problem is not with the plugin but with gnash itself.

Maybe some symbols used by the plugin and not found.

Sandro Santilli <strk>
Group Member
Sat 28 Sep 2013 04:40:39 PM UTC, comment #20: 

Extensions are known to be broken with -fvisibility=hidden. You can try building with -Wl,--no-undefined as I suggested below to find the offending symbols at link time, if you like. But I don't think it's worth fixing this bug.

Bastiaan Jacques <bjacques>
Group Member
Sat 28 Sep 2013 04:33:17 PM UTC, comment #19: 

DSOEXPORT'ing fileio_class_init didn't help.
LD_DEBUG=all may help figuring out more

Sandro Santilli <strk>
Group Member
Sun 14 Jul 2013 01:30:55 PM UTC, comment #18: 

A small correction: -no-undefined is silently ignored by libtool. The compiler and linker are not to be blamed for libtool's failure.

Bastiaan Jacques <bjacques>
Group Member
Sun 14 Jul 2013 11:31:54 AM UTC, comment #17: 

FWIW:

lt_dlopenext returns the unhelpful error 'file not found' even when the shared object exists. If you switch to standard dlopen the first unresolved symbol is shown in dlerror().

Easier is, however, to build with -Wl,--no-undefined in extensions/. (There already is a -no-undefined flag in Makefile.am, which seems to be silently ignored by the compiler and linker.) The only symbol not listed in the output from --no-undefined is the {extension}_class_init, which of course must also have external linkage.

Bastiaan Jacques <bjacques>
Group Member
Thu 28 Feb 2013 04:47:16 PM UTC, comment #16: 

That's as of commit ceaf5e4a988750da050514de5d36f22787d5257e

Sandro Santilli <strk>
Group Member
Thu 28 Feb 2013 04:46:51 PM UTC, comment #15: 

Still fails with --enable-visibility, succeeds without

Sandro Santilli <strk>
Group Member
Tue 26 Feb 2013 09:23:12 PM UTC, comment #14: 

Any status update on this bug ?

Rob Savoye <rsavoye>
Group administrator
Fri 01 Feb 2013 06:07:21 AM UTC, comment #13: 

Oh, nice, I see commits of you about visibility and flags.
Will try again after pulling 118600cd59d4ebfc6b557b162cfe25e9f510da53

Sandro Santilli <strk>
Group Member
Fri 01 Feb 2013 06:05:46 AM UTC, comment #12: 

I filed bug #38217 to track the build issue. Let's keep this one for the extensions. I can tell you that even with a vanilla ./configure (all the rest builds) I'm still having issue with FileIO:

Test Result Totals:
        Total passes: 48974
        Total unresolved: 9
        Total expected failures: 1944
        Total untested: 423
        * Total real failures: 9

Unexpected failures follow:
 --=[ extensions/fileio ]=--
FAIL: test: FileIO::open() [31]
FAIL: test: FileIO::fputs() [37]
FAIL: test: FileIO::fseek() [46]
FAIL: test: FileIO::fflush() [52]
FAIL: test: FileIO::ftell() [58]
FAIL: test: FileIO::fgetc() [65]
FAIL: test: FileIO::fgets() [73]
FAIL: test: FileIO::putchar() [85]
FAIL: test: FileIO::puts() [91]

make: * [anal] Error 1

Sandro Santilli <strk>
Group Member
Thu 31 Jan 2013 07:26:18 PM UTC, comment #11: 

I'd suggest doing a "make clean" or "make distclean". I can't reproduce this symbol problem on any of my machines, so I assume it's a problem with your build. Your CXXFLAGS looks wrong, btw...

Rob Savoye <rsavoye>
Group administrator
Thu 31 Jan 2013 07:24:10 PM UTC, comment #10: 

Uff with CFLAGS/CXXFLAGS not overridden the build is still not 100% fine. There are undefined references to  core symbols:
make[1]: Entering directory `/home/src/gnash/build/head/vanilla/testsuite/samples'
  CXXLD  clip_as_button2-TestRunner
../../testsuite/.libs/libtestsuite.a(libtestsuite_la-MovieTester.o): In function `gnash::MovieTester::findDisplayItemByName(gnash::MovieClip const&, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)':
/usr/src/gnash/gnash-head/testsuite/MovieTester.cpp:334: undefined reference to `gnash::getStringTable(gnash::as_object const&)'


make dumpconfig shows:
CXXFLAGS: -g -O2          -W     -Wall     -Wcast-align     -Wcast-qual     -Wpointer-arith     -Wreturn-type     -Wnon-virtual-dtor     -Wunused      -fvisibility-inlines-hidden -fvisibility=hidden

Can it be the visibility flag ? Does it default to hidden now ?

Sandro Santilli <strk>
Group Member
Thu 31 Jan 2013 03:29:40 PM UTC, comment #9: 

The way you are setting them in your environment will override the configure determined settings. The way it's supposed to work is to let configure do it's thing, then supply any modified CFLAGS/CXXFLAGS on the command line to make. So we are honoring user flags by forcibly redefining them when you configure.

Rob Savoye <rsavoye>
Group administrator
Thu 31 Jan 2013 01:03:35 PM UTC, comment #8: 

It turns out that my overrides of CFLAGS/CXXFLAGS are the offending ones. If I don't defined them, build is fine.
Is that expected ? Should we always honour user flags ?

Sandro Santilli <strk>
Group Member
Thu 31 Jan 2013 11:13:32 AM UTC, comment #7: 

ouch, actually also the build is not completely fixed either.
The build of "Dejagnu" itself is, but there are other part of the testsuite which are failing due to missing symbols.

Example, in testsuite/misc-ming.all:
  CXXLD  ResolveEventsTest-Runner
../../testsuite/.libs/libtestsuite.a(libtestsuite_la-MovieTester.o): In function `gnash::MovieTester::findDisplayItemByName(gnash::MovieClip const&, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)':
/usr/src/gnash/gnash-head/testsuite/MovieTester.cpp:334: undefined reference to `gnash::getStringTable(gnash::as_object const&)'
/usr/src/gnash/gnash-head/testsuite/MovieTester.cpp:335: undefined reference to `gnash::getVM(gnash::as_object const&)'
/usr/src/gnash/gnash-head/testsuite/MovieTester.cpp:336: undefined reference to `gnash::DisplayList::getDisplayObjectByName(gnash::string_table&, gnash::ObjectURI const&, bool) const'


I'm setting CFLAGS and CXXFLAGS in the env before configuring:
export CFLAGS="${CFLAGS} -O2 -g -m64"
export CXXFLAGS="${CXXFLAGS} -O2 -g -m64"

Sandro Santilli <strk>
Group Member
Thu 31 Jan 2013 10:54:00 AM UTC, comment #6: 

Thanks, your commit fixes the build of tests for me, but FileIO test still fails (rebuilt from scratch)

Sandro Santilli <strk>
Group Member
Wed 30 Jan 2013 06:58:28 PM UTC, comment #5: 

Should be fixed with commit #d58d080. I added the shared compilation flag to CFLAGS, it was already in CXXFLAGS. You
 also might want to start by removing any old plugins .so files to get a clean start. It's working fine for me on several distros now.

Rob Savoye <rsavoye>
Group administrator
Tue 29 Jan 2013 02:30:12 PM UTC, comment #4: 

There seems to be something really bad with my build tree as beside the FileIO test (which interrupt the whole 'make check' process) I can't build Dejagnu under testsuite/misc-ming.all:

/usr/bin/ld: Dejagnu.o: relocation R_X86_64_32 against `.rodata.str1.1' can not be used when making a shared object; recompile with -fPIC

Any idea ?

Sandro Santilli <strk>
Group Member
Mon 28 Jan 2013 09:12:10 AM UTC, comment #3: 

I'm on Ubuntu 12.04.1 LTS ("precise")

Sandro Santilli <strk>
Group Member
Fri 25 Jan 2013 09:03:07 PM UTC, comment #2: 

  When I try master on a Fedora machine, it works just fine. Are you on Debian or Ubuntu ? If so, I'll have to test there too. Here's what I get from "make check"

19090:1] 3 SECURITY: Extensions enabled, scanning plugin dir for load
19090:1] 3 SECURITY: Loading module: fileio from /home/rob/projects/gnu/i686-pc-linux-gnu/gnash/master/extensions/fileio/.libs
19090:1] 3 SECURITY: Initializing module: "fileio" from /home/rob/projects/gnu/i686-pc-linux-gnu/gnash/master/extensions/fileio/.libs
19090:1] 6 TRACE: [dejagnu.as master-21616-673c5de]
19090:1] 6 TRACE: SWF - LNX 10,0,12,36

PASS: test: FileIO::open() [29]
PASS: test: FileIO::fputs() [35]
PASS: test: FileIO::fseek() [44]
PASS: test: FileIO::fflush() [50]
PASS: test: FileIO::ftell() [56]
PASS: test: FileIO::fgetc() [63]
PASS: test: FileIO::fgets() [71]
PASS: test: FileIO::putchar() [83]
PASS: test: FileIO::puts() [89]

===  Summary ===

# of expected passes 9

Rob Savoye <rsavoye>
Group administrator
Fri 25 Jan 2013 04:19:36 PM UTC, comment #1: 

Still happens as of Gnash 0.8.11dev (master-21615-45a1c2f)
I have libtool and libltdl 2.4.2

Sandro Santilli <strk>
Group Member
Tue 12 Jun 2012 05:24:36 PM UTC, original submission:  

7068:1] 6 SECURITY: Initializing module: "fileio" from /extra/gnash-dev/lib/gnash/plugins
27068:1] 6 DEBUG: Trying to open shared library "/extra/gnash-dev/lib/gnash/plugins/fileio.so"
27068:1] 7 ERROR: lt_dlopenext(/extra/gnash-dev/lib/gnash/plugins/fileio.so): file not found

/extra/gnash-dev/lib/gnash/plugins/fileio.so: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, not stripped

Gnash 0.8.11dev (master-21585-e0bc76c)

Sandro Santilli <strk>
Group Member

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by bjacques (Posted a comment)
  • -email is unavailable- added by rsavoye (Updated the item)
  • -email is unavailable- added by strk (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follow 12 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2013-09-28 strk StatusConfirmed Works For Me
        Assigned torsavoye strk
        Open/ClosedOpen Closed
    2013-09-28 strk Summaryextensions don\'t load (FileIO test failing) with -fvisibility=hidden extensions don't load (FileIO test failing)
    2013-09-28 bjacques Summaryextensions don\'t load (FileIO test failing) extensions don't load (FileIO test failing) with -fvisibility=hidden
    2013-02-28 strk StatusReady For Test Confirmed
    2013-02-26 rsavoye StatusConfirmed Ready For Test
    2013-01-31 rsavoye Assigned toNone rsavoye
    2013-01-31 strk StatusReady For Test Confirmed
    2013-01-31 rsavoye StatusConfirmed Ready For Test
    2013-01-31 strk StatusReady For Test Confirmed
    2013-01-30 rsavoye StatusNone Ready For Test

    Back to the top

    Powered by Savane 3.13-02a9.
    Corresponding source code