7

I'm using Android-R8 and the following R8-warnings are present:

R8 warnings     
Missing class: javax.xml.stream.XMLStreamReader 
Missing class: javax.xml.stream.util.XMLEventAllocator  
Missing class: javax.xml.stream.events.Characters   
Missing class: javax.xml.stream.events.DTD  
Missing class: javax.xml.stream.XMLOutputFactory    
Missing class: javax.xml.stream.EventFilter 
Missing class: javax.xml.stream.events.Comment  
Missing class: javax.xml.stream.events.Attribute    
Missing class: javax.xml.stream.events.NotationDeclaration  
Missing class: javax.xml.stream.events.ProcessingInstruction    
Missing class: javax.xml.stream.events.EndElement   
Missing class: javax.xml.stream.events.StartDocument    
Missing class: javax.xml.stream.Location    
Missing class: javax.xml.stream.util.XMLEventConsumer   
Missing class: javax.xml.stream.events.EndDocument  
Missing class: javax.xml.stream.events.XMLEvent 
Missing class: javax.xml.stream.XMLInputFactory 
Missing class: javax.xml.stream.events.EntityDeclaration    
Missing class: javax.xml.stream.XMLEventWriter  
Missing class: javax.xml.stream.events.Namespace    
Missing class: javax.xml.stream.StreamFilter    
Missing class: javax.xml.stream.events.EntityReference  
Missing class: javax.xml.stream.events.StartElement 
Missing class: javax.xml.stream.XMLEventFactory 
Missing class: javax.xml.stream.XMLStreamWriter 
Missing class: javax.xml.stream.XMLEventReader 

The APK is successfully built but cannot be installed. Does anyone have similar problem ?

AceStan
  • 109
  • 1
  • 1
  • 7
  • not really a R8 question, because `javax` does not exist on Android. – Martin Zeitler Oct 21 '19 at 09:36
  • @MartinZeitler the problem is only present when I use R8, otherwise I haven't any problems – AceStan Oct 21 '19 at 09:39
  • 1
    This package won't exist in any other builds either, it is for desktop Java. The way ProGuard/R8 work is by mapping referenced class names - and when it cannot find them, this is a problem (even if one can add `-dontwarn javax.xml.stream.**`). Replacing it with anything Android Java might be rather proper... keeping all classes which reference these might also work, while these classes aren't used anywhere. – Martin Zeitler Oct 21 '19 at 09:45
  • @MartinZeitler, thanks, this made the things clearer – AceStan Oct 21 '19 at 09:53

0 Answers0