Search Issue Tracker
Fixed in 5.5.0
Votes
0
Found in
3.0.0b5
Issue ID
369773
Regression
No
Unity uses absolute paths and not relative paths for storing build directory
To Reproduce:
1) Create a test project
2) Build the project in a subfolder of the project.
3) Now close that project, quit Unity
4) Clone the project folder.
5) Open and build again. The folder for the previous project is presented, not the current one.
Expected:
1. To use a path relative to the project folder when building.
2. If the path is not available, it should show open on the project folder by default.
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Articulation Body with 'Revolute' Joint Type has erratic behavior when Upper Limit is set to above 360
- WebGL Player fails to render Scene when Terrain with Detail Mesh is added and WebGPU Graphics API is used
- Inconsistent errors are logged when different types are passed into the Query "Q<>" method in UIToolkit and the ancestor VisualElement is null
- Crash on GetMaterialPropertyByIndex when opening a specific Scene
- Discrepancies in the styling are present when using a TSS file instead of a USS file in custom EditorWindow
monroe-e
Sep 13, 2016 23:43
@tessellation - I also have observed that this bug fix caused the issue you're referencing. The XCProject class assumes that it's receiving a full path, but now it might not. The core of the issue is that the OnPostProcessBuild method's path will be sent as a relative path (the second argument) if the build directory is underneath the project's top level directory, whereas before it was sent as a full path all the time. You can fix it like you did there, or fix it in the OnPostProcessBuild that creates the XCProject by modifying the path to be a full path.
tessellation
Aug 31, 2016 07:41
I believe this change broke the BuildPostProcess step in the UnityAds code that is currently in the Asset Store. My fix was to modify Line 68 of Standard Assets/Editor/UnityAds/XCodeEditor/XCProject.cs to be the following code:
if (Path.IsPathRooted(filePath))
this.projectRootPath = filePath;
else
this.projectRootPath = Path.GetFullPath(filePath);