Changeset 846 for trunk/config.tests/unix/fvisibility.test
- Timestamp:
- May 5, 2011, 5:36:53 AM (14 years ago)
- Location:
- trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk
- Property svn:mergeinfo changed
/branches/vendor/nokia/qt/4.7.2 (added) merged: 845 /branches/vendor/nokia/qt/current merged: 844 /branches/vendor/nokia/qt/4.6.3 removed
- Property svn:mergeinfo changed
-
trunk/config.tests/unix/fvisibility.test
r2 r846 5 5 VERBOSE=$2 6 6 7 CMDLINE= 8 9 7 10 RunCompileTest() { 8 11 cat >>fvisibility.c << EOF 9 __attribute__((visibility("default"))) void blah(); 10 #if !defined(__GNUC__) 11 # error "Visiblility support requires GCC" 12 #elif __GNUC__ < 4 13 # error "GCC3 with backported visibility patch is known to miscompile Qt" 12 #if defined(__GNUC__) 13 # if (__GNUC__ < 4) 14 # error "GCC3 with backported visibility patch is known to miscompile Qt" 15 # endif 16 __attribute((visibility("default"))) void blah(); 17 #elif defined(__SUNPRO_CC) 18 # if (__SUNPRO_CC < 0x0550) 19 # error "SunStudio 8 or later is required for ELF visibility" 20 # endif 21 __global void blah(); 22 #else 23 # error "GCC4+ or SunStudio 8+ are required to support ELF visibility" 14 24 #endif 15 25 EOF 16 26 17 27 if [ "$VERBOSE" = "yes" ] ; then 18 "$COMPILER" -c -fvisibility=hiddenfvisibility.c && FVISIBILITY_SUPPORT=yes28 "$COMPILER" -c $CMDLINE fvisibility.c && FVISIBILITY_SUPPORT=yes 19 29 else 20 "$COMPILER" -c -fvisibility=hiddenfvisibility.c >/dev/null 2>&1 && FVISIBILITY_SUPPORT=yes30 "$COMPILER" -c $CMDLINE fvisibility.c >/dev/null 2>&1 && FVISIBILITY_SUPPORT=yes 21 31 fi 22 32 rm -f fvisibility.c fvisibility.o 23 33 } 24 34 35 25 36 case "$COMPILER" in 37 *g++*|*c++*) 38 CMDLINE="-fvisibility=hidden" 39 RunCompileTest 40 ;; 41 26 42 aCC*) 27 43 ;; … … 35 51 *) 36 52 # the compile test works for the intel compiler because it mimics gcc's behavior 53 CMDLINE="-fvisibility=hidden" 37 54 RunCompileTest 38 55 ;; … … 40 57 ;; 41 58 42 *) 43 RunCompileTest 44 ;; 59 CC) 60 # This should be SunStudio. If not, it'll get caught. 61 CMDLINE="-xldscope=hidden" 62 RunCompileTest 63 ;; 45 64 esac 46 65
Note:
See TracChangeset
for help on using the changeset viewer.