I am trying to compile a simple closure project but I am getting this error:
build/closure-library/closure/bin/build/closurebuilder.py:
Compiling with the following command:
java -client -jar build/compiler.jar
--js build/closure-library/closure/goog/base.js
--js js/index.js
--manage_closure_dependencies=true
--transform_amd_modules
--process_common_js_modules
--common_js_entry_module
--common_js_module_path_prefix
--language_in=ECMASCRIPT5_STRICT
--compilation_level=SIMPLE_OPTIMIZATIONS
ERROR - required entry point "goog" never provided
As you can see, the java command is including base.js which has goog defined in it, so I have no idea what is going on.
I switched from using the bower version of closure-compiler to just cloning that actual source: https://github.com/google/closure-compiler and building it myself, and it worked.
Related
I'm using for the first time JavaFX on Intellij for an university project that requires me to develop a certain program.
I downloaded the 19.0.2.1 version of JavaFX.
Then, i created a new project, and tried to run the HelloApplication file (the one it automatically creates), and it did not build. So, i started following around 10 different guides, so the steps i did were:
In 'Project structure', i created a new path to my lib file in the javafxjdk i download before.
In 'Edit run configurations', i added this code to the option 'add VM options':
--module-path /Users/User/Download/javafx-sdk-19.0.2.1/lib
--add-modules=javafx.controls,javafx.fxml
I also changed the JAVA_HOME variable (i'm on Mac) using this command:
/usr/libexec/java_home
But whenever i run, it gives me this error:
Executing pre-compile tasks...
Running 'before' tasks
Checking sources
Copying resources... [TenthTry]
Parsing java… [TenthTry]
java: module not found: eu.hansolo.fx.countries
java: module not found: eu.hansolo.fx.heatmap
java: module not found: eu.hansolo.toolboxfx
java: module not found: eu.hansolo.toolbox
I have absolutely no clue how i can resolve this. Any help?
I fixed it!
Go to file->project structure->modules and in your modules find those four modules that are throwing an error. change them from "Runtime" to "Compile".
I asked at this issue, but I still can't solve a problem. I get error like required "Blockly" namespace never provided .
I follow Google bLockly Advanced Compilation tutorial to try. I did not create a new directory in the Blockly root directory to test, but instead used blockly and closure-library as subdirectories (submodules) in project as below :
project
├─blockly
├─closure-library
├─closure-compiler.jar
├─index.html
└─main.js
Then compile files using the commend as below :
java -jar closure-compiler.jar --js='main.js' ^
--js='./blockly/**.js' ^
--js='!./blockly/externs/**.js' ^
--js='!./blockly/msg/messages.js' ^
--js='./closure-library/closure/goog/**.js' ^
--js='./closure-library/third_party/closure/goog/**.js' ^
--generate_exports ^
--externs ./blockly/externs/svg-externs.js ^
--compilation_level ADVANCED_OPTIMIZATIONS ^
--dependency_mode=STRICT --entry_point=Main ^
--js_output_file main_compressed.js
Stack Traces
main.js:3: ERROR - required "Blockly.Msg.en" namespace never provided
goog.require('Blockly.Msg.en');
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
main.js:5: ERROR - required "Blockly" namespace never provided
goog.require('Blockly');
^^^^^^^^^^^^^^^^^^^^^^^
main.js:7: ERROR - required "Blockly.Constants.Logic" namespace never provided
goog.require('Blockly.Constants.Logic');
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
main.js:8: ERROR - required "Blockly.Constants.Loops" namespace never provided
goog.require('Blockly.Constants.Loops');
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
main.js:9: ERROR - required "Blockly.Constants.Math" namespace never provided
goog.require('Blockly.Constants.Math');
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
main.js:10: ERROR - required "Blockly.Constants.Text" namespace never provided
goog.require('Blockly.Constants.Text');
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
6 error(s), 0 warning(s)
Operating System
OS: Windows 7
java version "1.8.0_161"
Java(TM) SE Runtime Environment (build 1.8.0_161-b12)
Java HotSpot(TM) 64-Bit Server VM (build 25.161-b12, mixed mode)
Closure Compiler Version: v20180204
P.S. I get same errors even I follow all step in the tutorial (same directory structure as tutorial)
Usually the 'Namespace never provided' error is caused by not passing the file that provides that namespace to the compiler. Your directory layout is perfectly fine, but for the actual command I find it's always better to specify what files you want specifically rather than using the ! operator. I see a lot of people having issues with that. I would try the following:
`java -jar closure-compiler.jar --js='main.js' \
--js='blockly/blocks/**.js' \
--js='blockly/core/**.js' \
--js='blockly/generators/**.js' \
--js='blockly/msg/js/**.js' \
--js='closure-library/closure/goog/**.js' \
--js='closure-library/third_party/closure/goog/**.js' \
--generate_exports \
--externs blockly/externs/svg-externs.js \
--compilation_level ADVANCED_OPTIMIZATIONS \
--dependency_mode=STRICT --entry_point=Main \
--output_manifest manifest.MF
--js_output_file main_compressed.js`
Note that this will allow you see what files are actually being compiled by listing them in manifest.MF.
I access code in Docker($docker pull mreif/fse2016:evaluation), the code could be compiled and run without errors in remote server. While i download it to local machine, i suffered some errors in compiling(using: sbt compile):
[error] (*:update) sbt.ResolveException: unresolved dependency: de.opal-project#abstract-interpretation-framework_2.11;0.9.0-SNAPSHOT: not
[What i have done] I added follow lines into "build.sbt":
resolvers += "Sonatype OSS Snapshots" at "https://oss.sonatype.org/content/repositories/snapshots"
[error] evaluation/src/main/scala/org/opalj/evaluation/EntryPointAndCallEdgeCountAnalysis.scala:90: not found:
[What i have done] I added follow lines into "build.sbt":
libraryDependencies += "de.opal-project" % "fixpoint-computations-framework-analyses_2.11" % "0.9.0- SNAPSHOT"
3.[error] /src/main/scala/org/opalj/evaluation/EntryPointAndCallEdgeCountAnalysis.scala:130: not found: value LibraryEntryPointsAnalysis
I have checked the related code, LibraryEntryPointsAnalysis has been actually imported but doesn't work.
Could you please help me to confirm is there any operations i missed for compile the source code?
Thank you very much!
Jiang
The reason why it is not working is a version mismatch of the OPAL framework. The reason why it doesn't find the "LibraryEntryPointAnalysis" is, that it has been renamed.
You have to options:
Use the version of OPAL that is used in the Docker container
make a check out of OPAL at from version tag "ArtifactEvaluationFSE2016"
copy OPAl from the container like you did with the evaluation project
Adapt the Evaluation Project to the new API
the LibraryEntryPointsAnalysis is now called EntryPointAnalysis
there are probably other breaking changes that you have to fix
If you want to go with option one you have to build OPAL on your own because the eval version is not published on maven.
I just built standard core 15.09a on linux and run sample apps basic_client.
This one built by scons.
bin/samples/basic_client works fine.
However, I built cpp/samples/basic/basic_client with Makefile.
It does not work. It shows an error
"0.232 ****** ERROR ALLJOYN external ...e/src/BusAttachment.cc:560 | BusAttachment::Connect failed: ER_OS_ERROR
BusAttachment::Connect('') failed.".
So, I launched the bin/allhoyn-daemon, then no error occurred.
What is difference between scon and Makefile version?
Additionally, where can I get the information of application under the bin directory?
I searched the web-site of AllSeen and couldn't find any info.
As i know, the error that you got when build with Makefile happens because basic_client hasn't alljoyn router inside, with scons it runs fine because it compiles with BR=on and some flags:
-lajrouter -lBundledRouter.o -lssl -lcrypto
For more infomation, visit: here
I have just recently forked an outdated SBT project (which you can find here https://github.com/mdedetrich/sbt-bower) that was last working with an outdated version of SBT 0.11.0. I am trying to get the sbt plugin to work with SBT versions 0.12.3 and 0.13.0, however I am getting an issue on this line
https://github.com/mdedetrich/sbt-bower/blob/master/src/main/scala/SbtBowerPlugin.scala#L37
When I run sbt compile, I get the following error
[error] /Users/mdedetrich/github/sbt-bower/src/main/scala/SbtBowerPlugin.scala:37: value / is not a member of java.io.File
[error] sourceDirectory in Bower <<= (sourceDirectory).apply (_ / "main" / "webapp" )
Does anyone know what is causing this issue?
Thanks to Mark Harrah, this is actually due to this https://groups.google.com/forum/#!topic/simple-build-tool/0k1No2kfvm8/discussion
I had to remove the import Path._ in the SbtBowerPlugin.scala file and it now compiles fine!