Changeset 9109

Show
Ignore:
Timestamp:
10/26/11 15:27:18 (19 months ago)
Author:
walt
Message:

Fixing scandir and dlfcn issues for SL

Location:
branches/Orange-Branch
Files:
3 modified

Legend:

Unmodified
Added
Removed
  • branches/Orange-Branch/configure

    r9108 r9109  
    1500715007fi; 
    1500815008 
     15009echo "$as_me:$LINENO: checking if dlfns needs explicit library request" >&5 
     15010echo $ECHO_N "checking if dlfns needs explicit library request... $ECHO_C" >&6 
     15011cat >conftest.$ac_ext <<_ACEOF 
     15012 
     15013#define _GNU_SOURCE 1 
     15014#include <dlfcn.h> 
     15015main() {void *p = dlsym(RTLD_DEFAULT,"sym");} 
     15016 
     15017_ACEOF 
     15018rm -f conftest.$ac_objext conftest$ac_exeext 
     15019if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 
     15020  (eval $ac_link) 2>conftest.er1 
     15021  ac_status=$? 
     15022  grep -v '^ *+' conftest.er1 >conftest.err 
     15023  rm -f conftest.er1 
     15024  cat conftest.err >&5 
     15025  echo "$as_me:$LINENO: \$? = $ac_status" >&5 
     15026  (exit $ac_status); } && 
     15027         { ac_try='test -z "$ac_c_werror_flag" 
     15028                         || test ! -s conftest.err' 
     15029  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 
     15030  (eval $ac_try) 2>&5 
     15031  ac_status=$? 
     15032  echo "$as_me:$LINENO: \$? = $ac_status" >&5 
     15033  (exit $ac_status); }; } && 
     15034         { ac_try='test -s conftest$ac_exeext' 
     15035  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5 
     15036  (eval $ac_try) 2>&5 
     15037  ac_status=$? 
     15038  echo "$as_me:$LINENO: \$? = $ac_status" >&5 
     15039  (exit $ac_status); }; }; then 
     15040 
     15041    echo "$as_me:$LINENO: result: no" >&5 
     15042echo "${ECHO_T}no" >&6 
     15043 
     15044else 
     15045  echo "$as_me: failed program was:" >&5 
     15046sed 's/^/| /' conftest.$ac_ext >&5 
     15047 
     15048 
     15049    echo "$as_me:$LINENO: result: yes" >&5 
     15050echo "${ECHO_T}yes" >&6 
     15051    LIBS="$LIBS -ldl" 
     15052 
     15053fi 
     15054rm -f conftest.err conftest.$ac_objext \ 
     15055      conftest$ac_exeext conftest.$ac_ext 
     15056 
    1500915057BUILD_UCACHE= 
    1501015058# Check whether --enable-ucache or --disable-ucache was given. 
     
    1510815156/* end confdefs.h.  */ 
    1510915157 
    15110 #define __USE_LARGEFILE64 
     15158#define _LARGEFILE64_SOURCE 1 
     15159#define _GNU_SOURCE 1 
    1511115160#include <dirent.h> 
    1511215161int scandir (const char *dir, struct dirent ***list, 
  • branches/Orange-Branch/configure.in

    r9108 r9109  
    847847fi]) 
    848848 
     849dnl Method to check if dl calls need an explicit link flag 
     850AC_MSG_CHECKING(if dlfns needs explicit library request) 
     851AC_LINK_IFELSE( 
     852[ 
     853#define _GNU_SOURCE 1 
     854#include <dlfcn.h> 
     855main() {void *p = dlsym(RTLD_DEFAULT,"sym");} 
     856],[ 
     857    AC_MSG_RESULT(no) 
     858],[ 
     859    AC_MSG_RESULT(yes) 
     860    LIBS="$LIBS -ldl" 
     861]) 
     862 
    849863dnl Method to enable user interface data cache 
    850864BUILD_UCACHE= 
     
    884898AC_MSG_CHECKING(for scandir compare arg using void pointers) 
    885899AC_TRY_COMPILE([ 
    886 #define __USE_LARGEFILE64 
     900#define _LARGEFILE64_SOURCE 1 
     901#define _GNU_SOURCE 1 
    887902#include <dirent.h> 
    888903int scandir (const char *dir, struct dirent ***list, 
  • branches/Orange-Branch/src/client/usrint/stdio.c

    r9108 r9109  
    25882588    } 
    25892589    /* now sort entries */ 
    2590     qsort(*namelist, i, sizeof(struct dirent *), compar); 
     2590    qsort(*namelist, i, sizeof(struct dirent *), (__compar_fn_t)compar); 
    25912591    rc = closedir(dp); 
    25922592    if (rc == -1)