Add missing visibility exports
authorRoland Schulz <roland@utk.edu>
Fri, 21 Dec 2012 04:26:01 +0000 (23:26 -0500)
committerGerrit Code Review <gerrit@gerrit.gromacs.org>
Sat, 22 Dec 2012 05:44:15 +0000 (06:44 +0100)
For template and for double

Also: fix define symbol for gpu libs
      declare of MPI_Wtime

Change-Id: Iba1a0c6e5ec74739c00b20d43a577813228e3f2d

CMakeLists.txt
include/gmx_arpack.h
include/gmx_lapack.h
include/main.h
include/maths.h
include/nbsearch.h
include/network.h
include/trajana.h
src/gmxlib/gpu_utils/CMakeLists.txt
src/mdlib/fft5d.h
src/mdlib/nbnxn_cuda/CMakeLists.txt

index c2117eb67f50815971e8c6eb493a9dc7fbb8be21..fdf707324329c70b223b1ad612b69c41d988a95a 100644 (file)
@@ -184,6 +184,10 @@ IF( WIN32 AND NOT CYGWIN)
 
   #Workaround for cmake bug 13174. Replace deprecated options.
   IF( CMAKE_C_COMPILER_ID MATCHES "Intel" )
+    if(BUILD_SHARED_LIBS)
+        STRING(REPLACE "/INCREMENTAL:YES" "" CMAKE_SHARED_LINKER_FLAGS ${CMAKE_SHARED_LINKER_FLAGS})
+        SET(CMAKE_SHARED_LINKER_FLAGS ${CMAKE_SHARED_LINKER_FLAGS} CACHE STRING "" FORCE)
+    endif()
     STRING(REPLACE /GZ /RTC1 CMAKE_C_FLAGS_DEBUG ${CMAKE_C_FLAGS_DEBUG})
     SET(CMAKE_C_FLAGS_DEBUG ${CMAKE_C_FLAGS_DEBUG} CACHE STRING "" FORCE)
   ENDIF()
index 612ebf62fa30e379f81f9c0bf1d19a021a01faa2..d60a56e91085002bc0f8c626120fdabee94f6d73 100644 (file)
@@ -106,6 +106,7 @@ extern "C" {
  *                 and 3 that no shifts could be applied. Negative numbers
  *                 correspond to errors in the arguments provided.
  */
+GMX_LIBGMX_EXPORT
 void
 F77_FUNC(dsaupd,DSAUPD)(int *     ido, 
                         const char *    bmat, 
@@ -165,6 +166,7 @@ F77_FUNC(dsaupd,DSAUPD)(int *     ido,
  *  \param lworkl  Provide the same argument as you did to dsaupd()
  *  \param info    Provide the same argument as you did to dsaupd()
  */
+GMX_LIBGMX_EXPORT
 void
 F77_FUNC(dseupd,DSEUPD)(int *     rvec, 
                         const char *    howmny, 
index c21f5b034c669df5531b70eef46490d4356e6074..a7bed9cc2462794d9c8d98bd52b7e0372e1e785f 100644 (file)
@@ -396,6 +396,7 @@ void
 F77_FUNC(dsytrd,DSYTRD)(const char *uplo, int *n, double *  a, int *lda, double *d, 
        double *e, double *tau, double *work, int *lwork, int *info);
 
+GMX_LIBGMX_EXPORT
 void
 F77_FUNC(dsyevr,DSYEVR)(const char *jobz, const char *range, const char *uplo, int *n, 
        double *a, int *lda, double *vl, double *vu, int *
index d6e7afc7ab6d1065a9b7173245079faf61766901..64d64466aaa0239de32221304ca942ec2e8fa641 100644 (file)
@@ -75,7 +75,7 @@ void check_multi_large_int(FILE *log,const gmx_multisim_t *ms,
  * The string name is used to print to the log file and in a fatal error
  * if the val's don't match.
  */
-
+GMX_LIBGMX_EXPORT
 void init_multisystem(t_commrec *cr, int nsim, char **multidirs,
                       int nfile, const t_filenm fnm[], gmx_bool bParFn);
 /* Splits the communication into nsim separate simulations
index 2895026cca6c894c0c518c9de1255745e5cf6c04..daa2ec58df3b01a9e49314aef460ce5435f00829 100644 (file)
@@ -121,6 +121,7 @@ real    sign(real x,real y);
 real    cuberoot (real a);
 GMX_LIBGMX_EXPORT
 double  gmx_erfd(double x);
+GMX_LIBGMX_EXPORT
 double  gmx_erfcd(double x);
 GMX_LIBGMX_EXPORT
 float   gmx_erff(float x);
index bff7a88a5285992cf34e6335fe3701ddad8b3507..6d51d00894368fb0fd60d17d0401e5c17daa0a79 100644 (file)
@@ -62,6 +62,7 @@ struct gmx_ana_pos_t;
 typedef struct gmx_ana_nbsearch_t gmx_ana_nbsearch_t;
 
 /** Create a new neighborhood search data structure. */
+GMX_LIBGMX_EXPORT
 int
 gmx_ana_nbsearch_create(gmx_ana_nbsearch_t **d, real cutoff, int maxn);
 /** Free memory allocated for neighborhood search. */
@@ -72,6 +73,7 @@ gmx_ana_nbsearch_free(gmx_ana_nbsearch_t *d);
 int
 gmx_ana_nbsearch_init(gmx_ana_nbsearch_t *d, t_pbc *pbc, int n, rvec x[]);
 /** Initializes neighborhood search for a frame using \c gmx_ana_pos_t.  */
+GMX_LIBGMX_EXPORT
 int
 gmx_ana_nbsearch_pos_init(gmx_ana_nbsearch_t *d, t_pbc *pbc,
                           struct gmx_ana_pos_t *p);
@@ -89,6 +91,7 @@ gmx_ana_nbsearch_pos_is_within(gmx_ana_nbsearch_t *d,
 real
 gmx_ana_nbsearch_mindist(gmx_ana_nbsearch_t *d, rvec x);
 /** Calculates the minimun distance from the reference points. */
+GMX_LIBGMX_EXPORT
 real
 gmx_ana_nbsearch_pos_mindist(gmx_ana_nbsearch_t *d,
                              struct gmx_ana_pos_t *p, int i);
index 35ce9bc5286506d0940d3400ddb8b854dd82e86f..680a88136f9435fa46f746334af55339514e572f 100644 (file)
@@ -129,6 +129,7 @@ GMX_LIBGMX_EXPORT
 void gmx_sumf_sim(int nr,float r[],const gmx_multisim_t *ms);
 /* Calculate the sum over the simulations of an array of floats */
 
+GMX_LIBGMX_EXPORT
 void gmx_sumd_sim(int nr,double r[],const gmx_multisim_t *ms);
 /* Calculate the sum over the simulations of an array of doubles */
 
index 42bff59464257bd6417020f890990b54abc78470..d4b32015c954e0e741c71b7637c51d51c89a416a 100644 (file)
@@ -196,6 +196,7 @@ gmx_ana_traj_free(gmx_ana_traj_t *d);
 int
 gmx_ana_add_flags(gmx_ana_traj_t *d, unsigned long flags);
 /** Sets the number of reference groups required. */
+GMX_LIBGMX_EXPORT
 int
 gmx_ana_set_nrefgrps(gmx_ana_traj_t *d, int nrefgrps);
 /** Sets the number of analysis groups required. */
@@ -250,6 +251,7 @@ GMX_LIBGMX_EXPORT
 int
 gmx_ana_get_nanagrps(gmx_ana_traj_t *d, int *nanagrps);
 /** Gets the selection object for a reference selection. */
+GMX_LIBGMX_EXPORT
 int
 gmx_ana_get_refsel(gmx_ana_traj_t *d, int i, gmx_ana_selection_t **sel);
 /** Gets the selection object for a reference selection. */
index 1ad107dfdbe9c174926f5bc66ed9325b8999b468..cc749674305e33aa0a436bb2b08a27cf967025d1 100644 (file)
@@ -55,5 +55,8 @@ CUDA_ADD_LIBRARY(gpu_utils STATIC ${GPU_UTILS_SOURCES}
                  OPTIONS ${_os_def}
                  RELWITHDEBINFO -g
                  DEBUG -g -D_DEBUG_=1 )
+#Because this is a static library linked into the (potential) shared library
+#it should have the export of the shared library.
+SET_TARGET_PROPERTIES(gpu_utils PROPERTIES DEFINE_SYMBOL "gmx_EXPORTS" )
 
 CUDA_BUILD_CLEAN_TARGET()
index 99ceba34e4c37d193043d46b77af70072e2e9a6b..fd25a5b1c0e65048553c4dd584f2e84868fc96f8 100644 (file)
@@ -53,7 +53,7 @@ FILE* debug;
 #include "gmxcomplex.h"
 #include "gmx_fft.h"
 
-#ifndef GMX_LIB_MPI
+#ifndef GMX_MPI
 double MPI_Wtime();
 #endif
 
index ddf2719dab070a9fe6a1c4be78118195fc6664e6..2b6398c1e4ab80d8a0e5e4242a98226afe885dd7 100644 (file)
@@ -39,4 +39,7 @@ if(GMX_GPU)
             OPTIONS
             RELWITHDEBINFO -g
             DEBUG -g -D_DEBUG_=1)
+    #Because this is a static library linked into the (potential) shared library
+    #it should have the export of the shared library.
+    SET_TARGET_PROPERTIES(nbnxn_cuda PROPERTIES DEFINE_SYMBOL "md_EXPORTS" )
 endif()