RPM Package Manager, CVS Repository
  http://rpm5.org/cvs/
  ____________________________________________________________________________

  Server: rpm5.org                         Name:   Pinto Elia
  Root:   /v/rpm/cvs                       Email:  devzero2...@rpm5.org
  Module: popt                             Date:   05-Sep-2011 13:20:27
  Branch: HEAD                             Handle: 2011090511202700

  Modified files:
    popt                    CHANGES system.h test1.c

  Log:
    merge  commit ea2978d from git pull request
    https://github.com/devzero2000/POPT/pull/2
    "Fix build with MinGW 32/64 + MSVC" by arsenm
    (Matt Arsenault)

  Summary:
    Revision    Changes     Path
    1.166       +4  -0      popt/CHANGES
    1.23        +12 -8      popt/system.h
    1.52        +2  -2      popt/test1.c
  ____________________________________________________________________________

  patch -p0 <<'@@ .'
  Index: popt/CHANGES
  ============================================================================
  $ cvs diff -u -r1.165 -r1.166 CHANGES
  --- popt/CHANGES      16 Jun 2011 15:26:43 -0000      1.165
  +++ popt/CHANGES      5 Sep 2011 11:20:27 -0000       1.166
  @@ -1,4 +1,8 @@
   1.17 -> 2.0:
  +    - devzero2000: merge  commit ea2978d from git pull request 
  +      https://github.com/devzero2000/POPT/pull/2 
  +      "Fix build with MinGW 32/64 + MSVC" by arsenm
  +      (Matt Arsenault)
       - devzero2000: fix compiler warning -Wunused-but-set-variable (GCC 4.6)
       - devzero2000: redo the autofu vendor-script linker script check for 
openindiana native
         ld, using modern and not deprecated autoconf construct. Even if the 
check is not perfect 
  @@ .
  patch -p0 <<'@@ .'
  Index: popt/system.h
  ============================================================================
  $ cvs diff -u -r1.22 -r1.23 system.h
  --- popt/system.h     14 Apr 2011 12:40:49 -0000      1.22
  +++ popt/system.h     5 Sep 2011 11:20:27 -0000       1.23
  @@ -56,6 +56,9 @@
   
   #ifdef _MSC_VER
   #  define inline __inline
  +#endif
  +
  +#if defined(_MSC_VER) || defined(__MINGW32__)
   #define _CRT_SECURE_NO_WARNINGS 1
   #include <io.h>
   #include <malloc.h>
  @@ -109,18 +112,19 @@
   #define lseek _lseek
   
   /* Pretend to be root to replace these */
  -inline int setuid(int x) { return 1; }
  -inline int getuid(void) { return 0; }
  +static inline int setuid(int x) { return 1; }
  +
  +static inline int getuid(void) { return 0; }
   
  -inline int seteuid(int x) { return 1; }
  -inline int geteuid(void) { return 0; }
  +static inline int seteuid(int x) { return 1; }
  +static inline int geteuid(void) { return 0; }
   
  -inline int setgid(int x) { return 1; }
  -inline int getgid(void) { return 0; }
  +static inline int setgid(int x) { return 1; }
  +static inline int getgid(void) { return 0; }
   
  -inline int setegid(int x) { return 1; }
  +static inline int setegid(int x) { return 1; }
   
  -#endif /* _MSC_VER */
  +#endif /* defined(_MSC_VER) || defined(__MINGW32__) */
   
   #ifdef __NeXT
   /* access macros are not declared in non posix mode in unistd.h -
  @@ .
  patch -p0 <<'@@ .'
  Index: popt/test1.c
  ============================================================================
  $ cvs diff -u -r1.51 -r1.52 test1.c
  --- popt/test1.c      26 Jul 2010 16:23:41 -0000      1.51
  +++ popt/test1.c      5 Sep 2011 11:20:27 -0000       1.52
  @@ -256,6 +256,7 @@
       const char ** rest;
       int help = 0;
       int usage = 0;
  +    char * testpoptrc;
   
   #if defined(HAVE_MCHECK_H) && defined(HAVE_MTRACE)
       /*@-moduncon -noeffectuncon@*/
  @@ -269,9 +270,8 @@
   /*@-temptrans@*/
       optCon = poptGetContext("test1", argc, argv, options, 0);
   #ifdef HAVE_STDLIB_H
  -    char * testpoptrc;
       testpoptrc = getenv ("testpoptrc");
  -    if (testpoptrc != NULL ) 
  +    if (testpoptrc != NULL )
       (void) poptReadConfigFile(optCon, testpoptrc);
       else {
       (void) poptReadConfigFile(optCon, "./test-poptrc");
  @@ .
______________________________________________________________________
RPM Package Manager                                    http://rpm5.org
CVS Sources Repository                                rpm-cvs@rpm5.org

Reply via email to