7669d308ac453cbc8c01a8644c2d26b8e0adab47
[jalview.git] / doc / building.html
1 <!DOCTYPE html>
2 <html xmlns="http://www.w3.org/1999/xhtml" lang="" xml:lang="">
3 <head>
4   <meta charset="utf-8" />
5   <meta name="generator" content="pandoc" />
6   <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
7   <title>"Building Jalview from Source"</title>
8   <style>
9       code{white-space: pre-wrap;}
10       span.smallcaps{font-variant: small-caps;}
11       span.underline{text-decoration: underline;}
12       div.column{display: inline-block; vertical-align: top; width: 50%;}
13   </style>
14   <style>
15 a.sourceLine { display: inline-block; line-height: 1.25; }
16 a.sourceLine { pointer-events: none; color: inherit; text-decoration: inherit; }
17 a.sourceLine:empty { height: 1.2em; }
18 .sourceCode { overflow: visible; }
19 code.sourceCode { white-space: pre; position: relative; }
20 div.sourceCode { margin: 1em 0; }
21 pre.sourceCode { margin: 0; }
22 @media screen {
23 div.sourceCode { overflow: auto; }
24 }
25 @media print {
26 code.sourceCode { white-space: pre-wrap; }
27 a.sourceLine { text-indent: -1em; padding-left: 1em; }
28 }
29 pre.numberSource a.sourceLine
30   { position: relative; left: -4em; }
31 pre.numberSource a.sourceLine::before
32   { content: attr(title);
33     position: relative; left: -1em; text-align: right; vertical-align: baseline;
34     border: none; pointer-events: all; display: inline-block;
35     -webkit-touch-callout: none; -webkit-user-select: none;
36     -khtml-user-select: none; -moz-user-select: none;
37     -ms-user-select: none; user-select: none;
38     padding: 0 4px; width: 4em;
39     color: #aaaaaa;
40   }
41 pre.numberSource { margin-left: 3em; border-left: 1px solid #aaaaaa;  padding-left: 4px; }
42 div.sourceCode
43   {  }
44 @media screen {
45 a.sourceLine::before { text-decoration: underline; }
46 }
47 code span.al { color: #ff0000; font-weight: bold; } /* Alert */
48 code span.an { color: #60a0b0; font-weight: bold; font-style: italic; } /* Annotation */
49 code span.at { color: #7d9029; } /* Attribute */
50 code span.bn { color: #40a070; } /* BaseN */
51 code span.bu { } /* BuiltIn */
52 code span.cf { color: #007020; font-weight: bold; } /* ControlFlow */
53 code span.ch { color: #4070a0; } /* Char */
54 code span.cn { color: #880000; } /* Constant */
55 code span.co { color: #60a0b0; font-style: italic; } /* Comment */
56 code span.cv { color: #60a0b0; font-weight: bold; font-style: italic; } /* CommentVar */
57 code span.do { color: #ba2121; font-style: italic; } /* Documentation */
58 code span.dt { color: #902000; } /* DataType */
59 code span.dv { color: #40a070; } /* DecVal */
60 code span.er { color: #ff0000; font-weight: bold; } /* Error */
61 code span.ex { } /* Extension */
62 code span.fl { color: #40a070; } /* Float */
63 code span.fu { color: #06287e; } /* Function */
64 code span.im { } /* Import */
65 code span.in { color: #60a0b0; font-weight: bold; font-style: italic; } /* Information */
66 code span.kw { color: #007020; font-weight: bold; } /* Keyword */
67 code span.op { color: #666666; } /* Operator */
68 code span.ot { color: #007020; } /* Other */
69 code span.pp { color: #bc7a00; } /* Preprocessor */
70 code span.sc { color: #4070a0; } /* SpecialChar */
71 code span.ss { color: #bb6688; } /* SpecialString */
72 code span.st { color: #4070a0; } /* String */
73 code span.va { color: #19177c; } /* Variable */
74 code span.vs { color: #4070a0; } /* VerbatimString */
75 code span.wa { color: #60a0b0; font-weight: bold; font-style: italic; } /* Warning */
76   </style>
77   <!--[if lt IE 9]>
78     <script src="//cdnjs.cloudflare.com/ajax/libs/html5shiv/3.7.3/html5shiv-printshiv.min.js"></script>
79   <![endif]-->
80   <style>
81   @font-face {
82     font-family: octicons-link;
83     src: url(data:font/woff;charset=utf-8;base64,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) format('woff');
84   }
85   
86   body {
87     -webkit-text-size-adjust: 100%;
88     text-size-adjust: 100%;
89     color: #333;
90     font-family: "Helvetica Neue", Helvetica, "Segoe UI", Arial, freesans, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
91     font-size: 16px;
92     line-height: 1.6;
93     word-wrap: break-word;
94     width: 728px;
95     max-width: 99%;
96     box-sizing: border-box;
97     padding: 30px 30px 8rem 30px;
98     margin-left: auto;
99     margin-right: auto;
100   }
101   
102   body a {
103     background-color: transparent;
104   }
105   
106   body a:active,
107   body a:hover {
108     outline: 0;
109   }
110   
111   body strong {
112     font-weight: bold;
113   }
114   
115   body h1 {
116     font-size: 2em;
117     margin: 0.67em 0;
118   }
119   
120   body img {
121     border: 0;
122   }
123   
124   body hr {
125     box-sizing: content-box;
126     height: 0;
127   }
128   
129   body pre {
130     overflow: auto;
131   }
132   
133   body code,
134   body kbd,
135   body pre {
136     font-family: monospace, monospace;
137     font-size: 1em;
138   }
139   
140   body input {
141     color: inherit;
142     font: inherit;
143     margin: 0;
144   }
145   
146   body html input[disabled] {
147     cursor: default;
148   }
149   
150   body input {
151     line-height: normal;
152   }
153   
154   body input[type="checkbox"] {
155     box-sizing: border-box;
156     padding: 0;
157   }
158   
159   body table {
160     border-collapse: collapse;
161     border-spacing: 0;
162   }
163   
164   body td,
165   body th {
166     padding: 0;
167   }
168   
169   body * {
170     box-sizing: border-box;
171   }
172   
173   body input {
174     font: 13px / 1.4 Helvetica, arial, nimbussansl, liberationsans, freesans, clean, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
175   }
176   
177   body a {
178     color: #4078c0;
179     text-decoration: none;
180   }
181   
182   body a:hover,
183   body a:active {
184     text-decoration: underline;
185   }
186   
187   body hr {
188     height: 0;
189     margin: 15px 0;
190     overflow: hidden;
191     background: transparent;
192     border: 0;
193     border-bottom: 1px solid #ddd;
194   }
195   
196   body hr:before {
197     display: table;
198     content: "";
199   }
200   
201   body hr:after {
202     display: table;
203     clear: both;
204     content: "";
205   }
206   
207   body h1,
208   body h2,
209   body h3,
210   body h4,
211   body h5,
212   body h6 {
213     margin-top: 15px;
214     margin-bottom: 15px;
215     line-height: 1.1;
216   }
217   
218   body h1 {
219     font-size: 30px;
220   }
221   
222   body h2 {
223     font-size: 21px;
224   }
225   
226   body h3 {
227     font-size: 16px;
228   }
229   
230   body h4 {
231     font-size: 14px;
232   }
233   
234   body h5 {
235     font-size: 12px;
236   }
237   
238   body h6 {
239     font-size: 11px;
240   }
241   
242   body blockquote {
243     margin: 0;
244   }
245   
246   body ul,
247   body ol {
248     padding: 0;
249     margin-top: 0;
250     margin-bottom: 0;
251   }
252   
253   body ol ol,
254   body ul ol {
255     list-style-type: lower-roman;
256   }
257   
258   body ul ul ol,
259   body ul ol ol,
260   body ol ul ol,
261   body ol ol ol {
262     list-style-type: lower-alpha;
263   }
264   
265   body dd {
266     margin-left: 0;
267   }
268   
269   body code {
270     font-family: Consolas, "Liberation Mono", Menlo, Courier, monospace;
271     font-size: 12px;
272   }
273   
274   body pre {
275     margin-top: 0;
276     margin-bottom: 0;
277     font: 12px Consolas, "Liberation Mono", Menlo, Courier, monospace;
278   }
279   
280   body .select::-ms-expand {
281     opacity: 0;
282   }
283   
284   body .octicon {
285     font: normal normal normal 16px/1 octicons-link;
286     display: inline-block;
287     text-decoration: none;
288     text-rendering: auto;
289     -webkit-font-smoothing: antialiased;
290     -moz-osx-font-smoothing: grayscale;
291     -webkit-user-select: none;
292     -moz-user-select: none;
293     -ms-user-select: none;
294     user-select: none;
295   }
296   
297   body .octicon-link:before {
298     content: '\f05c';
299   }
300   
301   body:before {
302     display: table;
303     content: "";
304   }
305   
306   body:after {
307     display: table;
308     clear: both;
309     content: "";
310   }
311   
312   body>*:first-child {
313     margin-top: 0 !important;
314   }
315   
316   body>*:last-child {
317     margin-bottom: 0 !important;
318   }
319   
320   body a:not([href]) {
321     color: inherit;
322     text-decoration: none;
323   }
324   
325   body .anchor {
326     display: inline-block;
327     padding-right: 2px;
328     margin-left: -18px;
329   }
330   
331   body .anchor:focus {
332     outline: none;
333   }
334   
335   body h1,
336   body h2,
337   body h3,
338   body h4,
339   body h5,
340   body h6 {
341     margin-top: 1em;
342     margin-bottom: 16px;
343     font-weight: bold;
344     line-height: 1.4;
345   }
346   
347   body h1 .octicon-link,
348   body h2 .octicon-link,
349   body h3 .octicon-link,
350   body h4 .octicon-link,
351   body h5 .octicon-link,
352   body h6 .octicon-link {
353     color: #000;
354     vertical-align: middle;
355     visibility: hidden;
356   }
357   
358   body h1:hover .anchor,
359   body h2:hover .anchor,
360   body h3:hover .anchor,
361   body h4:hover .anchor,
362   body h5:hover .anchor,
363   body h6:hover .anchor {
364     text-decoration: none;
365   }
366   
367   body h1:hover .anchor .octicon-link,
368   body h2:hover .anchor .octicon-link,
369   body h3:hover .anchor .octicon-link,
370   body h4:hover .anchor .octicon-link,
371   body h5:hover .anchor .octicon-link,
372   body h6:hover .anchor .octicon-link {
373     visibility: visible;
374   }
375   
376   body h1 {
377     padding-bottom: 0.3em;
378     font-size: 1.75em;
379     line-height: 1.2;
380   }
381   
382   body h1 .anchor {
383     line-height: 1;
384   }
385   
386   body h2 {
387     padding-bottom: 0.3em;
388     font-size: 1.5em;
389     line-height: 1.225;
390   }
391   
392   body h2 .anchor {
393     line-height: 1;
394   }
395   
396   body h3 {
397     font-size: 1.25em;
398     line-height: 1.43;
399   }
400   
401   body h3 .anchor {
402     line-height: 1.2;
403   }
404   
405   body h4 {
406     font-size: 1em;
407   }
408   
409   body h4 .anchor {
410     line-height: 1.2;
411   }
412   
413   body h5 {
414     font-size: 1em;
415   }
416   
417   body h5 .anchor {
418     line-height: 1.1;
419   }
420   
421   body h6 {
422     font-size: 1em;
423     color: #777;
424   }
425   
426   body h6 .anchor {
427     line-height: 1.1;
428   }
429   
430   body p,
431   body blockquote,
432   body ul,
433   body ol,
434   body dl,
435   body table,
436   body pre {
437     margin-top: 0;
438     margin-bottom: 16px;
439   }
440   
441   body hr {
442     height: 4px;
443     padding: 0;
444     margin: 16px 0;
445     background-color: #e7e7e7;
446     border: 0 none;
447   }
448   
449   body ul,
450   body ol {
451     padding-left: 2em;
452   }
453   
454   body ul ul,
455   body ul ol,
456   body ol ol,
457   body ol ul {
458     margin-top: 0;
459     margin-bottom: 0;
460   }
461   
462   body li>p {
463     margin-top: 16px;
464   }
465   
466   body dl {
467     padding: 0;
468   }
469   
470   body dl dt {
471     padding: 0;
472     margin-top: 16px;
473     font-size: 1em;
474     font-style: italic;
475     font-weight: bold;
476   }
477   
478   body dl dd {
479     padding: 0 16px;
480     margin-bottom: 16px;
481   }
482   
483   body blockquote {
484     padding: 0 15px;
485     color: #777;
486     border-left: 4px solid #ddd;
487   }
488   
489   body blockquote>:first-child {
490     margin-top: 0;
491   }
492   
493   body blockquote>:last-child {
494     margin-bottom: 0;
495   }
496   
497   body table {
498     display: block;
499     width: 100%;
500     overflow: auto;
501     word-break: normal;
502     word-break: keep-all;
503   }
504   
505   body table th {
506     font-weight: bold;
507   }
508   
509   body table th,
510   body table td {
511     padding: 6px 13px;
512     border: 1px solid #ddd;
513   }
514   
515   body table tr {
516     background-color: #fff;
517     border-top: 1px solid #ccc;
518   }
519   
520   body table tr:nth-child(2n) {
521     background-color: #f8f8f8;
522   }
523   
524   body img {
525     max-width: 100%;
526     box-sizing: content-box;
527     background-color: #fff;
528   }
529   
530   body code {
531     padding: 0;
532     padding-top: 0;
533     padding-bottom: 0;
534     margin: 0;
535     font-size: 85%;
536     background-color: rgba(0,0,0,0.04);
537     border-radius: 3px;
538   }
539   
540   body code:before,
541   body code:after {
542     letter-spacing: -0.2em;
543     content: "\00a0";
544   }
545   
546   body pre>code {
547     padding: 0;
548     margin: 0;
549     font-size: 100%;
550     word-break: normal;
551     white-space: pre;
552     background: transparent;
553     border: 0;
554   }
555   
556   body .highlight {
557     margin-bottom: 16px;
558   }
559   
560   body .highlight pre,
561   body pre {
562     padding: 16px;
563     overflow: auto;
564     font-size: 85%;
565     line-height: 1.45;
566     background-color: #f7f7f7;
567     border-radius: 3px;
568   }
569   
570   body .highlight pre {
571     margin-bottom: 0;
572     word-break: normal;
573   }
574   
575   body pre {
576     word-wrap: normal;
577   }
578   
579   body pre code {
580     display: inline;
581     max-width: initial;
582     padding: 0;
583     margin: 0;
584     overflow: initial;
585     line-height: inherit;
586     word-wrap: normal;
587     background-color: transparent;
588     border: 0;
589   }
590   
591   body pre code:before,
592   body pre code:after {
593     content: normal;
594   }
595   
596   body kbd {
597     display: inline-block;
598     padding: 3px 5px;
599     font-size: 11px;
600     line-height: 10px;
601     color: #555;
602     vertical-align: middle;
603     background-color: #fcfcfc;
604     border: solid 1px #ccc;
605     border-bottom-color: #bbb;
606     border-radius: 3px;
607     box-shadow: inset 0 -1px 0 #bbb;
608   }
609   
610   body .pl-c {
611     color: #969896;
612   }
613   
614   body .pl-c1,
615   body .pl-s .pl-v {
616     color: #0086b3;
617   }
618   
619   body .pl-e,
620   body .pl-en {
621     color: #795da3;
622   }
623   
624   body .pl-s .pl-s1,
625   body .pl-smi {
626     color: #333;
627   }
628   
629   body .pl-ent {
630     color: #63a35c;
631   }
632   
633   body .pl-k {
634     color: #a71d5d;
635   }
636   
637   body .pl-pds,
638   body .pl-s,
639   body .pl-s .pl-pse .pl-s1,
640   body .pl-sr,
641   body .pl-sr .pl-cce,
642   body .pl-sr .pl-sra,
643   body .pl-sr .pl-sre {
644     color: #183691;
645   }
646   
647   body .pl-v {
648     color: #ed6a43;
649   }
650   
651   body .pl-id {
652     color: #b52a1d;
653   }
654   
655   body .pl-ii {
656     background-color: #b52a1d;
657     color: #f8f8f8;
658   }
659   
660   body .pl-sr .pl-cce {
661     color: #63a35c;
662     font-weight: bold;
663   }
664   
665   body .pl-ml {
666     color: #693a17;
667   }
668   
669   body .pl-mh,
670   body .pl-mh .pl-en,
671   body .pl-ms {
672     color: #1d3e81;
673     font-weight: bold;
674   }
675   
676   body .pl-mq {
677     color: #008080;
678   }
679   
680   body .pl-mi {
681     color: #333;
682     font-style: italic;
683   }
684   
685   body .pl-mb {
686     color: #333;
687     font-weight: bold;
688   }
689   
690   body .pl-md {
691     background-color: #ffecec;
692     color: #bd2c00;
693   }
694   
695   body .pl-mi1 {
696     background-color: #eaffea;
697     color: #55a532;
698   }
699   
700   body .pl-mdr {
701     color: #795da3;
702     font-weight: bold;
703   }
704   
705   body .pl-mo {
706     color: #1d3e81;
707   }
708   
709   body kbd {
710     display: inline-block;
711     padding: 3px 5px;
712     font: 11px Consolas, "Liberation Mono", Menlo, Courier, monospace;
713     line-height: 10px;
714     color: #555;
715     vertical-align: middle;
716     background-color: #fcfcfc;
717     border: solid 1px #ccc;
718     border-bottom-color: #bbb;
719     border-radius: 3px;
720     box-shadow: inset 0 -1px 0 #bbb;
721   }
722   
723   body .task-list-item {
724     list-style-type: none;
725   }
726   
727   body .task-list-item+.task-list-item {
728     margin-top: 3px;
729   }
730   
731   body .task-list-item input {
732     margin: 0 0.35em 0.25em -1.6em;
733     vertical-align: middle;
734   }
735   
736   body :checked+.radio-label {
737     z-index: 1;
738     position: relative;
739     border-color: #4078c0;
740   }
741   </style>
742 </head>
743 <body>
744 <nav id="TOC" role="doc-toc">
745 <ul>
746 <li><a href="#building-jalview-from-source">Building Jalview from Source</a><ul>
747 <li><a href="#tldr">tl;dr</a></li>
748 <li><a href="#setting-up">Setting up</a><ul>
749 <li><a href="#java-11-compliant-jdk">Java 11 compliant JDK</a></li>
750 <li><a href="#gradle-and-git">gradle and git</a></li>
751 </ul></li>
752 <li><a href="#downloading-the-jalview-source-tree">Downloading the Jalview source tree</a><ul>
753 <li><a href="#whats-in-the-source-tree">What’s in the source tree?</a></li>
754 </ul></li>
755 <li><a href="#building-jalview">Building Jalview</a><ul>
756 <li><a href="#minimal-jalview-build">Minimal Jalview Build</a></li>
757 <li><a href="#jalview-in-a-jar-file">Jalview in a Jar File</a></li>
758 <li><a href="#distributed-jar-files">Distributed Jar Files</a></li>
759 <li><a href="#single-shadow-jar-file">Single <em>shadow</em> Jar File</a></li>
760 <li><a href="#building-the-getdown-launcher">Building the <code>getdown</code> launcher</a></li>
761 <li><a href="#running-tests">Running tests</a></li>
762 <li><a href="#installer-packaging-with-install4j">Installer packaging with <em>install4j</em></a></li>
763 </ul></li>
764 <li><a href="#building-in-eclipse">Building in Eclipse</a></li>
765 <li><a href="#gradle-properties">Gradle properties</a></li>
766 </ul></li>
767 </ul>
768 </nav>
769 <h1 id="building-jalview-from-source">Building Jalview from Source</h1>
770 <h2 id="tldr">tl;dr</h2>
771 <pre><code># download
772 git clone http://source.jalview.org/git/jalview.git
773 # compile
774 cd jalview
775 gradle shadowJar
776 # run
777 java -jar build/libs/jalview-all-11.jar
778
779 # and/or create launcher
780 gradle getdown
781 # use launcher
782 cd getdown/files
783 java -jar getdown-launcher.jar . jalview</code></pre>
784 <h2 id="setting-up">Setting up</h2>
785 <p>The method here is described in terms of using a command line. You can easily do this on linux or in a Terminal window in macOS. You can do it in Windows.</p>
786 <ul>
787 <li>Java 11 compliant JDK</li>
788 <li>gradle 5.1 or above</li>
789 <li>git</li>
790 </ul>
791 <blockquote>
792 <p>The versions and installation methods here are just suggestions (which we have tested so are known to work). If you need or wish to use different implementations (particularly you might need a bespoke JDK if you are on an exotic architecture) then the general build instructions should work with any gradle 5+. You should be able to compile the bytecode with any JDK Java 11+. The resulting bytecode (in particular the shadow jar) should be runnable in any JRE Java 1.8+. Remember that because Jalview and the getdown launcher are Java bytecode you can build on one system where you might have gradle, and run on another where you don’t (JRE 1.8+ required).</p>
793 </blockquote>
794 <h3 id="java-11-compliant-jdk">Java 11 compliant JDK</h3>
795 <h4 id="all-platforms">All platforms</h4>
796 <p>We recommend obtaining an OpenJDK JDK 11 (since 11 is the long term support release) from AdoptOpenJDK: <a href="https://adoptopenjdk.net/?variant=openjdk11&amp;jvmVariant=hotspot" class="uri">https://adoptopenjdk.net/?variant=openjdk11&amp;jvmVariant=hotspot</a>, either the <em>Installer</em> or <code>.zip</code>/<code>.tar.gz</code> variants whichever you prefer (if you’re not sure, choose the <em>Installer</em>).</p>
797 <blockquote>
798 <h5 id="alternativecli-install-of-adoptopenjdk-11">Alternative/CLI install of AdoptOpenJDK 11</h5>
799 <p>You can also install adoptopenjdk11 using either <code>brew</code> (macOS), <code>choco</code> (Windows) (see the section on <code>gradle</code> and <code>git</code> for more informaiton on <code>brew</code> and <code>choco</code>) or <code>yum</code> or <code>apt</code> (Linux):</p>
800 <h6 id="alternative-for-macos-and-homebrew">alternative for MacOS and Homebrew</h6>
801 <pre><code>brew tap adoptopenjdk/openjdk
802 brew cask install adoptopenjdk11</code></pre>
803 <h6 id="alternative-for-windows-and-chocolatey">alternative for Windows and Chocolatey</h6>
804 <pre><code>choco install adoptopenjdk11</code></pre>
805 <h6 id="alternative-for-linux-with-yumapt">alternative for Linux with yum/apt</h6>
806 <p>see <a href="https://adoptopenjdk.net/installation.html#linux-pkg" class="uri">https://adoptopenjdk.net/installation.html#linux-pkg</a></p>
807 </blockquote>
808 <h3 id="gradle-and-git">gradle and git</h3>
809 <p>You should be able to install the latest (or sufficiently recent) versions of gradle and git using your OS package manager.</p>
810 <h4 id="macos">MacOS</h4>
811 <p>we recommend using <code>brew</code>, which can be installed following the instructions at <a href="https://brew.sh/" class="uri">https://brew.sh/</a>. After installing <code>brew</code>, open a Terminal window and type in (using an Administrator privileged user):</p>
812 <div class="sourceCode" id="cb4"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb4-1" title="1"><span class="ex">brew</span> install gradle git</a></code></pre></div>
813 <p>or if you aready have them installed but need to upgrade the version:</p>
814 <div class="sourceCode" id="cb5"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb5-1" title="1"><span class="ex">brew</span> upgrade gradle git</a></code></pre></div>
815 <h4 id="windows">Windows</h4>
816 <p>we suggest using the <strong>Chocolatey</strong> package manager. See install instructions at <a href="https://chocolatey.org/" class="uri">https://chocolatey.org/</a>, and you will just need</p>
817 <div class="sourceCode" id="cb6"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb6-1" title="1"><span class="ex">choco</span> install gradle</a>
818 <a class="sourceLine" id="cb6-2" title="2"><span class="ex">choco</span> install git</a></code></pre></div>
819 <p>Alternatively, you could install a real <code>bash</code> shell and install both <code>gradle</code> and <code>git</code> through <code>apt-get</code>. See <a href="https://devblogs.microsoft.com/commandline/bash-on-ubuntu-on-windows-download-now-3/" class="uri">https://devblogs.microsoft.com/commandline/bash-on-ubuntu-on-windows-download-now-3/</a> for how to install the ubuntu bash shell in Windows 10.</p>
820 <p>Another alternative would be to install them separately. For <code>gradle</code> follow the instructions at <a href="https://gradle.org/install/" class="uri">https://gradle.org/install/</a>, and for <code>git</code> here are a couple of suggestions: Git for Windows <a href="https://gitforwindows.org/" class="uri">https://gitforwindows.org/</a>. Getting the individual installs working together on the command line will be trickier so we recommend using Chocolatey or bash.</p>
821 <h4 id="linux">Linux</h4>
822 <p>this will depend on which distribution you’re using.</p>
823 <h5 id="for-debian-based-distributions-e.g.-mint-ubuntu-debian">For <em>Debian</em> based distributions (e.g. Mint, Ubuntu, Debian)</h5>
824 <p>run</p>
825 <div class="sourceCode" id="cb7"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb7-1" title="1"> <span class="fu">sudo</span> apt-get install gradle git</a></code></pre></div>
826 <h5 id="for-rpm-based-distributions-e.g.-fedora-centos-redhat">for RPM-based distributions (e.g. Fedora, CentOS, RedHat)</h5>
827 <p>run</p>
828 <div class="sourceCode" id="cb8"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb8-1" title="1"><span class="fu">sudo</span> yum install gradle git</a></code></pre></div>
829 <p>If you have some other version of linux you’ll probably be able to work it out!</p>
830 <h2 id="downloading-the-jalview-source-tree">Downloading the Jalview source tree</h2>
831 <p>This can be done with <code>git</code>. On the command line, change directory to where you want to download Jalview’s build-tree top level directory. Then run</p>
832 <div class="sourceCode" id="cb9"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb9-1" title="1"><span class="fu">git</span> clone http://source.jalview.org/git/jalview.git</a></code></pre></div>
833 <p>You’ll get some progress output and after a minute or two you should have the full Jalview build-tree in the folder <code>jalview</code>.</p>
834 <h3 id="whats-in-the-source-tree">What’s in the source tree?</h3>
835 <p>Jalview is a mature product with its codebase going back many years. As such it doesn’t have a folder structure that most new gradle projects would have, so you might not find everything in the place you might expect. Here’s a brief description of what you might find in the main folders under the <code>jalview</code> tree.</p>
836 <p>Within the <code>jalview</code> folder you will find (of possible interest):</p>
837 <table>
838 <colgroup>
839 <col style="width: 15%" />
840 <col style="width: 84%" />
841 </colgroup>
842 <thead>
843 <tr class="header">
844 <th>dir/ or file</th>
845 <th>contains</th>
846 </tr>
847 </thead>
848 <tbody>
849 <tr class="odd">
850 <td><code>bin/</code></td>
851 <td>used by eclipse for compiled classes – no need to touch this</td>
852 </tr>
853 <tr class="even">
854 <td><code>build/</code></td>
855 <td>the gradle build dir</td>
856 </tr>
857 <tr class="odd">
858 <td><code>classes/</code></td>
859 <td>contains the compiled Java classes for the Jalview application</td>
860 </tr>
861 <tr class="even">
862 <td><code>dist/</code></td>
863 <td>assembled <code>.jar</code> files needed to run Jalview application</td>
864 </tr>
865 <tr class="odd">
866 <td><code>examples/</code></td>
867 <td>example input files usable by Jalview</td>
868 </tr>
869 <tr class="even">
870 <td><code>getdown/</code></td>
871 <td>the libraries used by the Javliew launcher (getdown)</td>
872 </tr>
873 <tr class="odd">
874 <td><code>getdown/src/</code></td>
875 <td>our modified source for <code>getdown</code></td>
876 </tr>
877 <tr class="even">
878 <td><code>getdown/website/</code></td>
879 <td>the assembled “download” folder used by getdown for downloads/upgrades</td>
880 </tr>
881 <tr class="odd">
882 <td><code>getdown/files/</code></td>
883 <td>the minimal fileset to launch the Jalview launcher, which can then download the rest of the Jalview application</td>
884 </tr>
885 <tr class="even">
886 <td><code>help/</code></td>
887 <td>the help documents</td>
888 </tr>
889 <tr class="odd">
890 <td><code>j8lib/</code></td>
891 <td>libraries needed to run Jalview under Java 1.8</td>
892 </tr>
893 <tr class="even">
894 <td><code>j11lib/</code></td>
895 <td>libraries needed to run Jalivew under Java 11</td>
896 </tr>
897 <tr class="odd">
898 <td><code>resource/</code></td>
899 <td>non-java resources used in the Jalview application</td>
900 </tr>
901 <tr class="even">
902 <td><code>src/</code></td>
903 <td>the Jalview application source <code>.java</code> files</td>
904 </tr>
905 <tr class="odd">
906 <td><code>test/</code></td>
907 <td>Test class source files</td>
908 </tr>
909 <tr class="even">
910 <td><code>utils/</code></td>
911 <td>helper applications used in the build process</td>
912 </tr>
913 <tr class="odd">
914 <td><code>utils/install4j/</code></td>
915 <td>files used by the packaging tool, install4j</td>
916 </tr>
917 <tr class="even">
918 <td><code>build.gradle</code></td>
919 <td>the build file used by gradle</td>
920 </tr>
921 <tr class="odd">
922 <td><code>gradle.properties</code></td>
923 <td>configurable properties for the build process</td>
924 </tr>
925 </tbody>
926 </table>
927 <p>Note that you need a Java 11 JDK to compile Jalview whether your target build is Java 1.8 or Java 11.</p>
928 <h2 id="building-jalview">Building Jalview</h2>
929 <p>You will need to have the Java 11 <code>javac</code> in your path, or alternatively you can configure gradle to know where this is by putting</p>
930 <pre><code>org.gradle.java.home=/path_to_jdk_directory</code></pre>
931 <p>in the <code>gradle.properties</code> file.</p>
932 <blockquote>
933 <p><em>You may want to see some of the other properties you can change at the end of this document.</em></p>
934 </blockquote>
935 <h3 id="minimal-jalview-build">Minimal Jalview Build</h3>
936 <p>To compile the necessary class files, just run</p>
937 <div class="sourceCode" id="cb11"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb11-1" title="1"><span class="ex">gradle</span> compileJava</a></code></pre></div>
938 <p>to compile the classes into the <code>classes</code> folder. You should now be able to run the Jalview application directly with</p>
939 <div class="sourceCode" id="cb12"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb12-1" title="1"><span class="ex">java</span> -cp <span class="st">&quot;classes:resources:help:j11lib/*&quot;</span> jalview.bin.Jalview</a></code></pre></div>
940 <p>You can also run with an automatic large memory setting (which will set the maximum memory heap of the Jalview JVM to 90% of your local physical memory) and docked icon setting (if possible in your OS) with</p>
941 <div class="sourceCode" id="cb13"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb13-1" title="1"><span class="ex">java</span> -cp <span class="st">&quot;classes:resources:help:j11lib/*&quot;</span> jalview.bin.Launcher</a></code></pre></div>
942 <blockquote>
943 <p><em>You must use just “<code>j11lib/*</code>” and not “<code>j11lib/*.jar</code>” as this is a special Java classpath argument wildcard interpreted by <code>java</code>, <strong>not</strong> a shell expansion wildcard interpreted by the shell.</em></p>
944 </blockquote>
945 <p>Note that <code>jalview.bin.Launcher</code> is a simplified launcher class that re-launches <code>jalview.bin.Jalview</code> with the same JRE (<em>not</em> the same JVM instance), classpath and arguments, but with an automatically determined <code>-Xmx...</code> memory setting if one hasn’t been provided.</p>
946 <h3 id="jalview-in-a-jar-file">Jalview in a Jar File</h3>
947 <p>To package the <code>classes</code>, <code>resources</code>, and <code>help</code> into one jar, you can run</p>
948 <div class="sourceCode" id="cb14"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb14-1" title="1"><span class="ex">gradle</span> jar</a></code></pre></div>
949 <p>which assembles the Jalview classes and resources into <code>dist/jalview.jar</code></p>
950 <p>To run this, use</p>
951 <div class="sourceCode" id="cb15"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb15-1" title="1"><span class="ex">java</span> -cp <span class="st">&quot;dist/jalview.jar:j11lib/*&quot;</span> jalview.bin.Jalview</a></code></pre></div>
952 <h3 id="distributed-jar-files">Distributed Jar Files</h3>
953 <p>To simplify this, all required <code>.jar</code> files can be assembled into the <code>dist</code> folder using</p>
954 <div class="sourceCode" id="cb16"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb16-1" title="1"><span class="ex">gradle</span> makeDist</a></code></pre></div>
955 <p>which puts all required jar files into <code>dist</code> so you can run with</p>
956 <div class="sourceCode" id="cb17"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb17-1" title="1"><span class="ex">java</span> -cp <span class="st">&quot;dist/*&quot;</span> jalview.bin.Jalview</a></code></pre></div>
957 <h3 id="single-shadow-jar-file">Single <em>shadow</em> Jar File</h3>
958 <p>The shadow jar file is a single <code>.jar</code> that contains all required classes and resources from <code>jalview.jar</code> and all of the supporting libraries in <code>j11lib/*.jar</code> merged into one <code>.jar</code> archive file. A default launching class (<code>MAIN-CLASS: jalview.bin.Launcher</code>) is specified in the <code>.jar</code> manifest file (<code>META/MANIFEST.MF</code>) so a start class doesn’t need to be specified.</p>
959 <p>Build the shadow jar file in <code>build/lib/jalview-all-11.jar</code> with</p>
960 <div class="sourceCode" id="cb18"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb18-1" title="1"><span class="ex">gradle</span> shadowJar</a></code></pre></div>
961 <p>and run it with</p>
962 <div class="sourceCode" id="cb19"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb19-1" title="1"><span class="ex">java</span> -jar build/lib/jalview-all-11.jar</a></code></pre></div>
963 <p>Because no arguments are required, most OSes will associate a <code>.jar</code> file with the <code>java</code> application (if this has been installed through the OS and not just a local unzip) as a <code>-jar</code> argument so you may find you can launch <code>jalview-all-11.jar</code> just by double-clicking on it)!</p>
964 <blockquote>
965 <p>The <code>shadowJar</code> task is not a requirement for any other task, so to build the shadow jar file you must specify the <code>shadowJar</code> task.</p>
966 </blockquote>
967 <blockquote>
968 <p>The shadow jar file represents probably the simplest way to distribute the Jalview application to machines that already have a Java 11 installed, although without the many and compelling benefits of the <code>getdown</code> launcher.</p>
969 </blockquote>
970 <h3 id="building-the-getdown-launcher">Building the <code>getdown</code> launcher</h3>
971 <p>We have made significant customisations to the <code>getdown</code> launcher which you can find in <code>getdown/src/getdown</code>.</p>
972 <blockquote>
973 <p>You don’t need to build this afresh as the required <code>gradle-core.jar</code> and <code>gradle-launcher.jar</code> files are already distributed in <code>j11lib</code> and <code>getdown/lib</code> but if you want to, then you’ll need a working Maven and also a Java 8 JDK. Ensure the Java 8 <code>javac</code> is forefront in your path and do</p>
974 <div class="sourceCode" id="cb20"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb20-1" title="1"><span class="bu">cd</span> getdown/src/getdown</a>
975 <a class="sourceLine" id="cb20-2" title="2"><span class="ex">mvn</span> clean package -Dgetdown.host.whitelist=<span class="st">&quot;jalview.org,*.jalview.org&quot;</span></a></code></pre></div>
976 <p>and you will find the required <code>.jar</code> files in <code>core/target/gradle-core-XXX.jar</code> and <code>launcher/target/gradle-launcher-XXX.jar</code>. The <code>gradle-core.jar</code> should then be copied to all three of the <code>j8lib</code>, <code>j11lib</code> and <code>getdown/lib</code> folders, whilst the <code>gradle-launcher.jar</code> only needs to be copied to <code>getdown/lib</code>.</p>
977 <p>The <code>mvn</code> command should ideally include the <code>-Dgetdown.host.whitelist=*.jalview.org</code> setting. This, and the necessary file copying commands, can be found in <code>getdown/src/getdown/mvn_cmd</code>.</p>
978 </blockquote>
979 <p>To assemble Jalview with <code>getdown</code> use the following gradle task:</p>
980 <div class="sourceCode" id="cb21"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb21-1" title="1"><span class="ex">gradle</span> getdown</a></code></pre></div>
981 <p>This puts all the necessary files to launch Jalview with <code>getdown</code> into <code>getdown/website/11/</code>. This could be treated as the reference folder for <code>getdown</code>, which is where a getdown launcher will check to see if the Jalview application files it has are up to date, and download if they aren’t or it simply doesn’t have them.</p>
982 <p>A minimal getdown-launcher can be found in <code>getdown/files/11/</code> which checks its up-to-date status with (the absolute path to) <code>getdown/website/11/</code>.</p>
983 <p>This can be launched with</p>
984 <div class="sourceCode" id="cb22"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb22-1" title="1"><span class="ex">java</span> -jar getdown/files/11/getdown-launcher.jar getdown/files/11/ jalview</a></code></pre></div>
985 <blockquote>
986 <p>We’ve already met the <code>-jar file.jar</code> arguments. The next argument is the working folder for getdown, and the final argument, “<code>jalview</code>”, is a getdown application id (only “<code>jalview</code>” is defined here).</p>
987 </blockquote>
988 <h3 id="running-tests">Running tests</h3>
989 <p>There are substantial tests written for Jalview that use TestNG, which you can run with</p>
990 <div class="sourceCode" id="cb23"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb23-1" title="1"><span class="ex">gradle</span> test</a></code></pre></div>
991 <p>These normally take around 5 - 10 minutes to complete and outputs its full results into the <code>tests/</code> folder. A summary of results should appear in your console.</p>
992 <h3 id="installer-packaging-with-install4j">Installer packaging with <em>install4j</em></h3>
993 <p>Jalview is currently using <em>install4j</em> <a href="https://www.ej-technologies.com/products/install4j/overview.html" class="uri">https://www.ej-technologies.com/products/install4j/overview.html</a> as its installer packaging tool.</p>
994 <p>If you have a licensed installation of <em>install4j</em> you can build Jalview installers by running</p>
995 <div class="sourceCode" id="cb24"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb24-1" title="1"><span class="ex">gradle</span> installers</a></code></pre></div>
996 <p>though you may need to fiddle with the <code>install4j</code> and <code>copyInstall4jTemplate</code> tasks in <code>build.gradle</code> file to point to your installation of <em>install4j</em> and also to bundled JREs if you want to bundle those into the installers.</p>
997 <p>If you want more details, get in touch on our development mailing list <a href="mailto:jalview-dev@jalview.org" class="email">jalview-dev@jalview.org</a>. Sign up at <a href="http://www.compbio.dundee.ac.uk/mailman/listinfo/jalview-dev" class="uri">http://www.compbio.dundee.ac.uk/mailman/listinfo/jalview-dev</a>.</p>
998 <h2 id="building-in-eclipse">Building in Eclipse</h2>
999 <p>We develop in Eclipse, and support settings to develop and save Jalview source code in our preferred style. We also support running the Jalview application, debugging and running tests with TestNG from within Eclipse.</p>
1000 <p>To get Jalview set up as a project in Eclipse, we recommend using at least the 2019-03 version of Eclipse IDE for Java Developers which you can download from the Eclipse website: <a href="https://www.eclipse.org/downloads/" class="uri">https://www.eclipse.org/downloads/</a></p>
1001 <p>Once installed, we also recommend installing several plugins from the Eclipse Marketplace.</p>
1002 <p>To do so, launch Eclipse, and go to Help-&gt;Eclipse Marketplace…</p>
1003 <p>Search for and install:</p>
1004 <ol type="1">
1005 <li>Buildship Gradle Integration 3.0 (or greater)</li>
1006 <li>Groovy Development Tools 3.4.0 (or greater)</li>
1007 <li>TestNG for Eclipse (optional – only needed if you want to run tests from Eclipse)</li>
1008 </ol>
1009 <blockquote>
1010 <p>At time of writing, TestNG for Eclipse does not show up in the Eclipse Marketplace as the latest released version does not install in Eclipse 2019-03. However, you can install a working beta of TestNG for Eclipse by going to</p>
1011 <p>Help-&gt;Install New Software…</p>
1012 <p>and entering</p>
1013 <p><code>TestNG Eclipse Composite P2 Repo - http://beust.com/eclipse-beta</code></p>
1014 <p>into the <em>Work with</em> box and click on the <em>Add…</em> button.</p>
1015 <p>Eclipse might pause for a bit with the word <em>Pending</em> in the table below at this point, but it will eventually list TestNG with a selection box under the <em>Name</em> column.</p>
1016 <p>Select <em>TestNG</em> and carry on through the install process to install the TestNG plugin.</p>
1017 </blockquote>
1018 <p>After installing the plugins, it is a good to get Java 11 set up in Eclipse as the default JRE.</p>
1019 <p>To do this go to Preferences (Eclipse-&gt;Preferences in macOS, File-&gt;Preferences on Windows or Window-&gt;Preferences on Linux) and find</p>
1020 <p>Java -&gt; Installed JREs</p>
1021 <p>If your Java 11 installation is not listed, click on</p>
1022 <p><em>Add</em> -&gt; Standard VM -&gt; <em>Next</em></p>
1023 <p>and enter the JRE home. You can browse to where it was installed. Give it a name (like “AdoptOpenJDK 11”). Select this JDK as the default JRE and click on <em>Apply and Close</em>.</p>
1024 <p>You can now import Jalview. It is important to import Jalview as a Gradle project (not as a Java project), so go to</p>
1025 <p>File-&gt;Import…</p>
1026 <p>find and select</p>
1027 <p>Gradle-&gt;Existing Gradle Project</p>
1028 <p>and then click on the <em>Next &gt;</em> button.</p>
1029 <p>In the following options, it is the <em>Project Root Directory</em> you should set to be the <code>jalview</code> folder that git downloaded. Then you can click on the <em>Finish</em> button.</p>
1030 <h2 id="gradle-properties">Gradle properties</h2>
1031 <p>There are a lot of properties configured in <code>gradle.properties</code> which we strongly recommend being left as they are unless you have a specific problem with the build process.</p>
1032 <p>There are a few gradle properties you might want to set on the command line with the <code>-P</code> flag when building a version of Jalview with specific requirements:</p>
1033 <h4 id="java_version"><code>JAVA_VERSION</code></h4>
1034 <p>This changes the <em>target</em> java bytecode version &gt; NOTE that you will need to use a Java 11 (or greater) JDK Java compiler to build Jalview for any byte-code target version.</p>
1035 <p>Valid values are <code>11</code> and <code>1.8</code>.</p>
1036 <p>e.g.</p>
1037 <div class="sourceCode" id="cb25"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb25-1" title="1"><span class="ex">gradle</span> shadowJar -PJAVA_VERSION=1.8</a></code></pre></div>
1038 <p>When using <code>-PJAVA_VERSION=1.8</code> the libraries from <code>j8lib</code> (instead of <code>j11lib</code>) will be used in the compile<br />
1039 and runtime classpath and also used in the <code>makeDist</code> build step. Where a Java version of <code>11</code> is used in folder and file names, it will instead use <code>1.8</code>. Also if you are building installer packages with <em>install4j</em> the package builder will look for JRE 1.8 bundles to package in the installers.</p>
1040 <blockquote>
1041 <p>Note that continued development of Jalview will assume a Java 11+ runtime environment, the 2.11.0 release will run under a Java 1.8 JRE with a few minor features disabled.</p>
1042 </blockquote>
1043 <h4 id="channel"><code>CHANNEL</code></h4>
1044 <p>This changes the <code>appbase</code> setting in <code>getdown.txt</code> (<code>appbase</code> is where the getdown launcher looks to see if there’s an updated file) to point to a particular Jalview channel. Expected values are <code>FILE</code>, <code>STABLE</code>, <code>DEVELOPMENT</code>, or a specific version of Jalview like <code>2.11</code> or <code>2.10.5</code>.</p>
1045 <p>A value of <code>FILE</code> behaves differently to the other expected values and will use a local file-system scheme URI instead of a Jalview release channel. This <code>file:</code> scheme URI uses an absolute path to the <code>getdown/website/&lt;JAVA_VERSION&gt;</code></p>
1046 <p>On a regular development machine, this property will default to <code>LOCAL</code>.</p>
1047 <p>e.g.</p>
1048 <div class="sourceCode" id="cb26"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb26-1" title="1"><span class="ex">gradle</span> getdown -PCHANNEL=DEVELOPMENT</a></code></pre></div>
1049 <h4 id="media_types"><code>MEDIA_TYPES</code></h4>
1050 <p>If you are building <em>install4j</em> installers (requires <em>install4j</em> to be installed) then this property specifies a comma-separated list of media types (i.e. platform specific installers) <em>install4j</em> should actually build.</p>
1051 <p>Currently the valid values are <code>linuxDeb</code>, <code>linuxRPM</code>, <code>macosArchive</code>, <code>unixArchive</code>, <code>unixInstaller</code>, <code>windows</code></p>
1052 <p>The default value is all of them.</p>
1053 <p>e.g.</p>
1054 <div class="sourceCode" id="cb27"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb27-1" title="1"><span class="ex">gradle</span> installers -PJAVA_VERSION=1.8 -PMEDA_TYPE=macosArchive</a></code></pre></div>
1055 <p>To get an up-to-date list of possible values, you can run</p>
1056 <div class="sourceCode" id="cb28"><pre class="sourceCode bash"><code class="sourceCode bash"><a class="sourceLine" id="cb28-1" title="1"><span class="fu">perl</span> -n -e <span class="st">&#39;m/^\s*&lt;(\w+)[^&gt;]*\bmediaFileName=/ &amp;&amp; print &quot;$1\n&quot;;&#39;</span> utils/install4j/install4j_template.install4j  <span class="kw">|</span> <span class="fu">sort</span> -u</a></code></pre></div>
1057 <p>in the <code>jalview</code> root folder.</p>
1058 </body>
1059 </html>