I am trying to compile the class "Example.scala" which has a dependency on the class "ProtocolLang.scala". I would like to do this without using sbt so I tried to use scalac directly on the command line. I tried making a jar from the ProtocolLang.scala class and then run:
scalac -classpath "LangJar.jar" Example.scala
The compiler does find "Example.scala" but does not seem to link it with the dependency and I get this error message:
Example.scala:3: error: not found: type ProtocolLang
The jar file is in the same directory as Example.scala and in the place I am calling the command. I used the command
jar cf LangJar.jar ProtocolLang.scala
to create the jar .