Title: [245692] trunk/Tools
- Revision
- 245692
- Author
- [email protected]
- Date
- 2019-05-23 10:33:26 -0700 (Thu, 23 May 2019)
Log Message
generate-xcfilelists should not store temporary build files in /tmp
https://bugs.webkit.org/show_bug.cgi?id=198136
Reviewed by Jonathan Bedard.
Provide the build infrastructure control of the location of
generate-xcfilelists' temporary files by creating them in the build
directory when possible.
* Scripts/webkitpy/generate_xcfilelists_lib/application.py:
(get_xcode_project_temp_dir):
* Scripts/webkitpy/generate_xcfilelists_lib/generators.py:
(BaseGenerator._generate_derived):
(BaseGenerator._generate_unified):
(BaseGenerator):
(BaseGenerator._get_temp_dir):
Modified Paths
Diff
Modified: trunk/Tools/ChangeLog (245691 => 245692)
--- trunk/Tools/ChangeLog 2019-05-23 17:20:54 UTC (rev 245691)
+++ trunk/Tools/ChangeLog 2019-05-23 17:33:26 UTC (rev 245692)
@@ -1,3 +1,22 @@
+2019-05-23 Keith Rollin <[email protected]>
+
+ generate-xcfilelists should not store temporary build files in /tmp
+ https://bugs.webkit.org/show_bug.cgi?id=198136
+
+ Reviewed by Jonathan Bedard.
+
+ Provide the build infrastructure control of the location of
+ generate-xcfilelists' temporary files by creating them in the build
+ directory when possible.
+
+ * Scripts/webkitpy/generate_xcfilelists_lib/application.py:
+ (get_xcode_project_temp_dir):
+ * Scripts/webkitpy/generate_xcfilelists_lib/generators.py:
+ (BaseGenerator._generate_derived):
+ (BaseGenerator._generate_unified):
+ (BaseGenerator):
+ (BaseGenerator._get_temp_dir):
+
2019-05-23 Philippe Normand <[email protected]>
[JHBuild][GStreamer] Enable libsrtp
Modified: trunk/Tools/Scripts/webkitpy/generate_xcfilelists_lib/application.py (245691 => 245692)
--- trunk/Tools/Scripts/webkitpy/generate_xcfilelists_lib/application.py 2019-05-23 17:20:54 UTC (rev 245691)
+++ trunk/Tools/Scripts/webkitpy/generate_xcfilelists_lib/application.py 2019-05-23 17:33:26 UTC (rev 245692)
@@ -459,6 +459,11 @@
assert util.is_running_under_xcode()
return self._getenv("BUILT_PRODUCTS_DIR")
+ @util.LogEntryExit
+ def get_xcode_project_temp_dir(self):
+ assert util.is_running_under_xcode()
+ return self._getenv("PROJECT_TEMP_DIR")
+
# Return the named environment variable.
@util.LogEntryExit
def _getenv(self, variable_name):
Modified: trunk/Tools/Scripts/webkitpy/generate_xcfilelists_lib/generators.py (245691 => 245692)
--- trunk/Tools/Scripts/webkitpy/generate_xcfilelists_lib/generators.py 2019-05-23 17:20:54 UTC (rev 245691)
+++ trunk/Tools/Scripts/webkitpy/generate_xcfilelists_lib/generators.py 2019-05-23 17:33:26 UTC (rev 245692)
@@ -253,7 +253,8 @@
if not script:
return
- with tempfile.NamedTemporaryFile() as input, tempfile.NamedTemporaryFile() as output:
+ with tempfile.NamedTemporaryFile(dir=self._get_temp_dir()) as input, \
+ tempfile.NamedTemporaryFile(dir=self._get_temp_dir()) as output:
(stdout, stderr) = util.subprocess_run(
[script,
"NO_SUPPLEMENTAL_FILES=1",
@@ -308,7 +309,7 @@
if not script:
return
- with tempfile.NamedTemporaryFile() as output:
+ with tempfile.NamedTemporaryFile(dir=self._get_temp_dir()) as output:
# We need to define BUILD_SCRIPTS_DIR so that the bash script we're
# invoking can find the ruby script that it invokes. If we don't
@@ -641,7 +642,11 @@
def _get_generate_unified_sources_script(self):
return None
+ @util.LogEntryExit
+ def _get_temp_dir(self):
+ return self.application.get_xcode_project_temp_dir()
+
class _javascript_CoreGenerator(BaseGenerator):
VALID_PLATFORMS = ("macosx", "iosmac", "iphoneos", "iphonesimulator", "watchos", "watchsimulator")
VALID_CONFIGURATIONS = ("Debug", "Release", "Production", "Profiling")
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes