Uploaded image for project: 'Apache Cordova'
  1. Apache Cordova
  2. CB-9126

Fix ios pbxproj' resources paths when adding ios platform on non-OSX environment

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • None
    • cordova-lib
    • iOS

    Description

      Adding ios platform on Windows causes such build error on OSX:
      CpResource mobilespec/Resources/ResourcesCDVNotification.bundle build/emulator/mobilespec.app/ResourcesCDVNotification.bundle
      cd /Users/admin/Desktop/cordova5/mobilespec3/platforms/ios
      export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin"
      builtin-copy -exclude .DS_Store -exclude CVS -exclude .svn -exclude .git -exclude .hg -resolve-src-symlinks /Users/admin/Desktop/cordova5/mobilespec3/platforms/ios/mobilespec/Resources/ResourcesCDVNotification.bundle /Users/admin/Desktop/cordova5/mobilespec3/platforms/ios/build/emulator/mobilespec.app
      error: /Users/admin/Desktop/cordova5/mobilespec3/platforms/ios/mobilespec/Resources/ResourcesCDVNotification.bundle: No such file or directory

      This is caused by this node-xcode' code:

          var r_resources_dir = /^Resources\//;
      
          if (project.pbxGroupByName('Resources').path)
              file.path = file.path.replace(r_resources_dir, '');
          ...
      

      The regexp does not take backslash into account - this is fixed in node-xcode current version (0.7.0).

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              daserge Sergey Shakhnazarov
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: