diff --git a/src/actions/xcode/xcode_common.lua b/src/actions/xcode/xcode_common.lua index 01cdb0c0..3c9d0611 100644 --- a/src/actions/xcode/xcode_common.lua +++ b/src/actions/xcode/xcode_common.lua @@ -232,28 +232,22 @@ function xcode.PBXContainerItemProxy(tr) _p('/* Begin PBXContainerItemProxy section */') for _, node in ipairs(tr.projects.children) do - _p(2,'%s /* PBXContainerItemProxy */ = {', node.remoteid) + _p(2,'%s /* PBXContainerItemProxy */ = {', node.productproxyid) _p(3,'isa = PBXContainerItemProxy;') _p(3,'containerPortal = %s /* %s */;', node.id, path.getname(node.path)) _p(3,'proxyType = 2;') _p(3,'remoteGlobalIDString = %s;', node.project.xcode.projectnode.id) _p(3,'remoteInfo = "%s";', node.project.xcode.projectnode.name) _p(2,'};') + _p(2,'%s /* PBXContainerItemProxy */ = {', node.targetproxyid) + _p(3,'isa = PBXContainerItemProxy;') + _p(3,'containerPortal = %s /* %s */;', node.id, path.getname(node.path)) + _p(3,'proxyType = 1;') + _p(3,'remoteGlobalIDString = %s;', node.project.xcode.projectnode.targetid) + _p(3,'remoteInfo = "%s";', node.project.xcode.projectnode.name) + _p(2,'};') end _p('/* End PBXContainerItemProxy section */') - ---[[ - remoteGlobalIDString = 7DF44AF45AB7001258659540; - remoteInfo = "libMyLibrary-d.a"; - }; - 967BE4EA10B5D6F200E9EC24 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 967BE4E010B5D6C900E9EC24 /* MyLibrary.xcodeproj */; - proxyType = 1; - remoteGlobalIDString = 4EE55BCC4CE5001258659540; - remoteInfo = "libMyLibrary-d.a"; - }; -]] end diff --git a/src/actions/xcode/xcode_project.lua b/src/actions/xcode/xcode_project.lua index e8c3270f..cf134635 100644 --- a/src/actions/xcode/xcode_project.lua +++ b/src/actions/xcode/xcode_project.lua @@ -84,7 +84,8 @@ local xcnode = tree.insert(tr.projects, tree.new(path.getname(xcpath))) xcnode.path = xcpath xcnode.project = dep - xcnode.remoteid = xcode.newid(xcnode, "remote") + xcnode.productproxyid = xcode.newid(xcnode, "prodprox") + xcnode.targetproxyid = xcode.newid(xcnode, "targprox") -- create a grandchild node for the dependency's link target local cfg = premake.getconfig(dep, prj.solution.configurations[1]) diff --git a/tests/actions/xcode/test_xcode_dependencies.lua b/tests/actions/xcode/test_xcode_dependencies.lua index 17e8da6e..a9cf1ba3 100644 --- a/tests/actions/xcode/test_xcode_dependencies.lua +++ b/tests/actions/xcode/test_xcode_dependencies.lua @@ -60,16 +60,16 @@ xcode.PBXContainerItemProxy(tr) test.capture [[ /* Begin PBXContainerItemProxy section */ - [MyProject2.xcodeproj:remote] /* PBXContainerItemProxy */ = { + [MyProject2.xcodeproj:prodprox] /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = [MyProject2.xcodeproj] /* MyProject2.xcodeproj */; proxyType = 2; remoteGlobalIDString = [libMyProject2-d.a:product]; remoteInfo = "libMyProject2-d.a"; }; - 967BE4EA10B5D6F200E9EC24 /* PBXContainerItemProxy */ = { + [MyProject2.xcodeproj:targprox] /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; - containerPortal = 967BE4E010B5D6C900E9EC24 /* MyLibrary.xcodeproj */; + containerPortal = [MyProject2.xcodeproj] /* MyProject2.xcodeproj */; proxyType = 1; remoteGlobalIDString = [libMyProject2-d.a:target]; remoteInfo = "libMyProject2-d.a";