From b4d41b0561b6e8de38b99850ce0e4be8ef536bb1 Mon Sep 17 00:00:00 2001
From: Shane Carr <shane@unicode.org>
Date: Fri, 2 Aug 2019 16:25:15 -0700
Subject: [PATCH] ICU-20737 Removing Python dependency on distutils.

Deletes tstfiles.mk and merges the list into BUILDRULES.py
---
 icu4c/source/data/makedata.vcxproj         |  1 -
 icu4c/source/data/makedata.vcxproj.filters |  3 ---
 icu4c/source/data/makedata_uwp.vcxproj     |  1 -
 icu4c/source/test/testdata/BUILDRULES.py   | 24 ++++++++++------------
 icu4c/source/test/testdata/tstfiles.mk     | 12 -----------
 5 files changed, 11 insertions(+), 30 deletions(-)
 delete mode 100644 icu4c/source/test/testdata/tstfiles.mk

diff --git a/icu4c/source/data/makedata.vcxproj b/icu4c/source/data/makedata.vcxproj
index 8381142f393..89e07f62db7 100644
--- a/icu4c/source/data/makedata.vcxproj
+++ b/icu4c/source/data/makedata.vcxproj
@@ -93,7 +93,6 @@
     <None Include="locales\resfiles.mk" />
     <None Include="..\test\testdata\testdata.mak" />
     <None Include="translit\trnsfiles.mk" />
-    <None Include="..\test\testdata\tstfiles.mk" />
     <None Include="mappings\ucmcore.mk" />
     <None Include="mappings\ucmebcdic.mk" />
     <None Include="mappings\ucmfiles.mk" />
diff --git a/icu4c/source/data/makedata.vcxproj.filters b/icu4c/source/data/makedata.vcxproj.filters
index d37a4b28673..54bd3034bc1 100644
--- a/icu4c/source/data/makedata.vcxproj.filters
+++ b/icu4c/source/data/makedata.vcxproj.filters
@@ -35,9 +35,6 @@
     <None Include="translit\trnsfiles.mk">
       <Filter>Make Files</Filter>
     </None>
-    <None Include="..\test\testdata\tstfiles.mk">
-      <Filter>Make Files</Filter>
-    </None>
     <None Include="mappings\ucmcore.mk">
       <Filter>Make Files</Filter>
     </None>
diff --git a/icu4c/source/data/makedata_uwp.vcxproj b/icu4c/source/data/makedata_uwp.vcxproj
index 0b9965393d4..1385da467dd 100644
--- a/icu4c/source/data/makedata_uwp.vcxproj
+++ b/icu4c/source/data/makedata_uwp.vcxproj
@@ -124,7 +124,6 @@
     <None Include="locales\resfiles.mk" />
     <None Include="..\test\testdata\testdata.mak" />
     <None Include="translit\trnsfiles.mk" />
-    <None Include="..\test\testdata\tstfiles.mk" />
     <None Include="mappings\ucmcore.mk" />
     <None Include="mappings\ucmebcdic.mk" />
     <None Include="mappings\ucmfiles.mk" />
diff --git a/icu4c/source/test/testdata/BUILDRULES.py b/icu4c/source/test/testdata/BUILDRULES.py
index 47d3749c842..2a5eed8755c 100644
--- a/icu4c/source/test/testdata/BUILDRULES.py
+++ b/icu4c/source/test/testdata/BUILDRULES.py
@@ -1,8 +1,6 @@
 # Copyright (C) 2018 and later: Unicode, Inc. and others.
 # License & terms of use: http://www.unicode.org/copyright.html
 
-from distutils.sysconfig import parse_makefile
-
 from icutools.databuilder import *
 from icutools.databuilder.request_types import *
 
@@ -28,24 +26,24 @@ def generate(config, glob, common_vars):
 
 
 def generate_rb(config, glob, common_vars):
-    mk_vars = parse_makefile("{GLOB_DIR}/tstfiles.mk".format(**common_vars))
-    basenames = [v[:-4] for v in mk_vars["TEST_RES_SOURCE"].split()]
-    basenames += [
+    basenames = [
+        "calendar",
         "casing",
+        "conversion",
+        "format",
+        "icuio",
+        "idna_rules",
         "mc",
         "root",
-        "sh",
         "sh_YU",
-        "te",
-        "te_IN",
+        "sh",
+        "structLocale",
         "te_IN_REVISED",
-        "testtypes",
+        "te_IN",
+        "te",
         "testaliases",
         "testempty",
-        "structLocale",
-        "idna_rules",
-        "conversion",
-        "icuio",
+        "testtypes",
         # "metaZones",
         # "timezoneTypes",
         # "windowsZones",
diff --git a/icu4c/source/test/testdata/tstfiles.mk b/icu4c/source/test/testdata/tstfiles.mk
deleted file mode 100644
index a8a5d532302..00000000000
--- a/icu4c/source/test/testdata/tstfiles.mk
+++ /dev/null
@@ -1,12 +0,0 @@
-# Copyright (C) 2016 and later: Unicode, Inc. and others.
-# License & terms of use: http://www.unicode.org/copyright.html
-# Copyright (C) 2007-2014, International Business Machines Corporation and others.  All Rights Reserved.
-#
-# TEST_RES_SOURCE defines data driven tests and other resource files to be included with 
-# the testdata package. For ordinary resource bundles, they only need to be referenced here.
-#
-# Not everything has been moved to this file yet, as this is a new facility.
-#
-
-TEST_RES_SOURCE=calendar.txt format.txt
-
-- 
2.40.0