diff --git a/.gitattributes b/.gitattributes index 9b03811..ba6da56 100644 --- a/.gitattributes +++ b/.gitattributes @@ -21,3 +21,6 @@ *.xz filter=lfs diff=lfs merge=lfs -text *.zip filter=lfs diff=lfs merge=lfs -text *.zst filter=lfs diff=lfs merge=lfs -text +## Specific LFS patterns +jquery-3.7.0.min.js filter=lfs diff=lfs merge=lfs -text +jquery-3.7.0.slim.min.js filter=lfs diff=lfs merge=lfs -text diff --git a/_service b/_service deleted file mode 100644 index f6b6bb1..0000000 --- a/_service +++ /dev/null @@ -1,19 +0,0 @@ - - - git - git://github.com/scala/scala.git - v2.10.7 - 2.10.7 - scala - lib/*.jar - lib/ant/*.jar - test - tools/*jar - src/compiler/scala/tools/nsc/doc/html/resource/lib - - - *.tar - xz - - - diff --git a/asm.properties b/asm.properties new file mode 100644 index 0000000..a5e789f --- /dev/null +++ b/asm.properties @@ -0,0 +1,4 @@ +#@@DATE@@ +scala.version.number=@@VER@@ +scala.binary.version.number=@@MAJVER@@ +version.number=@@ASMVER@@-scala-@@ASMREL@@ diff --git a/buildcharacter.properties b/buildcharacter.properties new file mode 100644 index 0000000..ebaee47 --- /dev/null +++ b/buildcharacter.properties @@ -0,0 +1,10 @@ +#@@DATE@@ +maven.version.number=@@VER@@ +maven.version.base=@@VER@@ +jline.version=@@JLINEVER@@ +version.number=@@VER@@ +scala-asm.version=@@ASMVER@@-scala-@@ASMREL@@ +maven.version.suffix= +starr.version=@@VER@@ +jna.version=@@JNAVER@@ +osgi.version.number=@@OSGI@@ diff --git a/compiler.properties b/compiler.properties new file mode 100644 index 0000000..5e77a2d --- /dev/null +++ b/compiler.properties @@ -0,0 +1,6 @@ +#@@DATE@@ +shell.banner=%n ________ ___ / / ___%n / __/ __// _ | / / / _ |%n __\\ \\/ /__/ __ |/ /__/ __ |%n /____/\\___/_/ |_/____/_/ | |%n |/ %s +copyright.string=Copyright 2002-2023, LAMP/EPFL and Lightbend, Inc. +version.number=@@VER@@ +osgi.version.number=@@OSGI@@ +maven.version.number=@@VER@@ diff --git a/jquery-3.7.0.min.js b/jquery-3.7.0.min.js new file mode 100644 index 0000000..3c4a071 --- /dev/null +++ b/jquery-3.7.0.min.js @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d8f9afbf492e4c139e9d2bcb9ba6ef7c14921eb509fb703bc7a3f911b774eff8 +size 87462 diff --git a/jquery-3.7.0.slim.min.js b/jquery-3.7.0.slim.min.js new file mode 100644 index 0000000..114a5f0 --- /dev/null +++ b/jquery-3.7.0.slim.min.js @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b46e6671952d26c66fc8a03160b557ae68ca0552dde95a5571cab3febe32a451 +size 70193 diff --git a/scala-2.10-jline.patch b/scala-2.10-jline.patch deleted file mode 100644 index bb84b27..0000000 --- a/scala-2.10-jline.patch +++ /dev/null @@ -1,99 +0,0 @@ ---- scala-2.10.7/src/compiler/scala/tools/nsc/interpreter/JLineReader.scala 2019-11-27 16:04:03.141644641 +0100 -+++ scala-2.10.7/src/compiler/scala/tools/nsc/interpreter/JLineReader.scala 2019-11-27 16:04:24.461764259 +0100 -@@ -45,7 +45,7 @@ - def readOneKey(prompt: String) = { - this.print(prompt) - this.flush() -- this.readVirtualKey() -+ this.readCharacter() - } - def eraseLine() = consoleReader.resetPromptLine("", "", 0) - def redrawLineAndFlush(): Unit = { flush() ; drawLine() ; flush() } ---- scala-2.10.7/src/compiler/scala/tools/nsc/interpreter/session/FileBackedHistory.scala 2019-11-27 16:04:03.141644641 +0100 -+++ scala-2.10.7/src/compiler/scala/tools/nsc/interpreter/session/FileBackedHistory.scala 2019-11-27 16:05:14.034042924 +0100 -@@ -15,7 +15,7 @@ - /** TODO: file locking. - */ - trait FileBackedHistory extends JLineHistory with JPersistentHistory { -- def maxSize: Int -+ def maxSize: Int = 2500 - - // For a history file in the standard location, always try to restrict permission, - // creating an empty file if none exists. ---- scala-2.10.7/src/compiler/scala/tools/nsc/interpreter/session/JLineHistory.scala 2019-11-27 16:04:03.141644641 +0100 -+++ scala-2.10.7/src/compiler/scala/tools/nsc/interpreter/session/JLineHistory.scala 2019-11-27 16:04:24.461764259 +0100 -@@ -13,7 +13,6 @@ - trait JLineHistory extends JHistory with History { - def size: Int - def isEmpty: Boolean -- def index: Int - def clear(): Unit - def get(index: Int): CharSequence - def add(line: CharSequence): Unit -@@ -42,7 +41,8 @@ - addLineToFile(item) - } - } -- override def toString = "History(size = " + size + ", index = " + index + ")" -+ override def toString = "History(size = " + size + ", _index = " + index + ")" -+ override def maxSize: Int = 2500 - } - - def apply(): JLineHistory = try new JLineFileHistory catch { case x: Exception => new SimpleHistory() } ---- scala-2.10.7/src/compiler/scala/tools/nsc/interpreter/session/SimpleHistory.scala 2019-11-27 16:04:03.141644641 +0100 -+++ scala-2.10.7/src/compiler/scala/tools/nsc/interpreter/session/SimpleHistory.scala 2019-11-27 16:04:24.461764259 +0100 -@@ -10,7 +10,7 @@ - import scala.collection.mutable.{ Buffer, ListBuffer } - import scala.collection.JavaConverters._ - --class SimpleHistory extends JLineHistory { -+class SimpleHistory extends JMemoryHistory with JLineHistory { - private var _index: Int = 0 - private val buf: Buffer[String] = new ListBuffer[String] - private def toEntries(): Seq[JEntry] = buf.zipWithIndex map { case (x, i) => Entry(i, x) } -@@ -32,27 +32,27 @@ - def maxSize: Int = 2500 - def last = if (isEmpty) fail("last") else buf.last - -- def size = buf.size -- def index = _index -- def isEmpty = buf.isEmpty -- def clear() = buf.clear() -- def get(idx: Int): CharSequence = buf(idx) -- def add(item: CharSequence): Unit = buf += item -- def replace(item: CharSequence): Unit = { -+ override def size = buf.size -+ override def index = _index -+ override def isEmpty = buf.isEmpty -+ override def clear() = buf.clear() -+ override def get(idx: Int): CharSequence = buf(idx) -+ override def add(item: CharSequence): Unit = buf += item -+ override def replace(item: CharSequence): Unit = { - buf trimEnd 1 - add(item) - } -- def entries(idx: Int): JListIterator[JEntry] = toEntries().asJava.listIterator(idx) -- def entries(): JListIterator[JEntry] = toEntries().asJava.listIterator() -- def iterator: JIterator[JEntry] = toEntries().iterator.asJava -- -- def current() = if (index >= 0 && index < buf.size) buf(index) else fail("current()") -- def previous() = (index > 0) && minusOne -- def next() = (index <= lastIndex) && plusOne -- def moveToFirst() = (size > 0) && (index != 0) && setTo(0) -- def moveToLast() = (size > 0) && (index < lastIndex) && setTo(lastIndex) -- def moveTo(idx: Int) = (idx > 0) && (idx <= lastIndex) && setTo(idx) -- def moveToEnd(): Unit = setTo(size) -+ override def entries(idx: Int): JListIterator[JEntry] = toEntries().asJava.listIterator(idx) -+ override def entries(): JListIterator[JEntry] = toEntries().asJava.listIterator() -+ override def iterator: JIterator[JEntry] = toEntries().iterator.asJava -+ -+ override def current() = if (index >= 0 && index < buf.size) buf(index) else fail("current()") -+ override def previous() = (index > 0) && minusOne -+ override def next() = (index <= lastIndex) && plusOne -+ override def moveToFirst() = (size > 0) && (index != 0) && setTo(0) -+ override def moveToLast() = (size > 0) && (index < lastIndex) && setTo(lastIndex) -+ override def moveTo(idx: Int) = (idx > 0) && (idx <= lastIndex) && setTo(idx) -+ override def moveToEnd(): Unit = setTo(size) - - // scala legacy interface - def asList: List[JEntry] = toEntries().toList diff --git a/scala-2.10.0-tooltemplate.patch b/scala-2.10.0-tooltemplate.patch deleted file mode 100644 index 7b9ae67..0000000 --- a/scala-2.10.0-tooltemplate.patch +++ /dev/null @@ -1,21 +0,0 @@ -diff -up scala-2.10.0-RC3/src/compiler/scala/tools/ant/templates/tool-unix.tmpl.tool scala-2.10.0-RC3/src/compiler/scala/tools/ant/templates/tool-unix.tmpl ---- scala-2.10.0-RC3/src/compiler/scala/tools/ant/templates/tool-unix.tmpl.tool 2012-11-21 17:01:54.000000000 +0100 -+++ scala-2.10.0-RC3/src/compiler/scala/tools/ant/templates/tool-unix.tmpl 2012-11-25 14:55:22.583111734 +0100 -@@ -68,7 +68,16 @@ if uname | grep -q ^MINGW; then - fi - - # Finding the root folder for this Scala distribution --SCALA_HOME="$(findScalaHome)" -+export JAVA_HOMe=/usr/share/jvm/java -+ -+[ -r @@JAVADIR@@-utils/java-functions ] && . @@JAVADIR@@-utils/java-functions || exit 1 -+ -+set_javacmd || exit 3 -+check_java_env || exit 4 -+set_jvm_dirs || exit 5 -+ -+export SCALA_HOME=@@DATADIR@@/scala -+ - SEP=":" - - # Possible additional command line options diff --git a/scala-2.10.2-java7.patch b/scala-2.10.2-java7.patch deleted file mode 100644 index 891f4de..0000000 --- a/scala-2.10.2-java7.patch +++ /dev/null @@ -1,198 +0,0 @@ -diff -up scala-2.10.0-RC3-sources/src/swing/scala/swing/ComboBox.scala.jdk7 scala-2.10.0-RC3-sources/src/swing/scala/swing/ComboBox.scala ---- scala-2.10.0-RC3-sources/src/swing/scala/swing/ComboBox.scala.jdk7 2012-11-05 02:49:19.000000000 +0100 -+++ scala-2.10.0-RC3-sources/src/swing/scala/swing/ComboBox.scala 2012-12-07 23:29:32.821949227 +0100 -@@ -9,7 +9,7 @@ - package scala.swing - - import event._ --import javax.swing.{JList, JComponent, JComboBox, JTextField, ComboBoxModel, AbstractListModel, ListCellRenderer} -+import javax.swing.{ JComponent, JComboBox, JTextField, ComboBoxModel, AbstractListModel, ListCellRenderer } - import java.awt.event.ActionListener - - object ComboBox { -@@ -118,10 +118,10 @@ object ComboBox { - implicit def floatEditor(c: ComboBox[Float]): Editor[Float] = new BuiltInEditor(c)(s => s.toFloat, s => s.toString) - implicit def doubleEditor(c: ComboBox[Double]): Editor[Double] = new BuiltInEditor(c)(s => s.toDouble, s => s.toString) - -- def newConstantModel[A](items: Seq[A]): ComboBoxModel = { -- new AbstractListModel with ComboBoxModel { -+ def newConstantModel[A](items: Seq[A]): ComboBoxModel[A] = { -+ new AbstractListModel[A] with ComboBoxModel[A] { - private var selected: A = if (items.isEmpty) null.asInstanceOf[A] else items(0) -- def getSelectedItem: AnyRef = selected.asInstanceOf[AnyRef] -+ def getSelectedItem = selected.asInstanceOf[AnyRef] - def setSelectedItem(a: Any) { - if ((selected != null && selected != a) || - selected == null && a != null) { -@@ -129,7 +129,7 @@ object ComboBox { - fireContentsChanged(this, -1, -1) - } - } -- def getElementAt(n: Int) = items(n).asInstanceOf[AnyRef] -+ def getElementAt(n: Int) = items(n).asInstanceOf[A] - def getSize = items.size - } - } -@@ -157,7 +157,7 @@ object ComboBox { - * @see javax.swing.JComboBox - */ - class ComboBox[A](items: Seq[A]) extends Component with Publisher { -- override lazy val peer: JComboBox = new JComboBox(ComboBox.newConstantModel(items)) with SuperMixin -+ override lazy val peer: JComboBox[A] = new JComboBox(ComboBox.newConstantModel(items)) with SuperMixin - - object selection extends Publisher { - def index: Int = peer.getSelectedIndex -@@ -182,7 +182,8 @@ class ComboBox[A](items: Seq[A]) extends - * of the component to its own defaults _after_ the renderer has been - * configured. That's Swing's principle of most suprise. - */ -- def renderer: ListView.Renderer[A] = ListView.Renderer.wrap(peer.getRenderer) -+ def renderer: ListView.Renderer[A] = ListView.Renderer.wrap[A](peer.getRenderer.asInstanceOf[ListCellRenderer[A]]) -+ // def renderer: ListView.Renderer[A] = ListView.Renderer.wrap(peer.getRenderer) - def renderer_=(r: ListView.Renderer[A]) { peer.setRenderer(r.peer) } - - /* XXX: currently not safe to expose: -@@ -201,8 +202,8 @@ class ComboBox[A](items: Seq[A]) extends - peer.setEditor(editor(this).comboBoxPeer) - } - -- def prototypeDisplayValue: Option[A] = toOption[A](peer.getPrototypeDisplayValue) -+ def prototypeDisplayValue: Option[A] = Option(peer.getPrototypeDisplayValue) - def prototypeDisplayValue_=(v: Option[A]) { -- peer.setPrototypeDisplayValue((v map toAnyRef).orNull) -+ peer.setPrototypeDisplayValue((v map toAnyRef).orNull.asInstanceOf[A]) - } - } -diff -up scala-2.10.0-RC3-sources/src/swing/scala/swing/ListView.scala.jdk7 scala-2.10.0-RC3-sources/src/swing/scala/swing/ListView.scala ---- scala-2.10.0-RC3-sources/src/swing/scala/swing/ListView.scala.jdk7 2012-11-05 02:49:19.000000000 +0100 -+++ scala-2.10.0-RC3-sources/src/swing/scala/swing/ListView.scala 2012-12-07 22:58:13.267919851 +0100 -@@ -24,21 +24,21 @@ object ListView { - val MultiInterval = Value(ListSelectionModel.MULTIPLE_INTERVAL_SELECTION) - } - -- def wrap[A](c: JList) = new ListView[A] { -+ def wrap[A](c: JList[A]) = new ListView[A] { - override lazy val peer = c - } - - object Renderer { -- def wrap[A](r: ListCellRenderer): Renderer[A] = new Wrapped[A](r) -+ def wrap[A](r: ListCellRenderer[A]): Renderer[A] = new Wrapped[A](r) - - /** - * Wrapper for javax.swing.ListCellRenderers - */ -- class Wrapped[A](override val peer: ListCellRenderer) extends Renderer[A] { -- def componentFor(list: ListView[_], isSelected: Boolean, focused: Boolean, a: A, index: Int) = { -+ class Wrapped[A](override val peer: ListCellRenderer[A]) extends Renderer[A] { -+ def componentFor(list: ListView[_ <: A], isSelected: Boolean, focused: Boolean, a: A, index: Int) = { - Component.wrap(peer.getListCellRendererComponent(list.peer, a, index, isSelected, focused).asInstanceOf[JComponent]) -+ } - } -- } - - /** - * Returns a renderer for items of type A. The given function -@@ -55,8 +55,8 @@ object ListView { - * - */ - def apply[A,B](f: A => B)(implicit renderer: Renderer[B]): Renderer[A] = new Renderer[A] { -- def componentFor(list: ListView[_], isSelected: Boolean, focused: Boolean, a: A, index: Int): Component = -- renderer.componentFor(list, isSelected, focused, f(a), index) -+ def componentFor(list: ListView[_ <: A], isSelected: Boolean, focused: Boolean, a: A, index: Int): Component = -+ renderer.componentFor(list.asInstanceOf[ListView[_ <: B]], isSelected, focused, f(a), index) - } - } - -@@ -69,11 +69,11 @@ object ListView { - * @see javax.swing.ListCellRenderer - */ - abstract class Renderer[-A] { -- def peer: ListCellRenderer = new ListCellRenderer { -- def getListCellRendererComponent(list: JList, a: Any, index: Int, isSelected: Boolean, focused: Boolean) = -- componentFor(ListView.wrap[A](list), isSelected, focused, a.asInstanceOf[A], index).peer -+ def peer: ListCellRenderer[_ >: A] = new ListCellRenderer[A] { -+ def getListCellRendererComponent(list: JList[_ <: A], a: A, index: Int, isSelected: Boolean, focused: Boolean) = -+ componentFor(ListView.wrap[A](list.asInstanceOf[JList[A]]), isSelected, focused, a, index).peer - } -- def componentFor(list: ListView[_], isSelected: Boolean, focused: Boolean, a: A, index: Int): Component -+ def componentFor(list: ListView[_ <: A], isSelected: Boolean, focused: Boolean, a: A, index: Int): Component - } - - /** -@@ -110,7 +110,7 @@ object ListView { - /** - * Configures the component before returning it. - */ -- def componentFor(list: ListView[_], isSelected: Boolean, focused: Boolean, a: A, index: Int): Component = { -+ def componentFor(list: ListView[_ <: A], isSelected: Boolean, focused: Boolean, a: A, index: Int): Component = { - preConfigure(list, isSelected, focused, a, index) - configure(list, isSelected, focused, a, index) - component -@@ -123,10 +123,10 @@ object ListView { - * that renders the string returned from an item's toString. - */ - implicit object GenericRenderer extends Renderer[Any] { -- override lazy val peer: ListCellRenderer = new DefaultListCellRenderer -- def componentFor(list: ListView[_], isSelected: Boolean, focused: Boolean, a: Any, index: Int): Component = { -- val c = peer.getListCellRendererComponent(list.peer, a, index, isSelected, focused).asInstanceOf[JComponent] -- Component.wrap(c) -+ override lazy val peer: ListCellRenderer[Any] = (new DefaultListCellRenderer).asInstanceOf[ListCellRenderer[Any]] -+ def componentFor(list: ListView[_ <: Any], isSelected: Boolean, focused: Boolean, a: Any, index: Int): Component = { -+ val c = peer.getListCellRendererComponent(list.peer, a, index, isSelected, focused) -+ Component.wrap(c.asInstanceOf[JComponent]) - } - } - } -@@ -142,34 +142,34 @@ object ListView { - */ - class ListView[A] extends Component { - import ListView._ -- override lazy val peer: JList = new JList with SuperMixin -+ override lazy val peer: JList[A] = new JList[A] with SuperMixin - - def this(items: Seq[A]) = { - this() - listData = items - } - -- protected class ModelWrapper(val items: Seq[A]) extends AbstractListModel { -- def getElementAt(n: Int) = items(n).asInstanceOf[AnyRef] -+ protected class ModelWrapper[A](val items: Seq[A]) extends AbstractListModel[A] { -+ def getElementAt(n: Int) = items(n) - def getSize = items.size - } - - def listData: Seq[A] = peer.getModel match { -- case model: ModelWrapper => model.items -- case model @ _ => new Seq[A] { selfSeq => -+ case model: ModelWrapper[a] => model.items -+ case model => new Seq[A] { selfSeq => - def length = model.getSize - def iterator = new Iterator[A] { - var idx = 0 - def next = { idx += 1; apply(idx-1) } - def hasNext = idx < selfSeq.length - } -- def apply(n: Int) = model.getElementAt(n).asInstanceOf[A] -+ def apply(n: Int): A = model.getElementAt(n) - } - } - - def listData_=(items: Seq[A]) { -- peer.setModel(new AbstractListModel { -- def getElementAt(n: Int) = items(n).asInstanceOf[AnyRef] -+ peer.setModel(new AbstractListModel[A] { -+ def getElementAt(n: Int) = items(n) - def getSize = items.size - }) - } -@@ -216,7 +216,7 @@ class ListView[A] extends Component { - def adjusting = peer.getSelectionModel.getValueIsAdjusting - } - -- def renderer: ListView.Renderer[A] = ListView.Renderer.wrap(peer.getCellRenderer) -+ def renderer: ListView.Renderer[A] = ListView.Renderer.wrap[A](peer.getCellRenderer.asInstanceOf[ListCellRenderer[A]]) - def renderer_=(r: ListView.Renderer[A]) { peer.setCellRenderer(r.peer) } - - def fixedCellWidth = peer.getFixedCellWidth diff --git a/scala-2.10.3-compiler-pom.patch b/scala-2.10.3-compiler-pom.patch deleted file mode 100644 index 83b0505..0000000 --- a/scala-2.10.3-compiler-pom.patch +++ /dev/null @@ -1,15 +0,0 @@ -diff -up scala-2.10.3/src/build/maven/scala-compiler-pom.xml.compiler-pom scala-2.10.3/src/build/maven/scala-compiler-pom.xml ---- scala-2.10.3/src/build/maven/scala-compiler-pom.xml.compiler-pom 2013-12-09 18:00:10.765090809 +0100 -+++ scala-2.10.3/src/build/maven/scala-compiler-pom.xml 2013-12-09 18:02:31.251138135 +0100 -@@ -43,9 +43,9 @@ - @VERSION@ - - -- org.scala-lang -+ jline - jline -- @VERSION@ -+ 2.10 - true - - diff --git a/scala-2.10.3-use_system_jline.patch b/scala-2.10.3-use_system_jline.patch deleted file mode 100644 index df2d1ba..0000000 --- a/scala-2.10.3-use_system_jline.patch +++ /dev/null @@ -1,109 +0,0 @@ -diff -up scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/ConsoleReaderHelper.scala.sysjline scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/ConsoleReaderHelper.scala ---- scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/ConsoleReaderHelper.scala.sysjline 2013-10-10 21:03:24.000000000 +0200 -+++ scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/ConsoleReaderHelper.scala 2013-10-13 15:28:24.478283303 +0200 -@@ -6,8 +6,8 @@ - package scala.tools.nsc - package interpreter - --import scala.tools.jline.console.{ ConsoleReader, CursorBuffer } --import scala.tools.jline.console.completer.CompletionHandler -+import jline.console.{ ConsoleReader, CursorBuffer } -+import jline.console.completer.CompletionHandler - import Completion._ - - trait ConsoleReaderHelper extends ConsoleReader { -diff -up scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/Delimited.scala.sysjline scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/Delimited.scala ---- scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/Delimited.scala.sysjline 2013-10-10 21:03:24.000000000 +0200 -+++ scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/Delimited.scala 2013-10-13 15:28:24.483282990 +0200 -@@ -6,7 +6,7 @@ - package scala.tools.nsc - package interpreter - --import scala.tools.jline.console.completer.ArgumentCompleter.{ ArgumentDelimiter, ArgumentList } -+import jline.console.completer.ArgumentCompleter.{ ArgumentDelimiter, ArgumentList } - - class JLineDelimiter extends ArgumentDelimiter { - def toJLine(args: List[String], cursor: Int) = args match { -diff -up scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/JLineCompletion.scala.sysjline scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/JLineCompletion.scala ---- scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/JLineCompletion.scala.sysjline 2013-10-10 21:03:24.000000000 +0200 -+++ scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/JLineCompletion.scala 2013-10-13 15:28:24.487282739 +0200 -@@ -6,8 +6,8 @@ - package scala.tools.nsc - package interpreter - --import scala.tools.jline._ --import scala.tools.jline.console.completer._ -+import jline._ -+import jline.console.completer._ - import Completion._ - import scala.collection.mutable.ListBuffer - -diff -up scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/JLineReader.scala.sysjline scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/JLineReader.scala ---- scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/JLineReader.scala.sysjline 2013-10-10 21:03:24.000000000 +0200 -+++ scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/JLineReader.scala 2013-10-13 15:30:16.619034744 +0200 -@@ -6,8 +6,8 @@ - package scala.tools.nsc - package interpreter - --import scala.tools.jline.console.ConsoleReader --import scala.tools.jline.console.completer._ -+import jline.console.ConsoleReader -+import jline.console.completer._ - import session._ - import scala.collection.JavaConverters._ - import Completion._ -@@ -71,6 +71,9 @@ class JLineReader(_completion: => Comple - def eraseLine() = consoleReader.eraseLine() - // Alternate implementation, not sure if/when I need this. - // def eraseLine() = while (consoleReader.delete()) { } -- def readOneLine(prompt: String) = consoleReader readLine prompt -+ def readOneLine(prompt: String) = { -+ consoleReader.setExpandEvents(false) -+ consoleReader readLine prompt -+ } - def readOneKey(prompt: String) = consoleReader readOneKey prompt - } -diff -up scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/Parsed.scala.sysjline scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/Parsed.scala ---- scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/Parsed.scala.sysjline 2013-10-10 21:03:24.000000000 +0200 -+++ scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/Parsed.scala 2013-10-13 15:28:24.496282176 +0200 -@@ -6,7 +6,7 @@ - package scala.tools.nsc - package interpreter - --import scala.tools.jline.console.completer.ArgumentCompleter.{ ArgumentDelimiter, ArgumentList } -+import jline.console.completer.ArgumentCompleter.{ ArgumentDelimiter, ArgumentList } - import util.returning - - /** One instance of a command buffer. -diff -up scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/ReplProps.scala.sysjline scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/ReplProps.scala ---- scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/ReplProps.scala.sysjline 2013-10-10 21:03:24.000000000 +0200 -+++ scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/ReplProps.scala 2013-10-13 15:28:24.500281925 +0200 -@@ -13,8 +13,8 @@ class ReplProps { - private def bool(name: String) = BooleanProp.keyExists(name) - private def int(name: String) = IntProp(name) - -- val jlineDebug = bool("scala.tools.jline.internal.Log.debug") -- val jlineTrace = bool("scala.tools.jline.internal.Log.trace") -+ val jlineDebug = bool("jline.internal.Log.debug") -+ val jlineTrace = bool("jline.internal.Log.trace") - - val info = bool("scala.repl.info") - val debug = bool("scala.repl.debug") -diff -up scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/session/package.scala.sysjline scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/session/package.scala ---- scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/session/package.scala.sysjline 2013-10-10 21:03:24.000000000 +0200 -+++ scala-2.10.3/src/compiler/scala/tools/nsc/interpreter/session/package.scala 2013-10-13 15:28:24.504281675 +0200 -@@ -14,10 +14,10 @@ package object session { - type JIterator[T] = java.util.Iterator[T] - type JListIterator[T] = java.util.ListIterator[T] - -- type JEntry = scala.tools.jline.console.history.History.Entry -- type JHistory = scala.tools.jline.console.history.History -- type JMemoryHistory = scala.tools.jline.console.history.MemoryHistory -- type JPersistentHistory = scala.tools.jline.console.history.PersistentHistory -+ type JEntry = jline.console.history.History.Entry -+ type JHistory = jline.console.history.History -+ type JMemoryHistory = jline.console.history.MemoryHistory -+ type JPersistentHistory = jline.console.history.PersistentHistory - - private[interpreter] implicit def charSequenceFix(x: CharSequence): String = x.toString - } diff --git a/scala-2.10.4-build_xml.patch b/scala-2.10.4-build_xml.patch deleted file mode 100644 index 0cfa47b..0000000 --- a/scala-2.10.4-build_xml.patch +++ /dev/null @@ -1,672 +0,0 @@ ---- a/build.xml 2014-09-15 16:38:35.523938086 -0500 -+++ b/build.xml 2014-09-18 14:37:16.648133327 -0500 -@@ -1,6 +1,6 @@ - - -- -+ - - SuperSabbus for Scala core, builds the scala library and compiler. It can also package it as a simple distribution, tests it for stable bootstrapping and against the Scala test suite. - -@@ -44,8 +44,8 @@ - -- -- -+ -+ - - - -@@ -68,7 +68,7 @@ - - - -- -+ - - - -@@ -89,14 +89,13 @@ - - - -+ - - - - -- -- - - - -@@ -122,8 +121,8 @@ - - - -- -- -+ -+ - - - -@@ -181,91 +180,54 @@ - - - -- -- -- -- -- -- -- -- - - - - -- -- -- -- -- -+ - -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -+ -+ -+ -+ -+ -+ -+ -+ -+ - -- -- -- -- -- -- -- -+ -+ -+ -+ -+ -+ -+ - -- -- -+ -+ -+ -+ -+ -+ -+ -+ -+ - - - -@@ -337,7 +302,7 @@ - - - -- -+ - - - -@@ -466,6 +431,13 @@ - - There must be a variable of the shape @{stage}.compiler.path for all @{stage} in starr, locker, quick, strap. - --> -+ -+ -+ -+ -+ -+ -+ - - - -@@ -576,13 +548,6 @@ - - - -- -- -- -- -- -- -- - - - -@@ -605,12 +570,10 @@ - - - -- - - - - -- - - - -@@ -647,18 +610,6 @@ - - - -- -- -- -- -- -- -- -- -- -- -- -- - - - -@@ -733,10 +684,6 @@ - - - -- -- -- -- - - - -@@ -765,7 +712,8 @@ - - - -- -+ -+ - - - -- -- -- - - -- -+ - - - -- -- -- -- -- -- -- -- -- -- -- -- -- - -- -+ - - - -@@ -1331,7 +1258,7 @@ - -- -+ - - - -@@ -1378,7 +1305,6 @@ - - - -- - - - -@@ -1386,10 +1312,7 @@ - - - -- -- -- -- -+ - - - -@@ -1519,81 +1442,6 @@ - - - -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - -@@ -1604,71 +1452,37 @@ - - - -- -- -- -- -- -- -- -- - - - - -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -+ - - - -- -- -- -- -- -+ - - - - -- -- -- - - - -- -+ - - -+ -+ -+ pack.bin.tool.path is ${packBinToolPath} -+ -+ -+ -+ -+ -+ -+ - - - -@@ -1688,6 +1502,7 @@ - - - -+ - - - -@@ -1740,15 +1555,14 @@ - - - -- -- -- -- -+ -+ -+ -+ -+ - -- -- -+ - -- - - - -@@ -1758,12 +1572,6 @@ - - - -- -- -- -- -- -- - - - -@@ -1771,10 +1579,12 @@ - - - -+ - - - - -+ - - - -- -+ - - - -- -+ - - - -@@ -1836,7 +1646,6 @@ - - - -- - - - -@@ -2027,10 +1836,9 @@ - - - -- -+ - - -- - - - -@@ -2047,7 +1855,6 @@ - - - -- - - - diff --git a/scala-2.10.6-scaladoc-resources.patch b/scala-2.10.6-scaladoc-resources.patch deleted file mode 100644 index 83940d4..0000000 --- a/scala-2.10.6-scaladoc-resources.patch +++ /dev/null @@ -1,25 +0,0 @@ -From f9b8176c668d3dff01da73fe65308bc50e355226 Mon Sep 17 00:00:00 2001 -From: Mikolaj Izdebski -Date: Fri, 12 Oct 2018 16:43:59 +0000 -Subject: [PATCH] Stop scaladoc from bundling web assets in generated docs - ---- - src/compiler/scala/tools/nsc/doc/html/HtmlFactory.scala | 2 -- - 1 file changed, 2 deletions(-) - -diff --git a/src/compiler/scala/tools/nsc/doc/html/HtmlFactory.scala b/src/compiler/scala/tools/nsc/doc/html/HtmlFactory.scala -index 4630c3d..648a588 100644 ---- a/src/compiler/scala/tools/nsc/doc/html/HtmlFactory.scala -+++ b/src/compiler/scala/tools/nsc/doc/html/HtmlFactory.scala -@@ -121,8 +121,6 @@ class HtmlFactory(val universe: doc.Universe, index: doc.Index) { - - DiagramGenerator.initialize(universe.settings) - -- libResources foreach (s => copyResource("lib/" + s)) -- - new page.Index(universe, index) writeFor this - new page.IndexScript(universe, index) writeFor this - --- -2.17.2 - diff --git a/scala-2.10.7-java8compat.patch b/scala-2.10.7-java8compat.patch deleted file mode 100644 index c947217..0000000 --- a/scala-2.10.7-java8compat.patch +++ /dev/null @@ -1,184 +0,0 @@ ---- scala-2.10.7/src/compiler/scala/tools/nsc/io/SourceReader.scala 2017-11-01 04:52:36.000000000 +0100 -+++ scala-2.10.7/src/compiler/scala/tools/nsc/io/SourceReader.scala 2019-11-28 18:22:37.444126737 +0100 -@@ -8,7 +8,7 @@ - package io - - import java.io.{ FileInputStream, InputStream, IOException } --import java.nio.{ByteBuffer, CharBuffer} -+import java.nio.{Buffer, ByteBuffer, CharBuffer} - import java.nio.channels.{FileChannel, ReadableByteChannel, Channels} - import java.nio.charset.{CharsetDecoder, CoderResult} - import scala.tools.nsc.reporters._ -@@ -61,13 +61,13 @@ - /** Reads the specified byte channel. */ - protected def read(input: ReadableByteChannel): Array[Char] = { - val decoder: CharsetDecoder = this.decoder.reset() -- val bytes: ByteBuffer = this.bytes; bytes.clear() -- var chars: CharBuffer = this.chars; chars.clear() -+ val bytes: ByteBuffer = this.bytes; bytes.asInstanceOf[Buffer].clear() -+ var chars: CharBuffer = this.chars; chars.asInstanceOf[Buffer].clear() - var endOfInput = false - - while (!endOfInput ) { - endOfInput = input.read(bytes) < 0 -- bytes.flip() -+ bytes.asInstanceOf[Buffer].flip() - chars = decode(decoder, bytes, chars, endOfInput) - } - terminate(flush(decoder, chars)) -@@ -76,7 +76,7 @@ - /** Reads the specified byte buffer. */ - protected def read(bytes: ByteBuffer): Array[Char] = { - val decoder: CharsetDecoder = this.decoder.reset() -- val chars: CharBuffer = this.chars; chars.clear() -+ val chars: CharBuffer = this.chars; chars.asInstanceOf[Buffer].clear() - terminate(flush(decoder, decode(decoder, bytes, chars, true))) - } - -@@ -128,7 +128,7 @@ - def flush(decoder: CharsetDecoder, chars: CharBuffer): CharBuffer = { - val result: CoderResult = decoder.flush(chars) - if (result.isUnderflow()) { -- chars.flip() -+ chars.asInstanceOf[Buffer].flip() - chars - } else { - if (result.isError()) throw new IOException(result.toString()) -@@ -142,7 +142,7 @@ - * content but with an increased capacity. - */ - private def increaseCapacity(buffer: CharBuffer): CharBuffer = { -- buffer.flip() -+ buffer.asInstanceOf[Buffer].flip() - val capacity = 2 * buffer.capacity() - CharBuffer.allocate(capacity).put(buffer) - } ---- scala-2.10.7/src/msil/ch/epfl/lamp/compiler/msil/Attribute.java 2017-11-01 04:52:36.000000000 +0100 -+++ scala-2.10.7/src/msil/ch/epfl/lamp/compiler/msil/Attribute.java 2019-11-28 17:28:47.932834776 +0100 -@@ -11,6 +11,7 @@ - import java.util.HashMap; - import java.util.LinkedHashMap; - import java.util.Iterator; -+import java.nio.Buffer; - import java.nio.ByteBuffer; - import java.nio.ByteOrder; - import java.io.UnsupportedEncodingException; -@@ -462,7 +463,7 @@ - return null; - try { str = new String(value, buf.position(), length, "UTF-8" ); } - catch (UnsupportedEncodingException e) { throw new Error(e); } -- buf.position(buf.position() + length); -+ ((Buffer)buf).position(buf.position() + length); - return str; - } - ---- scala-2.10.7/src/msil/ch/epfl/lamp/compiler/msil/PEFile.java 2017-11-01 04:52:36.000000000 +0100 -+++ scala-2.10.7/src/msil/ch/epfl/lamp/compiler/msil/PEFile.java 2019-11-28 17:32:27.926199324 +0100 -@@ -17,6 +17,7 @@ - import java.io.IOException; - import java.io.FileNotFoundException; - -+import java.nio.Buffer; - import java.nio.ByteBuffer; - import java.nio.channels.FileChannel; - import java.nio.MappedByteBuffer; -@@ -454,7 +455,7 @@ - - /** Go to the specified position in the file. */ - public void seek(int pos) { -- buf.position(pos); -+ ((Buffer)buf).position(pos); - } - - -@@ -485,7 +486,7 @@ - - /** Move the forward in the file by the specified number of bytes. */ - public void skip(int n) { -- buf.position(buf.position() + n); -+ ((Buffer)buf).position(buf.position() + n); - } - - /** -@@ -503,11 +504,11 @@ - - /** Returns a buffer from the given offset to the end of the file. */ - public ByteBuffer getBuffer(long offset, int size) { -- buf.mark(); -- buf.position((int)offset); -+ ((Buffer)buf).mark(); -+ ((Buffer)buf).position((int)offset); - ByteBuffer bb = buf.slice(); -- buf.reset(); -- bb.limit(size); -+ ((Buffer)buf).reset(); -+ ((Buffer)bb).limit(size); - bb.order(java.nio.ByteOrder.LITTLE_ENDIAN); - return bb; - } -@@ -707,11 +708,11 @@ - if (i < length - 1) - b.append(" "); - } -- buf.position(savedPos); -+ ((Buffer)buf).position(savedPos); - return b.append(")").toString(); - } - -- public Sig reset() { buf.position(pos); return this; } -+ public Sig reset() { ((Buffer)buf).position(pos); return this; } - - public int pos() { return buf.position() - pos; } - ---- scala-2.10.7/src/msil/ch/epfl/lamp/compiler/msil/util/PEStream.java 2017-11-01 04:52:36.000000000 +0100 -+++ scala-2.10.7/src/msil/ch/epfl/lamp/compiler/msil/util/PEStream.java 2019-11-28 17:36:37.103730311 +0100 -@@ -11,6 +11,7 @@ - import java.io.PrintStream; - import java.io.IOException; - -+import java.nio.Buffer; - import java.nio.ByteBuffer; - import java.nio.channels.FileChannel; - -@@ -64,7 +65,7 @@ - /** Move to the specified position in the stream. */ - private void seek(int pos) { - try { -- buffer.position(pos); -+ ((Buffer)buffer).position(pos); - } catch (IllegalArgumentException e) { - System.err.println("\nSeek failed in file " + file - + " for position " + pos -@@ -76,11 +77,11 @@ - /** Return a string from the specified position in the stream. */ - public String getString(int pos) { - seek(pos); -- buffer.mark(); -+ ((Buffer)buffer).mark(); - int i; - for (i = 0; getByte() != 0; i++); - byte[] buf = new byte[i]; -- buffer.reset(); // go back to the marked position -+ ((Buffer)buffer).reset(); // go back to the marked position - buffer.get(buf); - try { - return new String(buf, "UTF-8"); ---- scala-2.10.7/src/msil/ch/epfl/lamp/compiler/msil/util/Table.java 2017-11-01 04:52:36.000000000 +0100 -+++ scala-2.10.7/src/msil/ch/epfl/lamp/compiler/msil/util/Table.java 2019-11-28 17:34:43.543040457 +0100 -@@ -9,6 +9,7 @@ - import ch.epfl.lamp.compiler.msil.PEFile.Sig; - - import java.io.PrintStream; -+import java.nio.Buffer; - import java.nio.ByteBuffer; - import java.nio.MappedByteBuffer; - -@@ -327,7 +328,7 @@ - protected final void seekRow(int row) { - assert row > 0 && row <= rows - : "Index " + row + " is not within the table with #rows = " + rows; -- buffer.position((row - 1)* rowSize()); -+ ((Buffer)buffer).position((row - 1)* rowSize()); - } - - public final int currentRow() { return currentRow; } diff --git a/scala-2.10.7-jdk15.patch b/scala-2.10.7-jdk15.patch deleted file mode 100644 index f9e46c5..0000000 --- a/scala-2.10.7-jdk15.patch +++ /dev/null @@ -1,27 +0,0 @@ ---- scala-2.10.7/src/compiler/scala/tools/ant/antlib.xml 2023-09-28 18:35:06.147897841 +0200 -+++ scala-2.10.7/src/compiler/scala/tools/ant/antlib.xml 2023-09-28 18:47:47.202949642 +0200 -@@ -13,6 +13,4 @@ - classname="scala.tools.ant.ScalaTool"/> - -- - -Only in scala-2.10.7/src/compiler/scala/tools/ant: Pack200Task.scala ---- scala-2.10.7/src/library/scala/collection/mutable/StringBuilder.scala 2023-09-28 18:35:06.187898108 +0200 -+++ scala-2.10.7/src/library/scala/collection/mutable/StringBuilder.scala 2023-09-28 18:49:06.536809546 +0200 -@@ -437,6 +437,14 @@ - * @return the string assembled by this StringBuilder - */ - def result(): String = toString -+ -+ /** Tests whether this builder is empty. -+ * -+ * This method is required for JDK15+ compatibility -+ * -+ * @return `true` if this builder contains nothing, `false` otherwise. -+ */ -+ override def isEmpty: Boolean = underlying.length() == 0 - } - - object StringBuilder { diff --git a/scala-2.10.7-lines.patch b/scala-2.10.7-lines.patch deleted file mode 100644 index 17e3f93..0000000 --- a/scala-2.10.7-lines.patch +++ /dev/null @@ -1,147 +0,0 @@ ---- scala-2.10.7/src/compiler/scala/tools/cmd/gen/AnyVals.scala 2017-11-01 04:52:36.000000000 +0100 -+++ scala-2.10.7/src/compiler/scala/tools/cmd/gen/AnyVals.scala 2019-11-28 13:37:03.940143371 +0100 -@@ -183,7 +183,7 @@ - } - def objectLines = { - val comp = if (isCardinal) cardinalCompanion else floatingCompanion -- (comp + allCompanions + "\n" + nonUnitCompanions).trim.lines.toList ++ implicitCoercions map interpolate -+ (comp + allCompanions + "\n" + nonUnitCompanions).trim.linesIterator.toList ++ implicitCoercions map interpolate - } - - /** Makes a set of binary operations based on the given set of ops, args, and resultFn. -@@ -225,7 +225,7 @@ - def representation = repr.map(", a " + _).getOrElse("") - - def indent(s: String) = if (s == "") "" else " " + s -- def indentN(s: String) = s.lines map indent mkString "\n" -+ def indentN(s: String) = s.linesIterator map indent mkString "\n" - - def boxUnboxImpls = Map( - "@boxImpl@" -> "%s.valueOf(x)".format(boxedName), -@@ -453,9 +453,9 @@ - def ^(x: Boolean): Boolean - - override def getClass(): Class[Boolean] = null -- """.trim.lines.toList -+ """.trim.linesIterator.toList - -- def objectLines = interpolate(allCompanions + "\n" + nonUnitCompanions).lines.toList -+ def objectLines = interpolate(allCompanions + "\n" + nonUnitCompanions).linesIterator.toList - } - object U extends AnyValRep("Unit", None, "void") { - override def classDoc = """ -@@ -468,7 +468,7 @@ - def classLines = List( - """override def getClass(): Class[Unit] = null""" - ) -- def objectLines = interpolate(allCompanions).lines.toList -+ def objectLines = interpolate(allCompanions).linesIterator.toList - - override def boxUnboxImpls = Map( - "@boxImpl@" -> "scala.runtime.BoxedUnit.UNIT", ---- scala-2.10.7/src/compiler/scala/tools/nsc/doc/base/CommentFactoryBase.scala 2017-11-01 04:52:36.000000000 +0100 -+++ scala-2.10.7/src/compiler/scala/tools/nsc/doc/base/CommentFactoryBase.scala 2019-11-28 13:38:10.892515720 +0100 -@@ -209,7 +209,7 @@ - SafeTags.replaceAllIn(javadoclessComment, { mtch => - java.util.regex.Matcher.quoteReplacement(safeTagMarker + mtch.matched + safeTagMarker) - }) -- markedTagComment.lines.toList map (cleanLine(_)) -+ markedTagComment.linesIterator.toList map (cleanLine(_)) - } - - /** Parses a comment (in the form of a list of lines) to a `Comment` ---- scala-2.10.7/src/compiler/scala/tools/nsc/interactive/tests/InteractiveTestSettings.scala 2017-11-01 04:52:36.000000000 +0100 -+++ scala-2.10.7/src/compiler/scala/tools/nsc/interactive/tests/InteractiveTestSettings.scala 2019-11-28 13:39:14.716870692 +0100 -@@ -58,7 +58,7 @@ - val str = try File(optsFile).slurp() catch { - case e: java.io.IOException => "" - } -- str.lines.filter(!_.startsWith(CommentStartDelimiter)).mkString(" ") -+ str.linesIterator.filter(!_.startsWith(CommentStartDelimiter)).mkString(" ") - } - - override protected def printClassPath(implicit reporter: Reporter) { ---- scala-2.10.7/src/compiler/scala/tools/nsc/interpreter/AbstractFileClassLoader.scala 2017-11-01 04:52:36.000000000 +0100 -+++ scala-2.10.7/src/compiler/scala/tools/nsc/interpreter/AbstractFileClassLoader.scala 2019-11-28 13:57:53.339092518 +0100 -@@ -85,7 +85,7 @@ - defineClass(name, bytes, 0, bytes.length) - } - -- private val packages = mutable.Map[String, Package]() -+ private val whatever = mutable.Map[String, Package]() - - override def definePackage(name: String, specTitle: String, specVersion: String, specVendor: String, implTitle: String, implVersion: String, implVendor: String, sealBase: URL): Package = { - throw new UnsupportedOperationException() -@@ -94,7 +94,7 @@ - override def getPackage(name: String): Package = { - findAbstractDir(name) match { - case null => super.getPackage(name) -- case file => packages.getOrElseUpdate(name, { -+ case file => whatever.getOrElseUpdate(name, { - val ctor = classOf[Package].getDeclaredConstructor(classOf[String], classOf[String], classOf[String], classOf[String], classOf[String], classOf[String], classOf[String], classOf[URL], classOf[ClassLoader]) - ctor.setAccessible(true) - ctor.newInstance(name, null, null, null, null, null, null, null, this) ---- scala-2.10.7/src/compiler/scala/tools/nsc/interpreter/Formatting.scala 2017-11-01 04:52:36.000000000 +0100 -+++ scala-2.10.7/src/compiler/scala/tools/nsc/interpreter/Formatting.scala 2019-11-28 13:43:44.162369415 +0100 -@@ -25,7 +25,7 @@ - def indentCode(code: String) = { - val indent = spaces(code) - stringFromWriter(str => -- for (line <- code.lines) { -+ for (line <- code.linesIterator) { - str print indent - str print (line + "\n") - str.flush() ---- scala-2.10.7/src/compiler/scala/tools/nsc/interpreter/IMain.scala 2017-11-01 04:52:36.000000000 +0100 -+++ scala-2.10.7/src/compiler/scala/tools/nsc/interpreter/IMain.scala 2019-11-28 13:47:12.735529430 +0100 -@@ -454,7 +454,7 @@ - // enclosing in braces it is constructed like "val x =\n5 // foo". - private def removeComments(line: String): String = { - showCodeIfDebugging(line) // as we're about to lose our // show -- line.lines map (s => s indexOf "//" match { -+ line.linesIterator map (s => s indexOf "//" match { - case -1 => s - case idx => s take idx - }) mkString "\n" -@@ -580,7 +580,7 @@ - if (printResults && result != "") - printMessage(result stripSuffix "\n") - else if (isReplDebug) // show quiet-mode activity -- printMessage(result.trim.lines map ("[quiet] " + _) mkString "\n") -+ printMessage(result.trim.linesIterator map ("[quiet] " + _) mkString "\n") - - // Book-keeping. Have to record synthetic requests too, - // as they may have been issued for information, e.g. :type -@@ -1161,8 +1161,8 @@ - /** Secret bookcase entrance for repl debuggers: end the line - * with "// show" and see what's going on. - */ -- def isShow = code.lines exists (_.trim endsWith "// show") -- def isShowRaw = code.lines exists (_.trim endsWith "// raw") -+ def isShow = code.linesIterator exists (_.trim endsWith "// show") -+ def isShowRaw = code.linesIterator exists (_.trim endsWith "// raw") - - // old style - beSilentDuring(parse(code)) foreach { ts => ---- scala-2.10.7/src/compiler/scala/tools/nsc/interpreter/Power.scala 2017-11-01 04:52:36.000000000 +0100 -+++ scala-2.10.7/src/compiler/scala/tools/nsc/interpreter/Power.scala 2019-11-28 13:46:26.087269973 +0100 -@@ -150,7 +150,7 @@ - // Then we import everything from $r. - intp interpret ("import " + intp.pathToTerm("$r") + "._") - // And whatever else there is to do. -- init.lines foreach (intp interpret _) -+ init.linesIterator foreach (intp interpret _) - } - def valsDescription: String = { - def to_str(m: Symbol) = "%12s %s".format( ---- scala-2.10.7/src/scalacheck/org/scalacheck/Pretty.scala 2017-11-01 04:52:36.000000000 +0100 -+++ scala-2.10.7/src/scalacheck/org/scalacheck/Pretty.scala 2019-11-28 14:07:48.018400196 +0100 -@@ -45,7 +45,7 @@ - else s.substring(0, length) / break(lead+s.substring(length), lead, length) - - def format(s: String, lead: String, trail: String, width: Int) = -- s.lines.map(l => break(lead+l+trail, " ", width)).mkString("\n") -+ s.linesIterator.map(l => break(lead+l+trail, " ", width)).mkString("\n") - - implicit def prettyAny(t: Any) = Pretty { p => t.toString } - diff --git a/scala-2.10.7-source8.patch b/scala-2.10.7-source8.patch deleted file mode 100644 index 7ac612f..0000000 --- a/scala-2.10.7-source8.patch +++ /dev/null @@ -1,22 +0,0 @@ -Index: scala-2.10.7/build.xml -=================================================================== ---- scala-2.10.7.orig/build.xml -+++ scala-2.10.7/build.xml -@@ -758,7 +758,7 @@ TODO: - destdir="${@{project}-classes}" - classpath="${@{project}-classes}" - includes="**/*.java" -- target="1.6" source="1.5" -+ target="1.8" source="1.8" - compiler="javac1.6" - includeantruntime="false" > - -@@ -794,7 +794,7 @@ TODO: - includes="**/*.java" - excludes="@{excludes}" - includeantruntime="false" -- target="1.6" source="1.5"> -+ target="1.8" source="1.8"> - - - diff --git a/scala-2.10.7.tar.xz b/scala-2.10.7.tar.xz deleted file mode 100644 index a9a617e..0000000 --- a/scala-2.10.7.tar.xz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:0deeee6a636b0da742b4880ae62215aad6f5aa4e0ec8a3b0ce386c40edc53674 -size 2864660 diff --git a/scala-2.13.12.tar.gz b/scala-2.13.12.tar.gz new file mode 100644 index 0000000..fc3eb4d --- /dev/null +++ b/scala-2.13.12.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a73de0631dd67f632a62559643ea6da2e4172fe4a449b96872a4ea1c192d286f +size 7799882 diff --git a/scala-2.13.12.tgz b/scala-2.13.12.tgz new file mode 100644 index 0000000..01029d6 --- /dev/null +++ b/scala-2.13.12.tgz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:afe7e6fb59e3c88457e99f7018730e52fba27c8d15e3d7154f72968206ca8719 +size 24014528 diff --git a/scala-compiler-2.13.12.pom b/scala-compiler-2.13.12.pom new file mode 100644 index 0000000..cebd668 --- /dev/null +++ b/scala-compiler-2.13.12.pom @@ -0,0 +1,71 @@ + + + 4.0.0 + org.scala-lang + scala-compiler + jar + Compiler for the Scala Programming Language + https://www.scala-lang.org/ + 2.13.12 + + + Apache-2.0 + https://www.apache.org/licenses/LICENSE-2.0 + repo + + + Scala Compiler + 2002 + + LAMP/EPFL + https://lamp.epfl.ch/ + + + scm:git:git://github.com/scala/scala.git + https://github.com/scala/scala + + + GitHub + https://github.com/scala/bug/issues + + + + lamp + LAMP/EPFL + + + Lightbend + Lightbend, Inc. + + + + https://www.scala-lang.org/api/2.13.12/scala-compiler/ + + + + org.scala-lang + scala-library + 2.13.12 + + + org.scala-lang + scala-reflect + 2.13.12 + + + io.github.java-diff-utils + java-diff-utils + 4.12 + + + org.jline + jline + 3.22.0 + + + net.java.dev.jna + jna + 5.13.0 + + + \ No newline at end of file diff --git a/scala-compiler-bnd.properties b/scala-compiler-bnd.properties new file mode 100644 index 0000000..24fd545 --- /dev/null +++ b/scala-compiler-bnd.properties @@ -0,0 +1,4 @@ +Automatic-Module-Name: scala.tools.nsc +Bundle-Name: Scala Compiler +Bundle-SymbolicName: org.scala-lang.scala-compiler +Export-Package: LICENSE,NOTICE,compiler.properties,interactive.properties,jquery.min.js,jquery.slim.min.js,repl.properties,replFrontend.properties,rootdoc.txt,scala-asm.properties,scala-buildcharacter.properties,scala.*,scaladoc.properties,templates diff --git a/scala-compiler.jar b/scala-compiler.jar deleted file mode 100644 index 1a64b34..0000000 --- a/scala-compiler.jar +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:f514e88ce18b07350d6f6b04af751e89be7390ad6ab6bf28c9ca76ba5e24f136 -size 15442780 diff --git a/scala-library-2.10.0-bnd.properties b/scala-library-2.10.0-bnd.properties deleted file mode 100644 index 7310da6..0000000 --- a/scala-library-2.10.0-bnd.properties +++ /dev/null @@ -1,6 +0,0 @@ -Bundle-Name: Scala Distribution -Bundle-SymbolicName: org.scala-ide.scala.library -Export-Package: scala.* --reproducible: true --noextraheaders: true --snapshot: SNAPSHOT diff --git a/scala-library-2.13.12.pom b/scala-library-2.13.12.pom new file mode 100644 index 0000000..9ccc533 --- /dev/null +++ b/scala-library-2.13.12.pom @@ -0,0 +1,44 @@ + + + 4.0.0 + org.scala-lang + scala-library + jar + Standard library for the Scala Programming Language + https://www.scala-lang.org/ + 2.13.12 + + + Apache-2.0 + https://www.apache.org/licenses/LICENSE-2.0 + repo + + + Scala Library + 2002 + + LAMP/EPFL + https://lamp.epfl.ch/ + + + scm:git:git://github.com/scala/scala.git + https://github.com/scala/scala + + + GitHub + https://github.com/scala/bug/issues + + + + lamp + LAMP/EPFL + + + Lightbend + Lightbend, Inc. + + + + https://www.scala-lang.org/api/2.13.12/ + + \ No newline at end of file diff --git a/scala-library-bnd.properties b/scala-library-bnd.properties new file mode 100644 index 0000000..32e1772 --- /dev/null +++ b/scala-library-bnd.properties @@ -0,0 +1,4 @@ +Automatic-Module-Name: scala.library +Bundle-Name: Scala Standard Library +Bundle-SymbolicName: org.scala-lang.scala-library +Export-Package: LICENSE,NOTICE,library.properties,rootdoc.txt,scala.* diff --git a/scala-library.jar b/scala-library.jar deleted file mode 100644 index a6510b9..0000000 --- a/scala-library.jar +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:c960031a08b5d56c65362586f2b51e56387f27b18664a4e81fc72f9405870cde -size 7192234 diff --git a/scala-mime-info.xml b/scala-mime-info.xml index bc3e00b..e7b8c66 100644 --- a/scala-mime-info.xml +++ b/scala-mime-info.xml @@ -1,4 +1,4 @@ - + diff --git a/scala-reflect-2.13.12.pom b/scala-reflect-2.13.12.pom new file mode 100644 index 0000000..2b7d4cc --- /dev/null +++ b/scala-reflect-2.13.12.pom @@ -0,0 +1,51 @@ + + + 4.0.0 + org.scala-lang + scala-reflect + jar + Reflection Library for the Scala Programming Language + https://www.scala-lang.org/ + 2.13.12 + + + Apache-2.0 + https://www.apache.org/licenses/LICENSE-2.0 + repo + + + Scala Reflect + 2002 + + LAMP/EPFL + https://lamp.epfl.ch/ + + + scm:git:git://github.com/scala/scala.git + https://github.com/scala/scala + + + GitHub + https://github.com/scala/bug/issues + + + + lamp + LAMP/EPFL + + + Lightbend + Lightbend, Inc. + + + + https://www.scala-lang.org/api/2.13.12/scala-reflect/ + + + + org.scala-lang + scala-library + 2.13.12 + + + \ No newline at end of file diff --git a/scala-reflect-bnd.properties b/scala-reflect-bnd.properties new file mode 100644 index 0000000..c953b66 --- /dev/null +++ b/scala-reflect-bnd.properties @@ -0,0 +1,4 @@ +Automatic-Module-Name: scala.reflect +Bundle-Name: Scala Reflect +Bundle-SymbolicName: org.scala-lang.scala-reflect +Export-Package: LICENSE,NOTICE,reflect.properties,scala.* diff --git a/scala-reflect.jar b/scala-reflect.jar deleted file mode 100644 index ab46005..0000000 --- a/scala-reflect.jar +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:fdda7c7b298147dcd9eae5fb0bddfcff4211ccf57b7ae5203147c76c1219c8ca -size 3368851 diff --git a/scala-tooltemplate.patch b/scala-tooltemplate.patch new file mode 100644 index 0000000..65a24e5 --- /dev/null +++ b/scala-tooltemplate.patch @@ -0,0 +1,25 @@ +--- a/src/compiler/templates/tool-unix.tmpl ++++ b/src/compiler/templates/tool-unix.tmpl +@@ -12,15 +12,14 @@ + # additional information regarding copyright ownership. + ############################################################################## + ++. /usr/share/java-utils/java-functions || exit 1 ++ ++set_javacmd || exit 3 ++check_java_env || exit 4 ++set_jvm_dirs || exit 5 ++ + findScalaHome () { +- # see scala/bug#2092 and scala/bug#5792 +- local source="${BASH_SOURCE[0]}" +- while [ -h "$source" ] ; do +- local linked="$(readlink "$source")" +- local dir="$( cd -P "$(dirname "$source")" && cd -P "$(dirname "$linked")" && pwd )" +- source="$dir/$(basename "$linked")" +- done +- ( cd -P "$(dirname "$source")/.." && pwd ) ++ echo "/usr/share/java/scala" + } + execCommand () { + [[ -n $SCALA_RUNNER_DEBUG ]] && echo "" && for arg in "$@@"; do echo "$arg"; done && echo ""; diff --git a/scala-unbundle-fonts.patch b/scala-unbundle-fonts.patch new file mode 100644 index 0000000..08facb7 --- /dev/null +++ b/scala-unbundle-fonts.patch @@ -0,0 +1,36 @@ +--- a/src/scaladoc/scala/tools/nsc/doc/html/HtmlFactory.scala ++++ b/src/scaladoc/scala/tools/nsc/doc/html/HtmlFactory.scala +@@ -46,33 +46,6 @@ class HtmlFactory(val universe: doc.Univ + "object_comp_trait.svg", + "object_comp_annotation.svg", + "abstract_type.svg", +- "lato-v11-latin-100.eot", +- "lato-v11-latin-100.ttf", +- "lato-v11-latin-100.woff", +- "lato-v11-latin-regular.eot", +- "lato-v11-latin-regular.ttf", +- "lato-v11-latin-regular.woff", +- "open-sans-v13-latin-regular.eot", +- "open-sans-v13-latin-regular.ttf", +- "open-sans-v13-latin-regular.woff", +- "open-sans-v13-latin-400i.eot", +- "open-sans-v13-latin-400i.ttf", +- "open-sans-v13-latin-400i.woff", +- "open-sans-v13-latin-700.eot", +- "open-sans-v13-latin-700.ttf", +- "open-sans-v13-latin-700.woff", +- "open-sans-v13-latin-700i.eot", +- "open-sans-v13-latin-700i.ttf", +- "open-sans-v13-latin-700i.woff", +- "source-code-pro-v6-latin-700.eot", +- "source-code-pro-v6-latin-700.ttf", +- "source-code-pro-v6-latin-700.woff", +- "source-code-pro-v6-latin-regular.eot", +- "source-code-pro-v6-latin-regular.ttf", +- "source-code-pro-v6-latin-regular.woff", +- "MaterialIcons-Regular.eot", +- "MaterialIcons-Regular.ttf", +- "MaterialIcons-Regular.woff", + + "index.js", + "scheduler.js", diff --git a/scala.ant.d b/scala.ant.d deleted file mode 100644 index 0037f1b..0000000 --- a/scala.ant.d +++ /dev/null @@ -1 +0,0 @@ -scala diff --git a/scala.gitinfo b/scala.gitinfo deleted file mode 100644 index 5aee872..0000000 --- a/scala.gitinfo +++ /dev/null @@ -1,2 +0,0 @@ -89e57bc7ad4a1809864b637617456736fd7b8101 -20171031 diff --git a/scala.keys b/scala.keys new file mode 100644 index 0000000..1bf3524 --- /dev/null +++ b/scala.keys @@ -0,0 +1,4 @@ +text/x-scala + description=Scala source code + category=Software Development/Source Code + can_be_executable=TRUE diff --git a/scala.mime b/scala.mime new file mode 100644 index 0000000..a7d0f34 --- /dev/null +++ b/scala.mime @@ -0,0 +1,2 @@ +text/x-scala + ext: scala diff --git a/scala.spec b/scala.spec index d390c53..718e920 100644 --- a/scala.spec +++ b/scala.spec @@ -22,67 +22,79 @@ %else %bcond_with bootstrap %endif -%global fullversion %{version} -%global release_repository http://nexus.scala-tools.org/content/repositories/releases -%global snapshot_repository http://nexus.scala-tools.org/content/repositories/snapshots -%global jansi_jar %{_jnidir}/jansi/jansi.jar -%global jline2_jar %{_javadir}/jline/jline.jar -%global scaladir %{_datadir}/scala %global base_name scala -%define __requires_exclude .*org\.apache\.ant.* -Version: 2.10.7 -#!BcntSyncTag: scala +%global asmver 9.5.0 +%global asmrel 1 +# Version of jquery bundled in scaladoc +%global jqueryver 3.7.0 +# Version of jline to use +%global jlinever 3.22.0 +%global scaladir %{_datadir}/scala +# Used to generate OSGi data +%global date 20230901 +%global seqnum 134811 +%global commit 80514f73a6c7db32df9887d9a5ca9ae921e25118 +%global shortcommit %(c=%{commit}; echo ${c:0:7}) +%global osgiver %{version}.v%{date}-%{seqnum}-VFINAL-%{shortcommit} +%global majver %(cut -d. -f1-2 <<< %{version}) +Version: 2.13.12 Release: 0 -Summary: A hybrid functional/object-oriented language for the JVM -License: BSD-3-Clause AND CC0-1.0 AND SUSE-Public-Domain +Summary: Hybrid functional/object-oriented language for the JVM +# The project as a whole is Apache-2.0. +# The bundled ASM is BSD-3-Clause. +# The bundled jquery is MIT. +License: Apache-2.0 AND BSD-3-Clause AND MIT Group: Development/Libraries/Java URL: https://www.scala-lang.org/ -Source0: %{base_name}-%{version}.tar.xz -Source1: scala-library-2.10.0-bnd.properties -# git log --pretty=format:"%H%n%ci" v%{version} | head -n 2 | sed -e 's/\-//g' -e 's/\s\+.*//g' -Source3: scala.gitinfo -Source23: scala-mime-info.xml -Source24: scala.ant.d -# Change the default classpath (SCALA_HOME) -Patch1: scala-2.10.0-tooltemplate.patch -# Use system jline2 instead of bundled jline2 -Patch2: scala-2.10.3-use_system_jline.patch -# change org.scala-lang jline in org.sonatype.jline jline -Patch3: scala-2.10.3-compiler-pom.patch -# Patch Swing module for JDK 1.7 -Patch4: scala-2.10.2-java7.patch -# fix incompatibilities with JLine 2.7 -Patch6: scala-2.10-jline.patch -Patch8: scala-2.10.4-build_xml.patch -# Stop scaladoc from trying to bundle non-existent resources that were -# removed due to being in object form only, whithout sources -Patch9: scala-2.10.6-scaladoc-resources.patch -Patch10: scala-2.10.7-source8.patch -Patch11: scala-2.10.7-lines.patch -Patch12: scala-2.10.7-java8compat.patch -Patch13: scala-2.10.7-jdk15.patch -BuildRequires: ant -BuildRequires: ant-contrib -BuildRequires: ant-junit +# Source code +Source0: https://github.com/scala/scala/archive/v%{version}/%{base_name}-%{version}.tar.gz +# Scala-modified version of objectweb-asm +Source2: https://github.com/scala/scala-asm/archive/v%{asmver}-scala-%{asmrel}.tar.gz +# POMs from maven central +Source3: https://repo1.maven.org/maven2/org/scala-lang/scala-library/%{version}/scala-library-%{version}.pom +Source4: https://repo1.maven.org/maven2/org/scala-lang/scala-reflect/%{version}/scala-reflect-%{version}.pom +Source5: https://repo1.maven.org/maven2/org/scala-lang/scala-compiler/%{version}/scala-compiler-%{version}.pom +Source6: https://repo1.maven.org/maven2/org/scala-lang/scalap/%{version}/scalap-%{version}.pom +# Bundled version of jquery for scaladoc +Source7: https://code.jquery.com/jquery-%{jqueryver}.min.js +Source8: https://code.jquery.com/jquery-%{jqueryver}.slim.min.js +# OSGi properties for the reflect jar +Source9: scala-reflect-bnd.properties +# OSGi properties for the library jar +Source10: scala-library-bnd.properties +# OSGi properties for the compiler jar +Source11: scala-compiler-bnd.properties +# Properties file for scala-compiler +Source12: compiler.properties +# Properties file for scala-asm +Source13: asm.properties +# Properties file for scala-buildcharacter +Source14: buildcharacter.properties +# MIME information +Source15: scala.keys +Source16: scala.mime +Source17: scala-mime-info.xml +# Use the Fedora way of finding the JVM to invoke +Patch0: %{base_name}-tooltemplate.patch +# Unbundle fonts from scaladoc +Patch1: %{base_name}-unbundle-fonts.patch BuildRequires: aqute-bnd -BuildRequires: graphviz -BuildRequires: java-devel >= 1.8 BuildRequires: javapackages-local -BuildRequires: jline >= 2.10 -BuildRequires: junit -Requires: jansi -Requires: java-headless >= 1.8 -# Require full javapackages-tools since scripts use -# /usr/share/java-utils/java-functions +BuildRequires: xmvn-install +BuildRequires: xmvn-resolve +BuildRequires: mvn(io.github.java-diff-utils:java-diff-utils) +BuildRequires: mvn(junit:junit) +BuildRequires: mvn(net.java.dev.jna:jna) +BuildRequires: mvn(org.jline:jline-builtins) +BuildRequires: mvn(org.jline:jline-terminal-jna) +BuildRequires: mvn(org.openjdk.jol:jol-core) Requires: javapackages-tools -Requires: jline >= 2.10 -%if %{with bootstrap} -Source100: scala-compiler.jar -Source101: scala-library.jar -Source102: scala-reflect.jar -%endif +Obsoletes: %{base_name}-swing < 2.13.4 +BuildArch: noarch %if %{with bootstrap} Name: %{base_name}-bootstrap +# Binary form, used to bootstrap +Source1: https://downloads.lightbend.com/scala/%{version}/%{base_name}-%{version}.tgz %else Name: %{base_name} BuildRequires: %{base_name}-bootstrap >= %{version} @@ -92,203 +104,309 @@ Obsoletes: %{base_name}-bootstrap %description Scala is a general purpose programming language designed to express -common programming patterns in a concise and type-safe way. It -integrates features of object-oriented and functional languages. It -is also interoperable with Java. +common programming patterns in a concise, elegant, and type-safe way. +It smoothly integrates features of object-oriented and functional +languages. It is also fully interoperable with Java. %if %{without bootstrap} -%package apidoc +%package apidoc Summary: Documentation for the Scala programming language Group: Documentation/HTML -Obsoletes: %{base_name}-bootstrap-apidoc -BuildArch: noarch +Recommends: font(lato) +Recommends: font(opensans) +Recommends: font(sourcecodepro) -%description apidoc -Scala is a general purpose programming language for the JVM that blends -object-oriented and functional programming. This package provides -reference and API documentation for the Scala programming language. +%description apidoc +This package provides reference and API documentation for the Scala +programming language. %endif -%package swing -Summary: The swing library for the Scala programming languages -Group: Development/Libraries/Java -Requires: %{name} = %{version}-%{release} -Requires: java >= 1.8 -BuildArch: noarch -%if %{without bootstrap} -Obsoletes: %{base_name}-bootstrap-swing -%endif - -%description swing -This package contains the swing library for the Scala programming languages. -This library is required to develop GUI-related applications in Scala. -The release provided by this package is not the original version from upstream -because this version is not compatible with JDK 1.7. - -%package -n ant-%{name} -Summary: Development files for Scala -Group: Development/Libraries/Java -Requires: ant -Requires: scala = %{version}-%{release} -BuildArch: noarch -%if %{without bootstrap} -Obsoletes: ant-%{base_name}-bootstrap -%endif - -%description -n ant-%{name} -Scala is a general purpose programming language for the JVM that blends -object-oriented and functional programming. This package enables support for -the Scala ant tasks. - %prep -%setup -q -n %{base_name}-%{version} -%patch1 -p1 -b .tool -%patch2 -p1 -b .sysjline -%patch3 -p1 -b .compiler-pom -%patch4 -p1 -b .jdk7 -%patch6 -p1 -b .rvk -%patch8 -p1 -b .bld -%patch9 -p1 -b .scaladoc -%patch10 -p1 -b .source6 -%patch11 -p1 -b .jdk11 -%patch12 -p1 -b .java8compat -%patch13 -p1 -b .jdk15 - -echo "starr.version=2.10.4\nstarr.use.released=0" > starr.number - -rm -f src/compiler/scala/tools/ant/Pack200Task.scala - -pushd src -rm -rf jline -popd - -sed -i '/is not supported by/d' build.xml -sed -i '/exec.*pull-binary-libs.sh/d' build.xml +%autosetup -n %{base_name}-%{version} -p1 %if %{with bootstrap} -%global do_bootstrap -DdoBootstrapBuild=yes -%global docs_target %{nil} -%else -%global do_bootstrap %{nil} -%global docs_target docs +%setup -q -n %{base_name}-%{version} -T -D -a 1 %endif +%setup -q -n %{base_name}-%{version} -T -D -a 2 -pushd lib -%if %{without bootstrap} - rm -rf scala-compiler.jar - ln -s $(find-jar scala/scala-compiler) scala-compiler.jar - rm -rf scala-library.jar - ln -s $(find-jar scala/scala-library) scala-library.jar - rm -rf scala-reflect.jar - ln -s $(find-jar scala/scala-reflect) scala-reflect.jar -%else - cp %{SOURCE100} scala-compiler.jar - cp %{SOURCE101} scala-library.jar - cp %{SOURCE102} scala-reflect.jar -%endif - pushd ant - rm -rf ant.jar - rm -rf ant-contrib.jar - ln -s $(build-classpath ant.jar) ant.jar - ln -s $(build-classpath ant/ant-contrib) ant-contrib.jar - popd -popd +fixtimestamp() { + touch -r $1.orig $1 + rm -f $1.orig +} -sed -i -e 's!@JLINE@!%{jline2_jar}!g' build.xml +# Unbundle fonts +# The CSS uses local() references, so these should not be needed anyway. +rm src/scaladoc/scala/tools/nsc/doc/html/resource/lib/{lato,MaterialIcons,open-sans,source-code-pro}* -echo echo $(head -n 1 %{SOURCE3}) > tools/get-scala-commit-sha -echo echo $(tail -n 1 %{SOURCE3}) > tools/get-scala-commit-date -chmod 755 tools/get-scala-* +# Fetch upstream's POMs +cp -p %{SOURCE3} src/library/pom.xml +cp -p %{SOURCE4} src/reflect/pom.xml +cp -p %{SOURCE5} src/compiler/pom.xml +cp -p %{SOURCE6} src/scalap/pom.xml + +# Fedora has a split jline3, so split up the dependency +%pom_change_dep org.jline:jline org.jline:jline-terminal-jna src/compiler +%pom_add_dep org.jline:jline-reader:%{jlinever} src/compiler +%pom_add_dep org.jline:jline-style:%{jlinever} src/compiler +%pom_add_dep org.jline:jline-builtins:%{jlinever} src/compiler %build +export LC_ALL=C.UTF-8 -export ANT_OPTS="-Xms2048m -Xmx2048m %{do_bootstrap}" +%if %{with bootstrap} +PATH=$PATH:$PWD/%{base_name}-%{version}/bin +COMPJAR=$PWD/%{base_name}-%{version}/lib/scala-compiler.jar +%else +COMPJAR=%{_javadir}/scala/scala-compiler.jar +%endif -# Add the -verbose flag to scalac on zero architectures. The build -# is slow, OBS thinks it is stuck and kills it before it has chance -# to finish -%{ant} \ - build %{docs_target} || exit 1 -pushd build/pack/lib -mv scala-library.jar scala-library.jar.no -bnd wrap --properties %{SOURCE1} --output scala-library.jar \ - --version "%{version}" scala-library.jar.no -popd +JLINE_JARS=$(build-classpath jna jline3/jline-terminal jline3/jline-terminal-jna \ + jline3/jline-reader jline3/jline-style jline3/jline-builtins) +JAVAC_FLAGS="-g -parameters -source 8 -target 8" +SCALAC_FLAGS="-g:vars -release 8 -J-Xmx512M -J-Xms32M" +SCALADOC_FLAGS='-J-Xmx512M -J-Xms32M -doc-footer epfl -diagrams -implicits -groups -doc-version %{version} -doc-source-url https://github.com/scala/scala/blob/v%{version}/src/€{FILE_PATH_EXT}#L€{FILE_LINE}' +DIFFUTILS_JAR=$(build-classpath java-diff-utils) + +mkdir -p target/{compiler,library,manual,reflect,scalap,tastytest,testkit} +mkdir -p target/html/{compiler,library,reflect} + +# Build the bundled objectweb-asm +cd scala-asm-%{asmver}-scala-%{asmrel} +javac $JAVAC_FLAGS -d ../target/compiler $(find src -name \*.java) +cd - + +# Build the library +cd src +javac $JAVAC_FLAGS -d ../target/library -cp $(build-classpath junit) \ + $(find library -name \*.java) +scalac $SCALAC_FLAGS -d ../target/library -classpath ../target/library \ + $(find library -name \*.scala | sort) +%if %{without bootstrap} +scaladoc $SCALADOC_FLAGS -doc-title 'Scala Standard Library' \ + -sourcepath $PWD/library -doc-no-compile $PWD/library-aux \ + -skip-packages scala.concurrent.impl \ + -doc-root-content $PWD/library/rootdoc.txt \ + $(find library -name \*.scala | sort) +mv scala ../target/html/library +%endif + +# Build the reflection library +javac $JAVAC_FLAGS -d ../target/reflect $(find reflect -name \*.java) +scalac $SCALAC_FLAGS -d ../target/reflect -classpath ../target/reflect \ + $(find reflect -name \*.scala | sort) +%if %{without bootstrap} +scaladoc $SCALADOC_FLAGS -doc-title 'Scala Reflection Library' \ + -sourcepath $PWD/reflect \ + -skip-packages scala.reflect.macros.internal:scala.reflect.internal:scala.reflect.io \ + $(find reflect -name \*.scala | sort) +mv scala ../target/html/reflect +%endif + +# Build the compiler +javac $JAVAC_FLAGS -d ../target/compiler -cp $COMPJAR \ + $(find compiler -name \*.java) +scalac $SCALAC_FLAGS -d ../target/compiler \ + -classpath ../target/compiler:$DIFFUTILS_JAR \ + -feature $(find compiler -name \*.scala) + +# Build the interactive compiler +scalac $SCALAC_FLAGS -d ../target/compiler -classpath ../target/compiler \ + -feature $(find interactive -name \*.scala) + +# Build the REPL +scalac $SCALAC_FLAGS -d ../target/compiler -classpath ../target/reflect \ + -feature $(find repl -name \*.scala) + +# Build the REPL frontend +javac $JAVAC_FLAGS -d ../target/compiler $(find repl-frontend -name \*.java) +scalac $SCALAC_FLAGS -d ../target/compiler \ + -classpath ../target/compiler:$JLINE_JARS \ + -feature $(find repl-frontend -name \*.scala) +%if %{without bootstrap} +scaladoc $SCALADOC_FLAGS -doc-title 'Scala Compiler' \ + -sourcepath $PWD/compiler:$PWD/interactive:$PWD/repl:$PWD/repl-frontend \ + -doc-root-content $PWD/compiler/rootdoc.txt \ + -classpath $PWD/../target/library:$PWD/../target/reflect:$JLINE_JARS:$DIFFUTILS_JAR \ + $(find compiler -name \*.scala) $(find interactive -name \*.scala) \ + $(find repl -name \*.scala) $(find repl-frontend -name \*.scala) +mv scala ../target/html/compiler +%endif + +# Build the documentation generator +# The order of the source files matters! +scalac $SCALAC_FLAGS -d ../target/compiler \ + -feature $(find scaladoc -name \*.scala | sort) + +# Build the bytecode parser +scalac $SCALAC_FLAGS -d ../target/scalap $(find scalap -name \*.scala) + +# Build the testing tool +javac $JAVAC_FLAGS -d ../target/testkit \ + -cp ../target/library:$(build-classpath junit) \ + $(find testkit -name \*.java) +scalac $SCALAC_FLAGS -d ../target/testkit \ + -classpath ../target/testkit:$(build-classpath junit) -feature \ + $(find testkit -name \*.scala) + +# TODO: build the parser testing tool. This cannot be done without some sbt +# classes. If we have sbt, then we don't need to build manually anyway. + +# Build the integration tests +scalac $SCALAC_FLAGS -d ../target/tastytest -classpath $DIFFUTILS_JAR \ + $(find tastytest -name \*.scala) + +# Build the man page builder +scalac $SCALAC_FLAGS -d ../target/manual -classpath ../target/library \ + $(find manual -name \*.scala) +cd - + +# Copy source files into target before constructing jars +for dir in reflect library compiler scalap; do + cp -p LICENSE NOTICE target/$dir +done +cp -p src/library/rootdoc.txt target/library +cp -p src/compiler/rootdoc.txt target/compiler +cp -a src/compiler/templates target/compiler +mkdir -p target/compiler/scala/tools/nsc/doc/html/resource/lib/ +cp -p src/scaladoc/scala/tools/nsc/doc/html/resource/lib/* target/compiler/scala/tools/nsc/doc/html/resource/lib/ +cp -p src/scalap/decoder.properties target/scalap + +# Build the compiler jar +cd target +mkdir -p compiler/META-INF/services +cat > compiler/META-INF/services/javax.script.ScriptEngineFactory << EOF +scala.tools.nsc.interpreter.shell.Scripted\$Factory +EOF +propdate=$(date -u -d %{date}) +jnaver=$(rpm -q --qf="%{VERSION}" jna) +cp -p %{SOURCE7} compiler/jquery.min.js +cp -p %{SOURCE8} compiler/jquery.slim.min.js +sed -e "s/@@DATE@@/$propdate/;s/@@VER@@/%{version}/;s/@@OSGI@@/%{osgiver}/" \ + %{SOURCE12} > compiler/compiler.properties +cp -p compiler/compiler.properties compiler/interactive.properties +cp -p compiler/compiler.properties compiler/repl.properties +cp -p compiler/compiler.properties compiler/replFrontend.properties +cp -p compiler/compiler.properties compiler/scaladoc.properties +sed -e "s/@@DATE@@/$propdate/;s/@@VER@@/%{version}/;s/@@MAJVER@@/%{majver}/" \ + -e "s/@@ASMVER@@/%{asmver}/;s/@@ASMREL@@/%{asmrel}/" \ + %{SOURCE13} > compiler/scala-asm.properties +sed -e "s/@@DATE@@/$propdate/;s/@@VER@@/%{version}/;s/@@OSGI@@/%{osgiver}/" \ + -e "s/@@ASMVER@@/%{asmver}/;s/@@ASMREL@@/%{asmrel}/" \ + -e "s/@@JLINEVER@@/%{jlinever}/;s/@@JNAVER@@/$jnaver/" \ + %{SOURCE14} > compiler/scala-buildcharacter.properties +jar cf scala-compiler.jar.no -C compiler . +bnd wrap --properties %{SOURCE11} --output scala-compiler.jar \ + --version "%{osgiver}" scala-compiler.jar.no + +# Build the reflect jar +cp -p compiler/compiler.properties reflect/reflect.properties +jar cf scala-reflect.jar.no -C reflect . +bnd wrap --properties %{SOURCE9} --output scala-reflect.jar \ + --version "%{osgiver}" scala-reflect.jar.no + +# Build the library jar +cp -p compiler/compiler.properties library/library.properties +jar cf scala-library.jar.no -C library . +bnd wrap --properties %{SOURCE10} --output scala-library.jar \ + --version "%{osgiver}" scala-library.jar.no + +# Build the decoder jar +cp -p compiler/compiler.properties scalap/scalap.properties +jar cf scalap-%{version}.jar -C scalap . +cd - + +# Build the man pages +mkdir -p html man/man1 +cd src +scala -classpath ../target/manual:../target/scala-library.jar scala.tools.docutil.ManMaker 'fsc, scala, scalac, scaladoc, scalap' ../html ../man +cd - + +%{mvn_file} ":{*}" %{base_name}/@1 +# Prepare to install +%{mvn_artifact} src/library/pom.xml target/scala-library.jar +%{mvn_artifact} src/reflect/pom.xml target/scala-reflect.jar +%{mvn_artifact} src/compiler/pom.xml target/scala-compiler.jar +%{mvn_artifact} src/scalap/pom.xml target/scalap-%{version}.jar %install +%mvn_install -install -d %{buildroot}%{_bindir} -for prog in scaladoc fsc scala scalac scalap; do - install -p -m 755 build/pack/bin/$prog %{buildroot}%{_bindir} -done +# Create the binary scripts +mkdir -p %{buildroot}%{_bindir} +CLASSPATH=$(build-classpath jna jline3/jline-terminal \ + jline3/jline-terminal-jna jline3/jline-reader jline3/jline-style \ + jline3/jline-builtins)\ +:%{_javadir}/scala/scala-library.jar\ +:%{_javadir}/scala/scala-reflect.jar\ +:%{_javadir}/scala/scala-compiler.jar +JAVAFLAGS="-Xmx256M -Xms32M" -install -dm 0755 %{buildroot}%{scaladir}/lib -install -dm 0755 %{buildroot}%{_javadir}/%{base_name} -install -dm 0755 %{buildroot}%{_mavenpomdir} +sed -e "s,@classpath@,$CLASSPATH," \ + -e "s,@javaflags@,$JAVAFLAGS," \ + -e "s,@properties@ ,," \ + -e "s,@class@,scala.tools.nsc.fsc.CompileClient," \ + -e "s,@toolflags@ ,," \ + -e "s,@@,@,g" \ + src/compiler/templates/tool-unix.tmpl > %{buildroot}%{_bindir}/fsc -# XXX: add scala-partest when it works again -for libname in scala-compiler \ - scala-library \ - scala-reflect \ - scalap \ - scala-swing ; do - sed -i "s|@VERSION@|%{fullversion}|" src/build/maven/$libname-pom.xml - sed -i "s|@RELEASE_REPOSITORY@|%{release_repository}|" src/build/maven/$libname-pom.xml - sed -i "s|@SNAPSHOT_REPOSITORY@|%{snapshot_repository}|" src/build/maven/$libname-pom.xml - install -pm 0644 build/pack/lib/$libname.jar %{buildroot}%{_javadir}/%{base_name}/$libname.jar - ln -sf $(abs2rel %{_javadir}/%{base_name}/$libname.jar %{scaladir}/lib) %{buildroot}%{scaladir}/lib - # climbing-nemesis uses the old JPP naming convention - install -pm 0644 src/build/maven/$libname-pom.xml %{buildroot}%{_mavenpomdir}/JPP.%{base_name}-$libname.pom - if [ $libname == scala-swing ]; then - %add_maven_depmap JPP.%{base_name}-$libname.pom %{base_name}/$libname.jar -f swing - else - %add_maven_depmap JPP.%{base_name}-$libname.pom %{base_name}/$libname.jar - fi -done -ln -s $(abs2rel %{jline2_jar} %{scaladir}/lib) %{buildroot}%{scaladir}/lib -ln -s $(abs2rel %{jansi_jar} %{scaladir}/lib) %{buildroot}%{scaladir}/lib +sed -e "s,@classpath@,$CLASSPATH," \ + -e "s,@javaflags@,$JAVAFLAGS," \ + -e "s,@properties@ ,," \ + -e "s,@class@,scala.tools.nsc.MainGenericRunner," \ + -e "s,@toolflags@ ,," \ + -e "s,@@,@,g" \ + src/compiler/templates/tool-unix.tmpl > %{buildroot}%{_bindir}/scala -%if %{without bootstrap} -install -d %{buildroot}%{_sysconfdir}/ant.d -install -p -m 644 %{SOURCE24} %{buildroot}%{_sysconfdir}/ant.d/scala -%endif +sed -e "s,@classpath@,$CLASSPATH," \ + -e "s,@javaflags@,$JAVAFLAGS," \ + -e "s,@properties@ ,," \ + -e "s,@class@,scala.tools.nsc.Main," \ + -e "s,@toolflags@ ,," \ + -e "s,@@,@,g" \ + src/compiler/templates/tool-unix.tmpl > %{buildroot}%{_bindir}/scalac + +sed -e "s,@classpath@,$CLASSPATH," \ + -e "s,@javaflags@,$JAVAFLAGS," \ + -e "s,@properties@ ,," \ + -e "s,@class@,scala.tools.nsc.ScalaDoc," \ + -e "s,@toolflags@ ,," \ + -e "s,@@,@,g" \ + src/compiler/templates/tool-unix.tmpl > %{buildroot}%{_bindir}/scaladoc + +sed -e "s,@classpath@,$CLASSPATH:$(build-classpath scala/scalap)," \ + -e "s,@javaflags@,$JAVAFLAGS," \ + -e "s,@properties@ ,," \ + -e "s,@class@,scala.tools.scalap.Main," \ + -e "s,@toolflags@ ,," \ + -e "s,@@,@,g" \ + src/compiler/templates/tool-unix.tmpl > %{buildroot}%{_bindir}/scalap + +chmod 0755 %{buildroot}%{_bindir}/{fsc,scala*} + +# Install the MIME info +#install -d %{buildroot}%{_datadir}/mime-info +#install -p -m 644 %{SOURCE15} %{SOURCE16} %{buildroot}%{_datadir}/mime-info/ install -d %{buildroot}%{_datadir}/mime/packages/ -install -p -m 644 %{SOURCE23} %{buildroot}%{_datadir}/mime/packages/ +install -p -m 644 %{SOURCE17} %{buildroot}%{_datadir}/mime/packages/ -sed -i -e 's,@JAVADIR@,%{_javadir},g' -e 's,@DATADIR@,%{_datadir},g' %{buildroot}%{_bindir}/* - -%if %{without bootstrap} +# Install the man pages install -d %{buildroot}%{_mandir}/man1 -install -p -m 644 build/scaladoc/manual/man/man1/* %{buildroot}%{_mandir}/man1 -%endif +install -p -m 644 man/man1/* %{buildroot}%{_mandir}/man1 %files -f .mfiles -%{_bindir}/* -%dir %{_datadir}/%{base_name} -%dir %{_datadir}/%{base_name}/lib -%{_datadir}/%{base_name}/lib/*.jar -%exclude %{_datadir}/%{base_name}/lib/scala-swing.jar -%{_datadir}/mime/packages/* -%license docs/LICENSE -%if %{without bootstrap} -%{_mandir}/man1/* -%endif - -%files swing -f .mfiles-swing -%license docs/LICENSE -%{_datadir}/%{base_name}/lib/scala-swing.jar +%{_bindir}/fsc +%{_bindir}/scala* +#{_datadir}/mime-info/scala.* +%{_datadir}/mime/packages/scala-mime-info.xml +%{_mandir}/man1/fsc.1%{?ext_man} +%{_mandir}/man1/scala* +%license LICENSE NOTICE doc/LICENSE.md doc/License.rtf %if %{without bootstrap} -%files -n ant-%{name} -# Following is plain config because the ant task classpath could change from -# release to release -%config %{_sysconfdir}/ant.d/* -%license docs/LICENSE - %files apidoc -%doc build/scaladoc/library/* -%license docs/LICENSE +%doc target/html/* +%license LICENSE NOTICE doc/LICENSE.md doc/License.rtf %endif %changelog diff --git a/scalap-2.13.12.pom b/scalap-2.13.12.pom new file mode 100644 index 0000000..14a957f --- /dev/null +++ b/scalap-2.13.12.pom @@ -0,0 +1,48 @@ + + + 4.0.0 + org.scala-lang + scalap + jar + bytecode analysis tool + https://www.scala-lang.org/ + 2.13.12 + + + Apache-2.0 + https://www.apache.org/licenses/LICENSE-2.0 + repo + + + Scalap + 2002 + + LAMP/EPFL + https://lamp.epfl.ch/ + + + scm:git:git://github.com/scala/scala.git + https://github.com/scala/scala + + + GitHub + https://github.com/scala/bug/issues + + + + lamp + LAMP/EPFL + + + Lightbend + Lightbend, Inc. + + + + + org.scala-lang + scala-compiler + 2.13.12 + + + \ No newline at end of file diff --git a/v9.5.0-scala-1.tar.gz b/v9.5.0-scala-1.tar.gz new file mode 100644 index 0000000..f0e9217 --- /dev/null +++ b/v9.5.0-scala-1.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ff7cf540b4e2543b6d219a426d6ff10435a4bbf570d879234a65a79035e403fd +size 261603