build fail @ "xulrunner-sdk/include/mozilla/Atomics.h" when using xulrunner-sdk >= v25.0, on linux/64 with gcc 4.7x/4.8x

2013-11-15 Thread opsdmt
hi,

I've installed,,

/usr/local/xulrunner-sdk/bin/xulrunner --version
Mozilla XULRunner 25.0.1 - 20131112160018

on

uname -a
Linux andromeda 3.7.10-1.16-desktop #1 SMP PREEMPT Fri May 31 
20:21:23 UTC 2013 (97c14ba) x86_64 x86_64 x86_64 GNU/Linux

using EITHER,

gcc -v
Using built-in specs.
COLLECT_GCC=gcc

COLLECT_LTO_WRAPPER=/usr/lib64/gcc/x86_64-suse-linux/4.7/lto-wrapper
Target: x86_64-suse-linux
Configured with: ../configure --prefix=/usr 
--infodir=/usr/share/info --mandir=/usr/share/man --libdir=/usr/lib64 
--libexecdir=/usr/lib64 --enable-languages=c,c++,objc,fortran,obj-c++,java,ada 
--enable-checking=release --with-gxx-include-dir=/usr/include/c++/4.7 
--enable-ssp --disable-libssp --disable-libitm --disable-plugin 
--with-bugurl=http://bugs.opensuse.org/ --with-pkgversion='SUSE Linux' 
--disable-libgcj --disable-libmudflap --with-slibdir=/lib64 --with-system-zlib 
--enable-__cxa_atexit --enable-libstdcxx-allocator=new --disable-libstdcxx-pch 
--enable-version-specific-runtime-libs --enable-linker-build-id 
--program-suffix=-4.7 --enable-linux-futex --without-system-libunwind 
--with-arch-32=i586 --with-tune=generic --build=x86_64-suse-linux
Thread model: posix
gcc version 4.7.3 (SUSE Linux) 

or

gcc -v
Using built-in specs.
COLLECT_GCC=gcc

COLLECT_LTO_WRAPPER=/usr/lib64/gcc/x86_64-suse-linux/4.8/lto-wrapper
Target: x86_64-suse-linux
Configured with: ../configure --prefix=/usr 
--infodir=/usr/share/info --mandir=/usr/share/man --libdir=/usr/lib64 
--libexecdir=/usr/lib64 --enable-languages=c,c++,objc,fortran,obj-c++,java,ada 
--enable-checking=release --with-gxx-include-dir=/usr/include/c++/4.8 
--enable-ssp --disable-libssp --disable-plugin 
--with-bugurl=http://bugs.opensuse.org/ --with-pkgversion='SUSE Linux' 
--disable-libgcj --disable-libmudflap --with-slibdir=/lib64 --with-system-zlib 
--enable-__cxa_atexit --enable-libstdcxx-allocator=new --disable-libstdcxx-pch 
--enable-version-specific-runtime-libs --enable-linker-build-id 
--enable-linux-futex --program-suffix=-4.8 --without-system-libunwind 
--with-arch-32=i586 --with-tune=generic --build=x86_64-suse-linux 
--host=x86_64-suse-linux
Thread model: posix
gcc version 4.8.2 20131016 [gcc-4_8-branch revision 203692] 
(SUSE Linux) 

a downstream build dependent on xulrunner-sdk, e.g., here, of 
'gecko-mediaplayer', 

svn co http://gecko-mediaplayer.googlecode.com/svn/trunk/ 
gecko-mediaplayer
cd gecko-mediaplayer
svn log | head


r527 | kdekorte | 2013-09-16 13:04:30 -0700 (Mon, 16 Sep 2013) 
| 1 line

v1.0.9a


r526 | kdekorte | 2013-08-02 05:50:05 -0700 (Fri, 02 Aug 2013) 
| 1 line

Updated German translation


r525 | kdekorte | 2013-06-26 21:30:27 -0700 (Wed, 26 Jun 2013) 
| 1 line

succeeds if using xulrunner-sdk < v25.0, but fails on upgrade to v25.0/v25.0.1

export CPPFLAGS="-I/usr/local/xulrunner-sdk/include 
-I/usr/include/nspr4"
./configure --with-xulrunner-sdk=/usr/local/xulrunner-sdk
make
...
make  all-recursive
make[1]: Entering directory `/usr/local/src/gecko-mediaplayer'
Making all in src
make[2]: Entering directory 
`/usr/local/src/gecko-mediaplayer/src'
make[3]: Entering directory 
`/usr/local/src/gecko-mediaplayer/src'
  CXX  plugin_types_std.o
plugin_types_std.cpp: In function ‘gchar* GetMIMEDescription()’:
plugin_types_std.cpp:46:5: warning: ‘void g_type_init()’ is 
deprecated (declared at /usr/include/glib-2.0/gobject/gtype.h:669) 
[-Wdeprecated-declarations]
 g_type_init();
 ^
plugin_types_std.cpp:46:17: warning: ‘void g_type_init()’ is 
deprecated (declared at /usr/include/glib-2.0/gobject/gtype.h:669) 
[-Wdeprecated-declarations]
 g_type_init();
 ^
  CXX  plugin.o
In file included from 
/usr/local/xulrunner-sdk/include/nsISupportsImpl.h:33:0,
 from 
/usr/local/xulrunner-sdk/include/nsISupportsUtils.h:26,
 from 
/usr/local/xulrunner-sdk/include/nsISupports.h:123,
 from 
/usr/local/xulrunner-sdk/include/nsIPrefBranch.h:10,
 from plugin.c

Re: build fail @ "xulrunner-sdk/include/mozilla/Atomics.h" when using xulrunner-sdk >= v25.0, on linux/64 with gcc 4.7x/4.8x

2013-11-15 Thread opsdmt
@Jeff

reading here,

  http://gcc.gnu.org/projects/cxx0x.html

adding either

  export CXXFLAGS="-std=gnu++0x"

or

  export CXXFLAGS="-std=gnu++11"

both seem to work.  From Mozilla's perspective -- is one preferable?
___
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform


Re: build fail @ "xulrunner-sdk/include/mozilla/Atomics.h" when using xulrunner-sdk >= v25.0, on linux/64 with gcc 4.7x/4.8x

2013-11-15 Thread opsdmt
> FWIW, it looks like Mozilla uses the former (gnu++0x) in the build system:
> http://mxr.mozilla.org/mozilla-central/source/build/autoconf/toolchain.m4?mark=152-153#145

Good enough, thanks!
___
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform


Re: build fail @ "xulrunner-sdk/include/mozilla/Atomics.h" when using xulrunner-sdk >= v25.0, on linux/64 with gcc 4.7x/4.8x

2013-11-16 Thread opsdmt
iiuc, any app built against new xulrunner will need to be aware of this.

@ a downstream app, a dev suggested

"Sounds like something that xulrunner should provide in there .pc file. So that 
when pkg-config --cflags xulrunner is run (which configure does do). This value 
should come out."

sounds reasonable.

checking in xulrunner-sdk/, only an 'nspr' pkg-config is available,

find . -name *\.pc
  ./lib/pkgconfig/nspr.pc
  ./sdk/lib/pkgconfig/nspr.pc

nothing for xulrunner itself, i.e., no mention/suggestion of the "-std=gnu++0x" 
flag.

in any case, pkg-config provides CFLAGS, not CXXFLAGS ...

EVENTUALLY, this'll get dealt with in distros' gcc.

until then / for now, can/should this be flagged from within xulrunner 
code/config? or at the end-use app's configure stage?
___
dev-platform mailing list
dev-platform@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-platform