forked from jminock/Generator-v3_00_04_ub3
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Dockerfile
155 lines (145 loc) · 4.87 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
### Created by James Minock ([email protected])
### GENIE v3.0.4 uboone patch 3 with Reweight package
### Based on ToolAnalysis Dockerfile created by Dr. Benjamin Richards
### Download base image from cern repo on docker hub
FROM quay.io/centos/centos:stream8
### Run the following commands as super user (root):
USER root
### GCC environment
RUN dnf config-manager --set-enabled extras,powertools \
&& yum install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm \
&& yum install -y https://repo.opensciencegrid.org/osg/3.6/osg-3.6-el8-release-latest.rpm \
&& yum install -y \
gcc \
gcc-c++ \
gcc-gfortran \
python38 \
python38-devel \
wget \
tar \
cmake \
binutils \
libX11-devel \
libXpm-devel \
libXft-devel \
libXext-devel \
libxml2-devel \
libpng \
libpng-devel \
libjpeg-devel \
graphviz-devel \
mesa-libGL-devel \
mesa-libGLU-devel \
make \
file \
git \
patch \
bzip2-devel \
cvs \
automake \
svn \
libtool \
libxml2 \
which \
gsl-devel \
emacs \
curl \
curl-devel \
osg-ca-certs \
osg-wn-client \
openssl-devel \
fftw3 \
fftw3-devel \
libnsl2-devel \
python3-devel \
python2 \
python2-devel \
bzip2 \
&& yum clean all \
&& rm -rf /var/cache/yum \
&& mkdir Genie \
&& cd Genie \
&& wget https://github.com/ANNIEsoft/GENIE-v3/archive/refs/heads/master.zip \
&& unzip master.zip \
&& rm -rf master.zip
### fsplit
RUN source /Genie/GENIE-v3-master/annie/Setup_GENIE.sh \
&& cd Genie \
&& mkdir fsplit && cd fsplit \
&& wget https://gist.githubusercontent.com/marc1uk/c0e32d955dd1c06ef69d80ce643018ad/raw/10e592d42737ecc7dca677e774ae66dcb5a3859d/fsplit.c \
&& gcc fsplit.c -o fsplit
### log4cpp
RUN source /Genie/GENIE-v3-master/annie/Setup_GENIE.sh \
&& cd Genie \
&& cvs -d :pserver:[email protected]:/cvsroot/log4cpp -z3 co log4cpp \
&& cd log4cpp/ \
&& mkdir install \
&& ./autogen.sh \
&& ./configure --prefix=/Genie/log4cpp/install \
&& make \
&& make install
### Pythia6
### dummies must be removed for LHAPDF which is needed for Reweight package
RUN source /Genie/GENIE-v3-master/annie/Setup_GENIE.sh \
&& cd Genie \
&& git clone https://github.com/GENIE-MC-Community/Pythia6Support.git \
&& cd Pythia6Support \
&& ./build_pythia6.sh --dummies=remove
### ROOT
RUN source /Genie/GENIE-v3-master/annie/Setup_GENIE.sh \
&& cd Genie \
&& wget https://root.cern.ch/download/root_v6.24.06.source.tar.gz \
&& tar zxf root_v6.24.06.source.tar.gz \
&& rm -rf root_v6.24.06.source.tar.gz \
&& cd root-6.24.06 \
&& mkdir install \
&& cd install \
&& cmake ../ -DCMAKE_CXX_STANDARD=14 \
-Dgdml=ON -Dxml=ON -Dmt=ON -Dmathmore=ON -Dx11=ON \
-Dimt=ON -Dtmva=ON -DCMAKE_BUILD_TYPE=RelWithDebInfo -Dpythia6=ON -Dfftw3=ON \
&& make \
&& make install \
&& cd ../ \
&& /bin/bash -O extglob -c 'rm -rf !(install)'
### LHAPDF
### Necessary for Reweight package
RUN source /Genie/GENIE-v3-master/annie/Setup_GENIE.sh \
&& cd Genie \
&& wget http://lhapdf.hepforge.org/downloads/LHAPDF-6.3.0.tar.gz \
&& tar zxf LHAPDF-6.3.0.tar.gz \
&& rm -rf LHAPDF-6.3.0.tar.gz \
&& cd LHAPDF-6.3.0 \
&& mkdir install \
&& ./configure --prefix=/Genie/LHAPDF-6.3.0/install \
&& make \
&& make install \
&& cd install/share/LHAPDF \
&& wget http://lhapdf.hepforge.org/downloads/pdfsets/5.9.1/CT10.LHgrid \
&& wget http://lhapdf.hepforge.org/downloads/pdfsets/5.9.1/cteq61.LHpdf \
&& wget http://lhapdf.hepforge.org/downloads/pdfsets/5.9.1/cteq61.LHgrid \
&& wget http://lhapdf.hepforge.org/downloads/pdfsets/5.9.1/GRV98lo.LHgrid \
&& wget http://lhapdf.hepforge.org/downloads/pdfsets/5.9.1/GRV98lo_patched.LHgrid \
&& wget http://lhapdf.hepforge.org/downloads/pdfsets/5.9.1/GRV98nlo.LHgrid \
&& wget http://lhapdf.hepforge.org/downloads/pdfsets/5.9.1/GRVG0.LHgrid \
&& wget http://lhapdf.hepforge.org/downloads/pdfsets/5.9.1/GRVG1.LHgrid \
&& wget http://lhapdf.hepforge.org/downloads/pdfsets/5.9.1/GRVPI0.LHgrid \
&& wget http://lhapdf.hepforge.org/downloads/pdfsets/5.9.1/GRVPI1.LHgrid \
&& cd /Genie/LHAPDF-6.3.0 \
&& /bin/bash -O extglob -c 'rm -rf !(install)'
### GENIE
### env variables need to be set before configuration/installation
RUN source /Genie/GENIE-v3-master/annie/Setup_GENIE.sh \
&& cd Genie/GENIE-v3-master/ \
&& mkdir install \
&& ./configure --prefix=/Genie/GENIE-v3-master/install/ \
--with-pythia6-lib=/Genie/Pythia6Support/v6_424/lib/ \
--with-log4cpp-inc=/Genie/log4cpp/install/include/ \
--with-log4cpp-lib=/Genie/log4cpp/install/lib/ \
--enable-fnal --enable-lhapdf6 --enable-rwght \
&& make -j4 \
&& make install \
&& cd src/ \
&& rm -rf Framework/ \
&& rm -rf Physics/ \
&& rm -rf Tools/
CMD ["/bin/bash"]