Merge branch 'release-4-5-patches'
authorDavid van der Spoel <spoel@xray.bmc.uu.se>
Wed, 25 Aug 2010 12:13:21 +0000 (14:13 +0200)
committerDavid van der Spoel <spoel@xray.bmc.uu.se>
Wed, 25 Aug 2010 12:13:21 +0000 (14:13 +0200)
Conflicts:
include/resall.h
include/string2.h
include/thread_mpi/atomic/xlc_ppc.h
include/vec.h
src/kernel/pdb2top.c

1  2 
include/resall.h
include/string2.h
include/thread_mpi/atomic/xlc_ppc.h
include/vec.h
src/kernel/pdb2top.c

index 4349551b525a56bac6ed03b43d8b7bab46947488,e23f8080091432d8f44b6cba60cd8fa281e25cc0..4fb1fa9f3f53f4f1942fe6889b8ac87b65124701
  extern "C" {
  #endif
  
++<<<<<<< HEAD
 +t_restp *search_rtp(const char *key,int nrtp,t_restp rtp[]);
 +/* Search for an entry in the rtp database */
++=======
+ char *search_rtp(const char *key,int nrtp,t_restp rtp[]);
+ /* Search for an entry in the rtp database, returns the rtp residue name.
+  * A mismatch of one character is allowed, if there is only one nearly
+  * matching entry in the database, a warning will be generated.
+  */
+ t_restp *get_restp(const char *rtpname,int nrtp,t_restp rtp[]);
+ /* Return the entry in the rtp database with rtp name rtpname.
+  * Generates a fatal error when rtpname is not found.
+  */
++>>>>>>> release-4-5-patches
  
  gpp_atomtype_t read_atype(const char *ffdir,t_symtab *tab);
  /* read atom type database(s) */
index 7f28075eb8ca46be97c07e5fdcf5b7bcf3b3f497,5077c3409b7ef3516dbf6b5f7f45508b78eff4a2..a7d30b745151459015baa94699b405fdc0bbf49e
@@@ -64,61 -64,61 +64,119 @@@ extern "C" 
  #define CONTINUE    '\\'
  #define COMMENTSIGN ';'
  
++<<<<<<< HEAD
 +  int continuing(char *s);
 +
 +  char *fgets2(char *s, int n, FILE *stream);
 +
 +  void strip_comment (char *line);
 +
 +  int break_line (char *line,
 +      char *variable,
 +      char *value);
 +
 +  void upstring (char *str);
 +
 +  void ltrim (char *str);
 +
 +  void rtrim (char *str);
 +
 +  void trim (char *str);
 +
 +  void nice_header (FILE *out,const char *fn);
 +
 +  int gmx_strcasecmp_min(const char *str1, const char *str2);
 +  int gmx_strncasecmp_min(const char *str1, const char *str2, int n);
 +  /* This funny version of strcasecmp, is not only case-insensitive,
 +   * but also ignores '-' and '_'.
 +   */
 +
 +  int gmx_strcasecmp(const char *str1, const char *str2);
 +  int gmx_strncasecmp(const char *str1, const char *str2, int n);
 +
 +  char *gmx_strdup(const char *src);
 +  char *gmx_strndup(const char *src, int n);
 +
 +  /** Pattern matcing with wildcards. */
 +  int gmx_wcmatch(const char *pattern, const char *src);
 +
 +  /** Return value for gmx_wcmatch() when there is no match. */
 +#define GMX_NO_WCMATCH 1
 +
 +
 +  /* this is our implementation of strsep, the thread-safe replacement for
 +     strtok */
 +  char *gmx_strsep(char **stringp, const char *delim);
 +
 +
 +  char *wrap_lines(const char *buf,int line_width, int indent,
 +      bool bIndentFirst);
 +  /* wraps lines at 'linewidth', indenting all following
 +   * lines by 'indent' spaces. A temp buffer is allocated and returned,
 +   * which can be disposed of if no longer needed.
 +   * If !bIndentFirst, then the first line will not be indented, only 
 +   * the lines that are created due to wapping.
 +   */
 +
 +
 +extern char **split(char sep,const char *str);
++=======
+ int continuing(char *s);
+ char *fgets2(char *s, int n, FILE *stream);
+ void strip_comment (char *line);
+ int break_line (char *line,
+                      char *variable,
+                      char *value);
+ void upstring (char *str);
+ void ltrim (char *str);
+ void rtrim (char *str);
+ void trim (char *str);
+ void nice_header (FILE *out,const char *fn);
+ int gmx_strcasecmp_min(const char *str1, const char *str2);
+ int gmx_strncasecmp_min(const char *str1, const char *str2, int n);
+ /* This funny version of strcasecmp, is not only case-insensitive,
+  * but also ignores '-' and '_'.
+  */
+ int gmx_strcasecmp(const char *str1, const char *str2);
+ int gmx_strncasecmp(const char *str1, const char *str2, int n);
+ char *gmx_strdup(const char *src);
+ char *gmx_strndup(const char *src, int n);
+     
+ /** Pattern matcing with wildcards. */
+ int gmx_wcmatch(const char *pattern, const char *src);
+ /** Return value for gmx_wcmatch() when there is no match. */
+ #define GMX_NO_WCMATCH 1
+ /* this is our implementation of strsep, the thread-safe replacement for
+    strtok */
+ char *gmx_strsep(char **stringp, const char *delim);
+ char *wrap_lines(const char *buf,int line_width, int indent,
+                       bool bIndentFirst);
+ /* wraps lines at 'linewidth', indenting all following
+  * lines by 'indent' spaces. A temp buffer is allocated and returned,
+  * which can be disposed of if no longer needed.
+  * If !bIndentFirst, then the first line will not be indented, only 
+  * the lines that are created due to wapping.
+  */
+ char **split(char sep,char *str);
++>>>>>>> release-4-5-patches
  /* Implementation of the well-known Perl function split */
  
  gmx_large_int_t str_to_large_int_t(const char *str, char **endptr);
index e013c6f3c0b1c14c3cd97f215155260ef790fc29,214a3a30258569ea9a48fe12f75f5f276ac5fd14..af16be35f823cdf92720231fc883d5d099ffc59f
@@@ -50,7 -50,7 +50,11 @@@ files
  #endif
  
  
++<<<<<<< HEAD
 +#define tMPI_Atomic_memory_barrier()  { __asm__ __volatile__("\t lwsync\n"\
++=======
+ #define tMPI_Atomic_memory_barrier()  { __asm__ __volatile__("\t isync\n"\
++>>>>>>> release-4-5-patches
                                                               : : :"memory" ); }
  
  
diff --cc include/vec.h
index a2b0c099d4a5600b8799da325b467556048d8016,dd916bc149bc1352bf1e05882b819c3b0d5a62ee..558b169c681f12ede7966c59426b9813499415d7
@@@ -828,7 -828,7 +828,11 @@@ static gmx_inline real trace(matrix m
    return (m[XX][XX]+m[YY][YY]+m[ZZ][ZZ]);
  }
  
++<<<<<<< HEAD
 +static gmx_inline real _divide_err(real a,real b,const char *file,int line)
++=======
+ static gmx_inline real _divide(real a,real b,const char *file,int line)
++>>>>>>> release-4-5-patches
  {
      if (fabs(b) <= GMX_REAL_MIN) 
          gmx_fatal(FARGS,"Dividing by zero, file %s, line %d",file,line);
index 97b9dbdcfeeb7ffe2e770756e387c1663b4ff4b9,52a3e6f94ca833176ce429d9cc2ec8f27eab50bc..80e26a30831e61faf2001e96549598e36218d1aa
@@@ -215,14 -215,17 +215,27 @@@ choose_ff(const char *ffsel
                  desc[i] = strdup(ffs[i]);
              }
          }
++<<<<<<< HEAD
 +        /*
++=======
+         /* Order force fields from the same dir alphabetically
+          * and put deprecated force fields at the end.
+          */
++>>>>>>> release-4-5-patches
          for(i=0; (i<nff); i++)
          {
              for(j=i+1; (j<nff); j++)
              {
++<<<<<<< HEAD
 +                if ((desc[i][0] == '[' && desc[j][0] != '[') ||
 +                    ((desc[i][0] == '[' || desc[j][0] != '[') &&
 +                     gmx_strcasecmp(desc[i],desc[j]) > 0))
++=======
+                 if (strcmp(ffs_dir[i],ffs_dir[j]) == 0 &&
+                     ((desc[i][0] == '[' && desc[j][0] != '[') ||
+                      ((desc[i][0] == '[' || desc[j][0] != '[') &&
+                       gmx_strcasecmp(desc[i],desc[j]) > 0)))
++>>>>>>> release-4-5-patches
                  {
                      swap_strings(ffdirs,i,j);
                      swap_strings(ffs   ,i,j);