namd-2.9-gentoo.patch 5.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152
  1. diff -Naur NAMD_2.9_Source.original/Make.charm NAMD_2.9_Source/Make.charm
  2. --- NAMD_2.9_Source.original/Make.charm 2012-02-29 19:12:11.000000000 -0700
  3. +++ NAMD_2.9_Source/Make.charm 2013-09-13 21:23:26.000000000 -0600
  4. @@ -2,5 +2,5 @@
  5. # The config script will override this setting if there is a directory
  6. # called charm-6.4.0 or charm in the NAMD base directory.
  7. -CHARMBASE = /Projects/namd2/charm-6.4.0
  8. +CHARMBASE = /usr/include/charm-6.4.0
  9. diff -Naur NAMD_2.9_Source.original/Makefile NAMD_2.9_Source/Makefile
  10. --- NAMD_2.9_Source.original/Makefile 2012-04-27 09:53:24.000000000 -0600
  11. +++ NAMD_2.9_Source/Makefile 2013-09-13 21:30:15.000000000 -0600
  12. @@ -344,10 +344,10 @@
  13. $(DSTDIR)/stringhash.o
  14. # definitions for Charm routines
  15. -CHARMC = $(CHARM)/bin/charmc
  16. -CHARMXI = $(CHARM)/bin/charmc
  17. -CHARMINC = $(CHARM)/include $(COPTD)CMK_OPTIMIZE=1
  18. -CHARMLIB = $(CHARM)/lib
  19. +CHARMC = /usr/bin/charmc
  20. +CHARMXI = /usr/bin/charmc
  21. +CHARMINC = /usr/include/gentoo-charm $(COPTD)CMK_OPTIMIZE=1
  22. +CHARMLIB = /usr/gentoo-libdir
  23. CHARM_MODULES = -module NeighborLB -module HybridLB -module RefineLB -module GreedyLB
  24. #CHARM_MODULES = -module msa -module NeighborLB -module HybridLB -module RefineLB -module GreedyLB
  25. #MSA = -DCHARM_HAS_MSA
  26. @@ -370,7 +370,7 @@
  27. # Add new executables here.
  28. -BINARIES = namd2 psfgen sortreplicas charmrun flipdcd flipbinpdb
  29. +BINARIES = namd2 psfgen sortreplicas flipdcd flipbinpdb
  30. # This should be rebuilt at every compile, but not on Win32.
  31. BUILDINFO = $(DSTDIR)/buildinfo
  32. @@ -386,7 +386,7 @@
  33. namd2: $(MKINCDIR) $(MKDSTDIR) $(OBJS) $(LIBS)
  34. $(MAKEBUILDINFO)
  35. - $(CHARMC) -verbose -ld++-option \
  36. + $(CHARMC) $(LDFLAGS) -verbose -ld++-option \
  37. "$(COPTI)$(CHARMINC) $(COPTI)$(INCDIR) $(COPTI)$(SRCDIR) $(CXXOPTS)" \
  38. "$(CHARM_MODULES)" -language charm++ \
  39. $(BUILDINFO).o \
  40. @@ -402,16 +402,9 @@
  41. $(EXTRALINKLIBS) \
  42. -lm -o namd2
  43. -charmrun: $(CHARM)/bin/charmrun # XXX
  44. - $(COPY) $(CHARM)/bin/charmrun $@
  45. -
  46. $(LIBCUDARTSO):
  47. $(COPY) $(CUDASODIR)/$(LIBCUDARTSO) $@;
  48. -WINDOWSBINARIES = namd2.exe psfgen.exe sortreplicas.exe
  49. -# WINDOWSBINARIES = namd2.exe psfgen.exe charmd.exe charmd_faceless.exe charmrun.exe
  50. -windowsbinaries: $(WINDOWSBINARIES)
  51. -
  52. namd2.exe: $(MKINCDIR) $(MKDSTDIR) $(OBJS) $(LIBS) $(TCLDLL)
  53. $(MAKEBUILDINFO)
  54. $(CHARMC) -verbose \
  55. @@ -434,11 +427,8 @@
  56. charmd_faceless.exe:
  57. $(COPY) $(CHARM)/bin/charmd_faceless.exe charmd_faceless.exe
  58. -charmrun.exe:
  59. - $(COPY) $(CHARM)/bin/charmrun.exe charmrun.exe
  60. -
  61. psfgen: $(MKDSTDIR) $(SBOBJS) $(PLUGINOBJS)
  62. - $(CC) $(SBCFLAGS) -o psfgen $(SBOBJS) $(PLUGINOBJS) $(TCLLIB) $(TCLAPPLIB) -lm
  63. + $(CC) $(SBCFLAGS) $(LDFLAGS) -o psfgen $(SBOBJS) $(PLUGINOBJS) $(TCLLIB) $(TCLAPPLIB) -lm
  64. psfgen.exe: $(MKDSTDIR) $(SBOBJS) $(PLUGINOBJS) $(TCLDLL)
  65. $(CC) $(SBCFLAGS) -o psfgen $(SBOBJS) $(PLUGINOBJS) $(TCLLIB) $(TCLAPPLIB) -lm
  66. @@ -456,7 +446,7 @@
  67. $(CC) $(CFLAGS) -o diffbinpdb $(SRCDIR)/diffbinpdb.c -lm
  68. flipdcd: $(SRCDIR)/flipdcd.c
  69. - $(CC) $(CFLAGS) -o $@ $(SRCDIR)/flipdcd.c || \
  70. + $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(SRCDIR)/flipdcd.c || \
  71. echo "#!/bin/sh\necho unavailable on this platform" > $@; \
  72. chmod +x $@
  73. @@ -466,7 +456,7 @@
  74. chmod +x $@
  75. fixdcd: $(SRCDIR)/fixdcd.c
  76. - $(CC) $(CFLAGS) -o fixdcd $(SRCDIR)/fixdcd.c
  77. + $(CC) $(CFLAGS) $(LDFLAGS) -o fixdcd $(SRCDIR)/fixdcd.c
  78. dumpdcd: $(SRCDIR)/dumpdcd.c
  79. $(CC) $(CFLAGS) -o dumpdcd $(SRCDIR)/dumpdcd.c
  80. @@ -665,9 +655,7 @@
  81. DOC_FILES = README.txt announce.txt license.txt notes.txt
  82. -RELEASE_FILES = $(LIBCUDARTSO) flipdcd flipbinpdb sortreplicas psfgen charmrun namd2
  83. -
  84. -WINDOWS_RELEASE_FILES = $(LIBCUDARTSO) $(WINDOWSBINARIES) $(TCLDLL)
  85. +RELEASE_FILES = $(LIBCUDARTSO) flipdcd flipbinpdb sortreplicas psfgen namd2
  86. release: all
  87. $(ECHO) Creating release $(RELEASE_DIR_NAME)
  88. @@ -678,17 +666,9 @@
  89. for f in `find $(RELEASE_DIR_NAME)/lib -name CVS`; do \
  90. /bin/rm -rf $$f; \
  91. done
  92. - if [ -r $(CHARM)/bin/charmd ]; then \
  93. - $(COPY) $(CHARM)/bin/charmd $(RELEASE_DIR_NAME); \
  94. - fi
  95. - if [ -r $(CHARM)/bin/charmd_faceless ]; then \
  96. - $(COPY) $(CHARM)/bin/charmd_faceless $(RELEASE_DIR_NAME); \
  97. - fi
  98. chmod -R a+rX $(RELEASE_DIR_NAME)
  99. tar cf $(RELEASE_DIR_NAME).tar $(RELEASE_DIR_NAME)
  100. gzip $(RELEASE_DIR_NAME).tar
  101. - echo $(CHARM)
  102. - ls -l $(CHARM)/lib
  103. -for f in $(RELEASE_FILES); do echo $$f; $(LDD) $(RELEASE_DIR_NAME)/$$f; done
  104. winrelease: winall
  105. diff -Naur NAMD_2.9_Source.original/arch/Linux-x86_64.fftw NAMD_2.9_Source/arch/Linux-x86_64.fftw
  106. --- NAMD_2.9_Source.original/arch/Linux-x86_64.fftw 2009-02-21 21:16:04.000000000 -0700
  107. +++ NAMD_2.9_Source/arch/Linux-x86_64.fftw 2013-09-13 20:55:02.000000000 -0600
  108. @@ -1,7 +1,7 @@
  109. -FFTDIR=/Projects/namd2/fftw/linux-x86_64
  110. +FFTDIR=/usr
  111. FFTINCL=-I$(FFTDIR)/include
  112. -FFTLIB=-L$(FFTDIR)/lib -lsrfftw -lsfftw
  113. +FFTLIB=-L$(FFTDIR)/gentoo-libdir -lsrfftw -lsfftw
  114. FFTFLAGS=-DNAMD_FFTW
  115. FFT=$(FFTINCL) $(FFTFLAGS)
  116. diff -Naur NAMD_2.9_Source.original/arch/Linux-x86_64.tcl NAMD_2.9_Source/arch/Linux-x86_64.tcl
  117. --- NAMD_2.9_Source.original/arch/Linux-x86_64.tcl 2011-06-17 14:38:43.000000000 -0600
  118. +++ NAMD_2.9_Source/arch/Linux-x86_64.tcl 2013-09-13 20:56:30.000000000 -0600
  119. @@ -1,9 +1,9 @@
  120. #TCLDIR=/Projects/namd2/tcl/tcl8.5.9-linux-x86_64
  121. -TCLDIR=/Projects/namd2/tcl/tcl8.5.9-linux-x86_64-threaded
  122. +TCLDIR=/usr
  123. TCLINCL=-I$(TCLDIR)/include
  124. #TCLLIB=-L$(TCLDIR)/lib -ltcl8.5 -ldl
  125. -TCLLIB=-L$(TCLDIR)/lib -ltcl8.5 -ldl -lpthread
  126. +TCLLIB=-L$(TCLDIR)/gentoo-libdir -ltcl8.5 -ldl -lpthread
  127. TCLFLAGS=-DNAMD_TCL
  128. TCL=$(TCLINCL) $(TCLFLAGS)