Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build osdetector-gradle-plugin for mips64el platform #8

Closed
vans88 opened this issue Oct 18, 2016 · 4 comments
Closed

build osdetector-gradle-plugin for mips64el platform #8

vans88 opened this issue Oct 18, 2016 · 4 comments

Comments

@vans88
Copy link

vans88 commented Oct 18, 2016

Basic information

I want to build osdetector-gradle-plugin for grpc-java locally. I get the source code from github. In the entire building process I encountered the following 2 errors:

The first one

when running the command "./gradlew install --info", I get the following info:

FAILURE: Build failed with an exception.
- What went wrong:
  Execution failed for task ':signArchives'.
  
  > Cannot perform signing task ':signArchives' because it has no configured signatory
- Try:
  Run with --stacktrace option to get the stack trace. Run with --debug option to get more log output.

BUILD FAILED

Total time: 44.037 secs
Stopped 0 compiler daemon(s).

then the second one

I commented the following line ---in file build.gradle line 61:
// sign configurations.archives
I try again it shows "Build Successfully"

Run test

But when I run "./gradlew test", I get the following error:

Starting process 'Gradle Test Executor 2'. Working directory: /usr/local/TenFlow/osdetector-gradle-plugin Command: /usr/lib/jvm/j2sdk-image/bin/java -Djava.security.manager=jarjar.org.gradle.process.internal.child.BootstrapSecurityManager -Dfile.encoding=UTF-8 -Duser.country=CN -Duser.language=zh -Duser.variant -ea -cp /root/.gradle/caches/2.3/workerMain/gradle-worker.jar jarjar.org.gradle.process.internal.launcher.GradleWorkerMain 'Gradle Test Executor 2'
Successfully started process 'Gradle Test Executor 2'
Gradle Test Executor 2 started executing tests.

com.google.gradle.osdetector.OsDetectorPluginTest > pluginAddsExtensionToProject STANDARD_OUT
    14:08:13.845 [Test worker] DEBUG o.g.i.n.f.s.FileSystemServices - Native-platform file system integration is not available. Continuing with fallback.
    14:08:13.888 [Test worker] DEBUG o.g.i.n.f.s.FileSystemServices - Using UnsupportedSymlink implementation.
    14:08:13.902 [Test worker] DEBUG o.g.i.n.f.s.FileSystemServices - Unable to load org.gradle.internal.nativeintegration.filesystem.jdk7.PosixJdk7FilePermissionHandler. Continuing with fallback org.gradle.internal.nativeintegration.filesystem.services.UnsupportedFilePermissions.
    14:08:16.765 [Test worker] DEBUG o.g.i.n.services.NativeServices - Native-platform process integration is not available. Continuing with fallback.
    14:08:20.494 [Test worker] INFO  c.g.gradle.osdetector.OsDetector - ------------------------------------------------------------------------
    14:08:20.501 [Test worker] INFO  c.g.gradle.osdetector.OsDetector - Detecting the operating system and CPU architecture
    14:08:20.502 [Test worker] INFO  c.g.gradle.osdetector.OsDetector - ------------------------------------------------------------------------
    14:08:20.509 [Test worker] INFO  c.g.gradle.osdetector.OsDetector - os.detected.name=linux
    14:08:20.510 [Test worker] INFO  c.g.gradle.osdetector.OsDetector - os.detected.arch=unknown

com.google.gradle.osdetector.OsDetectorPluginTest > pluginAddsExtensionToProject FAILED
    kr.motd.maven.os.DetectionException: unknown os.arch: mips64el
        at kr.motd.maven.os.Detector.detect(Detector.java:73)
        at com.google.gradle.osdetector.OsDetector$Impl.<init>(OsDetector.java:117)
        at com.google.gradle.osdetector.OsDetector.getImpl(OsDetector.java:64)
        at com.google.gradle.osdetector.OsDetector.getOs(OsDetector.java:34)
        at com.google.gradle.osdetector.OsDetector_Decorated.getOs(Unknown Source)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:483)
        at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:90)
        at groovy.lang.MetaBeanProperty.getProperty(MetaBeanProperty.java:60)
        at org.gradle.api.internal.BeanDynamicObject$MetaClassAdapter.getProperty(BeanDynamicObject.java:153)
        at org.gradle.api.internal.BeanDynamicObject.getProperty(BeanDynamicObject.java:107)
        at org.gradle.api.internal.CompositeDynamicObject.getProperty(CompositeDynamicObject.java:78)
        at com.google.gradle.osdetector.OsDetector_Decorated.getProperty(Unknown Source)
        at org.codehaus.groovy.runtime.callsite.PogoGetPropertySite.getProperty(PogoGetPropertySite.java:47)
        at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callGetProperty(AbstractCallSite.java:227)
        at com.google.gradle.osdetector.OsDetectorPluginTest.pluginAddsExtensionToProject(OsDetectorPluginTest.groovy:31)

com.google.gradle.osdetector.OsDetectorPluginTest > setClassifierWithLikes STANDARD_OUT
    14:08:21.197 [Test worker] INFO  c.g.gradle.osdetector.OsDetector - ------------------------------------------------------------------------
    14:08:21.200 [Test worker] INFO  c.g.gradle.osdetector.OsDetector - Detecting the operating system and CPU architecture
    14:08:21.202 [Test worker] INFO  c.g.gradle.osdetector.OsDetector - ------------------------------------------------------------------------
    14:08:21.207 [Test worker] INFO  c.g.gradle.osdetector.OsDetector - os.detected.name=linux
    14:08:21.209 [Test worker] INFO  c.g.gradle.osdetector.OsDetector - os.detected.arch=unknown
Gradle Test Executor 2 finished executing tests.

Anyone can give me some tips to deal with this situation?

@vans88
Copy link
Author

vans88 commented Oct 18, 2016

I have built os-maven-plugin successfully. and modified Detector.java(from os-maven-plugin) add the following lines to support my platform mips64el:

   if (value.matches("^(mips|mips64|mips64el)$")) {
             System.out.printf("*******************************\n");
             System.out.printf("**return** value: %s\n",value);
             return "mips64el";
        }

but, when I run command "./gradlew test" again the above error is still exists

@vans88
Copy link
Author

vans88 commented Oct 19, 2016

According to the README.md file:

$ git clone git@github.com:google/osdetector-gradle-plugin.git
$ cd osdetector-gradle-plugin
$ ./gradlew install
when I run command "**_./gradlew install --info_**"  the result is successful shown as follow:
:install (Thread[main,5,main]) started.
:install
Executing task ':install' (up-to-date check took 0.006 secs) due to:
  Task has not declared any outputs.
Publishing configuration: configuration ':archives'
Publishing to org.gradle.api.publication.maven.internal.ant.BaseMavenInstaller@314a31b0
[INFO] Installing /usr/local/TenFlow/osdetector-gradle-plugin/build/libs/osdetector-gradle-plugin-1.4.1-SNAPSHOT.jar to /root/.m2/repository/com/google/gradle/osdetector-gradle-plugin/1.4.1-SNAPSHOT/osdetector-gradle-plugin-1.4.1-SNAPSHOT.jar
[INFO] Installing /usr/local/TenFlow/osdetector-gradle-plugin/build/libs/osdetector-gradle-plugin-1.4.1-SNAPSHOT-sources.jar to /root/.m2/repository/com/google/gradle/osdetector-gradle-plugin/1.4.1-SNAPSHOT/osdetector-gradle-plugin-1.4.1-SNAPSHOT-sources.jar
[INFO] Installing /usr/local/TenFlow/osdetector-gradle-plugin/build/libs/osdetector-gradle-plugin-1.4.1-SNAPSHOT-javadoc.jar to /root/.m2/repository/com/google/gradle/osdetector-gradle-plugin/1.4.1-SNAPSHOT/osdetector-gradle-plugin-1.4.1-SNAPSHOT-javadoc.jar
[INFO] Installing /usr/local/TenFlow/osdetector-gradle-plugin/build/libs/osdetector-gradle-plugin-1.4.1-SNAPSHOT-groovydoc.jar to /root/.m2/repository/com/google/gradle/osdetector-gradle-plugin/1.4.1-SNAPSHOT/osdetector-gradle-plugin-1.4.1-SNAPSHOT-groovydoc.jar
:install (Thread[main,5,main]) completed. Took 5.357 secs.
**BUILD SUCCESSFUL**
Total time: 46.452 secs
Stopped 0 compiler daemon(s).

But when I run "./gradlew build ort test --info",getting the following error always.

com.google.gradle.osdetector.OsDetectorPluginTest > setClassifierWithLikes STANDARD_OUT
    16:50:43.511 [Test worker] INFO  c.g.gradle.osdetector.OsDetector - ------------------------------------------------------------------------
    16:50:43.512 [Test worker] INFO  c.g.gradle.osdetector.OsDetector - Detecting the operating system and CPU architecture
    16:50:43.513 [Test worker] INFO  c.g.gradle.osdetector.OsDetector - ------------------------------------------------------------------------
    16:50:43.516 [Test worker] INFO  c.g.gradle.osdetector.OsDetector - os.detected.name=linux
    16:50:43.517 [Test worker] INFO  c.g.gradle.osdetector.OsDetector - os.detected.arch=unknown
Gradle Test Executor 1 finished executing tests.

com.google.gradle.osdetector.OsDetectorPluginTest > setClassifierWithLikes FAILED


    kr.motd.maven.os.DetectionException: unknown os.arch: mips64el

... .... .... ... ... ... .. .. .. ... . ... .. .. .. .. . .. .. .. . .. .. . .. .. . .. .. .. .. . .. .. .. .. .. . .. . .. . .. . ... .. .. .. . . .. . .. . . .. .. ..

what differences between "install" and "build"? I need to excute tests successfully. Could you give some tips about this error.

@vans88
Copy link
Author

vans88 commented Oct 19, 2016

Here I paste some information about my platfrom:

java info

Java version: 1.8.0_25
Java vendor: Oracle Corporation
Java vendor URL: http://java.oracle.com/
Java home: /usr/lib/jvm/j2sdk-image/jre
Java vm.specification.version: 1.8
Java vm.specification.vendor: Oracle Corporation
Java vm.specification.name: Java Virtual Machine Specification
Java vm.version: 25.25-b02
Java vm.vendor: Oracle Corporation
Java vm.name: OpenJDK 64-Bit Server VM
Java specification.version: 1.8
Java specification.vendor: Oracle Corporation
Java specification.name: Java Platform API Specification
class.version: 52.0
class.path: .
library.path: /usr/java/packages/lib/mipsel:/usr/lib64:/lib64:/lib:/usr/lib
io.tmpdir: /tmp
java compiler: null
java ext dirs: /usr/lib/jvm/j2sdk-image/jre/lib/ext:/usr/java/packages/lib/ext
os.name: Linux
os.arch: mips64el
os.version: 4.4.21+
file.separator: /
path.separator: :
line.separator:

user name: root
user dir: /root/BigData
user home: /root

Arch info

[root@dscn2 ~]# lscpu
Architecture:          mips64
Byte Order:            Little Endian
CPU(s):                15
On-line CPU(s) list:   0-14
Thread(s) per core:    1
Core(s) per socket:    7
Socket(s):             2
NUMA node(s):          4
Model name:            ICT Loongson-3B R2 (Loongson-3B1500) @ 1100MHz
NUMA node0 CPU(s):     0-2
NUMA node1 CPU(s):     3-6
NUMA node2 CPU(s):     7-10
NUMA node3 CPU(s):     11-14

[root@dscn2 ~]# uname -a
Linux dscn2 4.4.21+ #3 SMP PREEMPT Wed Oct 12 09:14:23 CST 2016 mips64 mips64 mips64 GNU/Linux

This was referenced Nov 16, 2016
@ejona86
Copy link
Collaborator

ejona86 commented Jan 19, 2023

This seems like it was fixed many years ago. This is handled by the os-maven-plugin, so when they added support we got it as part of a normal upgrade.

@ejona86 ejona86 closed this as completed Jan 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants