title: Xcode - Include of non-modular header inside framework module error when archiving project
body: <p>I'm currently trying to archive my project to finally update my app on the app store when I came across this issue. </p>
  
  <p>I'm getting this error on multiple files in the <a href="https://github.com/renebigot/XlsxReaderWriter" rel="nofollow noreferrer">XlsxReaderWriter</a> framework.</p>
  
  <p><code>Include of non-modular header inside framework module 'XlsxReaderWriter.BRARelationship': '/Users/dannyespina/Documents/iOS_Applications/LoanMaster/loan-master/Pods/XMLDictionary/XMLDictionary/XMLDictionary.h'</code></p>
  
  <p><a href="https://i.stack.imgur.com/wlFvN.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/wlFvN.png" alt="enter image description here"></a></p>
  
  <p><a href="https://i.stack.imgur.com/mfPK5.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/mfPK5.png" alt="enter image description here"></a></p>
  
  <p>I had issues with this framework in the past but unfortunately this is the only one of it's kind that writes to excel files. I had to makes some changes in order for it work as shown <a href="https://github.com/renebigot/XlsxReaderWriter/pull/44/files" rel="nofollow noreferrer">here</a>.</p>
  
  <p>I tried everything to fixed this such as:</p>
  
  <ul>
  <li>setting "Allow Non-modular Includes in Framework Modules" to YES to both the Pods project and LoanMaster</li>
  <li>Cleaning the project and deleting the derivedData a bunch of times</li>
  <li>Reinstalling Xcode.</li>
  <li>placing XMLDictionary.h as a public header as mentioned in one of the stack overflow answers</li>
  <li>Making sure that the framework is public </li>
  <li>Updated pods to the latest version (1.8.4)</li>
  </ul>
  
  <p>The strange thing is that I archive this project in the past with this framework with the same exact changes to it. The library hasn't been updated in 3 years so nothing new should had cause this. Is this an issue with the new version of Xcode? </p>
  
  <p>I really just want to update my app that I been working on for the past 6 months :(</p>
  
  <p>Any help will be amazing!</p>
  
  <hr>
  
  <p>Podfile</p>
  
  <pre><code># Uncomment the next line to define a global platform for your project
  platform :ios, '11.0'
  
  target 'LoanMaster' do
    # Comment the next line if you're not using Swift and don't want to use dynamic frameworks
    use_frameworks!
  
    # Pods for LoanMaster
    pod 'MPNumericTextField', '~&gt; 1.4.0'
    pod 'Charts', '~&gt; 3.2.1'
    pod 'LGButton'
    pod 'RealmSwift'
    pod 'SpreadsheetView'
    pod 'IQKeyboardManagerSwift'
    pod 'GoogleMobileAdsMediationMoPub'
    pod 'PersonalizedAdConsent'
    pod 'PopupDialog', '~&gt; 1.1'
    pod 'NVActivityIndicatorView'
    pod 'FBAudienceNetwork'
    pod 'Firebase/Core'
    pod 'Firebase/AdMob'
    pod 'XlsxReaderWriter', '~&gt; 1.0'
    pod 'M13Checkbox'
  
      post_install do |installer|
        installer.pods_project.targets.each do |target|
          if ['SpreadsheetView', 'IQKeyboardManagerSwift', 'NVActivityIndicatorView'].include? target.name
            target.build_configurations.each do |config|
              config.build_settings['SWIFT_VERSION'] = '4.0'
            end
          target.build_configurations.each do |config|
            config.build_settings['CLANG_WARN_DOCUMENTATION_COMMENTS'] = 'NO'
          end
        end
      end
    end
  
  end
  </code></pre>