Re: can't compile okhttp-3.6.0 - AndroidPlatform.java:[18, 20] package android.util does not exist

2017-03-10 Thread gil

hi

you should remove all Android implementations from its code

used only in android enviroment

for the moment i don't want upgrade okhttp to the 3 series

regards

.g

https://bugzilla.redhat.com/show_bug.cgi?id=837450


Il 10/03/2017 16:44, Martin Gansser ha scritto:

I tried to compile the new version 3.6.0 of okhttp, itook the rpm spec file 
from http://pkgs.fedoraproject.org/cgit/rpms/okhttp.git/tree/okhttp.spec
and changed the version numbering.
my rpm spec file: 
https://martinkg.fedorapeople.org/Packages/okhttp3/okhttp-3.6.0.spec

But the compilation fails with this errors:

[ERROR] Failed to execute goal 
org.apache.maven.plugins:maven-compiler-plugin:3.5.1:compile (default-compile) 
on project okhttp: Compilation failure: Compilation failure:
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/platform/AndroidPlatform.java:[18,20]
 package android.util does not exist
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/Util.java:[412,15]
 cannot find symbol
[ERROR] symbol:   method rangeEquals(int,okio.ByteString)
[ERROR] location: variable source of type okio.BufferedSource
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/Util.java:[416,15]
 cannot find symbol
[ERROR] symbol:   method rangeEquals(int,okio.ByteString)
[ERROR] location: variable source of type okio.BufferedSource
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/Util.java:[420,15]
 cannot find symbol
[ERROR] symbol:   method rangeEquals(int,okio.ByteString)
[ERROR] location: variable source of type okio.BufferedSource
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/Util.java:[424,15]
 cannot find symbol
[ERROR] symbol:   method rangeEquals(int,okio.ByteString)
[ERROR] location: variable source of type okio.BufferedSource
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/Util.java:[428,15]
 cannot find symbol
[ERROR] symbol:   method rangeEquals(int,okio.ByteString)
[ERROR] location: variable source of type okio.BufferedSource
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/CertificatePinner.java:[248,70]
 cannot find symbol
[ERROR] symbol:   method sha1()
[ERROR] location: class okio.ByteString
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/ws/WebSocketProtocol.java:[124,71]
 cannot find symbol
[ERROR] symbol:   method sha1()
[ERROR] location: class okio.ByteString
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/ws/RealWebSocket.java:[233,9]
 cannot find symbol
[ERROR] symbol:   method sha1()
[ERROR] location: class okio.ByteString
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/cache/DiskLruCache.java:[188,43]
 cannot find symbol
[ERROR] symbol:   method blackhole()
[ERROR] location: class okio.Okio
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/cache/DiskLruCache.java:[890,22]
 cannot find symbol
[ERROR] symbol:   method blackhole()
[ERROR] location: class okio.Okio
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/cache/DiskLruCache.java:[900,22]
 cannot find symbol
[ERROR] symbol:   method blackhole()
[ERROR] location: class okio.Okio
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/http2/Hpack.java:[511,24]
 cannot find symbol
[ERROR] symbol:   method startsWith(okio.ByteString)
[ERROR] location: variable name of type okio.ByteString
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/cache2/Relay.java:[266,20]
 cannot find symbol
[ERROR] symbol:   method waitUntilNotified(okhttp3.internal.cache2.Relay)
[ERROR] location: variable timeout of type okio.Timeout
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/platform/AndroidPlatform.java:[122,36]
 cannot find symbol
[ERROR] symbol:   variable Log
[ERROR] location: class okhttp3.internal.platform.AndroidPlatform
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/platform/AndroidPlatform.java:[122,47]
 cannot find symbol
[ERROR] symbol:   variable Log
[ERROR] location: class okhttp3.internal.platform.AndroidPlatform
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/platform/AndroidPlatform.java:[123,47]
 cannot find symbol
[ERROR] symbol:   variable Log
[ERROR] location: class okhttp3.internal.platform.AndroidPlatform
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/platform/AndroidPlatform.java:[131,9]
 cannot find symbol
[ERROR] symbol:   variable Log
[ERROR] location: class okht

can't compile okhttp-3.6.0 - AndroidPlatform.java:[18, 20] package android.util does not exist

2017-03-10 Thread Martin Gansser
I tried to compile the new version 3.6.0 of okhttp, itook the rpm spec file 
from http://pkgs.fedoraproject.org/cgit/rpms/okhttp.git/tree/okhttp.spec
and changed the version numbering.
my rpm spec file: 
https://martinkg.fedorapeople.org/Packages/okhttp3/okhttp-3.6.0.spec

But the compilation fails with this errors:

[ERROR] Failed to execute goal 
org.apache.maven.plugins:maven-compiler-plugin:3.5.1:compile (default-compile) 
on project okhttp: Compilation failure: Compilation failure:
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/platform/AndroidPlatform.java:[18,20]
 package android.util does not exist
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/Util.java:[412,15]
 cannot find symbol
[ERROR] symbol:   method rangeEquals(int,okio.ByteString)
[ERROR] location: variable source of type okio.BufferedSource
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/Util.java:[416,15]
 cannot find symbol
[ERROR] symbol:   method rangeEquals(int,okio.ByteString)
[ERROR] location: variable source of type okio.BufferedSource
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/Util.java:[420,15]
 cannot find symbol
[ERROR] symbol:   method rangeEquals(int,okio.ByteString)
[ERROR] location: variable source of type okio.BufferedSource
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/Util.java:[424,15]
 cannot find symbol
[ERROR] symbol:   method rangeEquals(int,okio.ByteString)
[ERROR] location: variable source of type okio.BufferedSource
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/Util.java:[428,15]
 cannot find symbol
[ERROR] symbol:   method rangeEquals(int,okio.ByteString)
[ERROR] location: variable source of type okio.BufferedSource
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/CertificatePinner.java:[248,70]
 cannot find symbol
[ERROR] symbol:   method sha1()
[ERROR] location: class okio.ByteString
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/ws/WebSocketProtocol.java:[124,71]
 cannot find symbol
[ERROR] symbol:   method sha1()
[ERROR] location: class okio.ByteString
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/ws/RealWebSocket.java:[233,9]
 cannot find symbol
[ERROR] symbol:   method sha1()
[ERROR] location: class okio.ByteString
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/cache/DiskLruCache.java:[188,43]
 cannot find symbol
[ERROR] symbol:   method blackhole()
[ERROR] location: class okio.Okio
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/cache/DiskLruCache.java:[890,22]
 cannot find symbol
[ERROR] symbol:   method blackhole()
[ERROR] location: class okio.Okio
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/cache/DiskLruCache.java:[900,22]
 cannot find symbol
[ERROR] symbol:   method blackhole()
[ERROR] location: class okio.Okio
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/http2/Hpack.java:[511,24]
 cannot find symbol
[ERROR] symbol:   method startsWith(okio.ByteString)
[ERROR] location: variable name of type okio.ByteString
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/cache2/Relay.java:[266,20]
 cannot find symbol
[ERROR] symbol:   method waitUntilNotified(okhttp3.internal.cache2.Relay)
[ERROR] location: variable timeout of type okio.Timeout
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/platform/AndroidPlatform.java:[122,36]
 cannot find symbol
[ERROR] symbol:   variable Log
[ERROR] location: class okhttp3.internal.platform.AndroidPlatform
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/platform/AndroidPlatform.java:[122,47]
 cannot find symbol
[ERROR] symbol:   variable Log
[ERROR] location: class okhttp3.internal.platform.AndroidPlatform
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/platform/AndroidPlatform.java:[123,47]
 cannot find symbol
[ERROR] symbol:   variable Log
[ERROR] location: class okhttp3.internal.platform.AndroidPlatform
[ERROR] 
/home/martin/rpmbuild/BUILD/okhttp-parent-3.6.0/okhttp/src/main/java/okhttp3/internal/platform/AndroidPlatform.java:[131,9]
 cannot find symbol
[ERROR] symbol:   variable Log
[ERROR] location: class okhttp3.internal.platform.AndroidPlatform
[ERROR] -> [Help 1]
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org