File size: 376,151 Bytes
ca26373 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2231 2232 2233 2234 2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 2245 2246 2247 2248 2249 2250 2251 2252 2253 2254 2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 2283 2284 2285 2286 2287 2288 2289 2290 2291 2292 2293 2294 2295 2296 2297 2298 2299 2300 2301 2302 2303 2304 2305 2306 2307 2308 2309 2310 2311 2312 2313 2314 2315 2316 2317 2318 2319 2320 2321 2322 2323 2324 2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 2343 2344 2345 2346 2347 2348 2349 2350 2351 2352 2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 2380 2381 2382 2383 2384 2385 2386 2387 2388 2389 2390 2391 2392 2393 2394 2395 2396 2397 2398 2399 2400 2401 2402 2403 2404 2405 2406 2407 2408 2409 2410 2411 2412 2413 2414 2415 2416 2417 2418 2419 2420 2421 2422 2423 2424 2425 2426 2427 2428 2429 2430 2431 2432 2433 2434 2435 2436 2437 2438 2439 2440 2441 2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 2464 2465 2466 2467 2468 2469 2470 2471 2472 2473 2474 2475 2476 2477 2478 2479 2480 2481 2482 2483 2484 2485 2486 2487 2488 2489 2490 2491 2492 2493 2494 2495 2496 2497 2498 2499 2500 2501 2502 2503 2504 2505 2506 2507 2508 2509 2510 2511 2512 2513 2514 2515 2516 2517 2518 2519 2520 2521 2522 2523 2524 2525 2526 2527 2528 2529 2530 2531 2532 2533 2534 2535 2536 2537 2538 2539 2540 2541 2542 2543 2544 2545 2546 2547 2548 2549 2550 2551 2552 2553 2554 2555 2556 2557 2558 2559 2560 2561 2562 2563 2564 2565 2566 2567 2568 2569 2570 2571 2572 2573 2574 2575 2576 2577 2578 2579 2580 2581 2582 2583 2584 2585 2586 2587 2588 2589 2590 2591 2592 2593 2594 2595 2596 2597 2598 2599 2600 2601 2602 2603 2604 2605 2606 2607 2608 2609 2610 2611 2612 2613 2614 2615 2616 2617 2618 2619 2620 2621 2622 2623 2624 2625 2626 2627 2628 2629 2630 2631 2632 2633 2634 2635 2636 2637 2638 2639 2640 2641 2642 2643 2644 2645 2646 2647 2648 2649 2650 2651 2652 2653 2654 2655 2656 2657 2658 2659 2660 2661 2662 2663 2664 2665 2666 2667 2668 2669 2670 2671 2672 2673 2674 2675 2676 2677 2678 2679 2680 2681 2682 2683 2684 2685 2686 2687 2688 2689 2690 2691 2692 2693 2694 2695 2696 2697 2698 2699 2700 2701 2702 2703 2704 2705 2706 2707 2708 2709 2710 2711 2712 2713 2714 2715 2716 2717 2718 2719 2720 2721 2722 2723 2724 2725 2726 2727 2728 2729 2730 2731 2732 2733 2734 2735 2736 2737 2738 2739 2740 2741 2742 2743 2744 2745 2746 2747 2748 2749 2750 2751 2752 2753 2754 2755 2756 2757 2758 2759 2760 2761 2762 2763 2764 2765 2766 2767 2768 2769 2770 2771 2772 2773 2774 2775 2776 2777 2778 2779 2780 2781 2782 2783 2784 2785 2786 2787 2788 2789 2790 2791 2792 2793 2794 2795 2796 2797 2798 2799 2800 2801 2802 2803 2804 2805 2806 2807 2808 2809 2810 2811 2812 2813 2814 2815 2816 2817 2818 2819 2820 2821 2822 2823 2824 2825 2826 2827 2828 2829 2830 2831 2832 2833 2834 2835 2836 2837 2838 2839 2840 2841 2842 2843 2844 2845 2846 2847 2848 2849 2850 2851 2852 2853 2854 2855 2856 2857 2858 2859 2860 2861 2862 2863 2864 2865 2866 2867 2868 2869 2870 2871 2872 2873 2874 2875 2876 2877 2878 2879 2880 2881 2882 2883 2884 2885 2886 2887 2888 2889 2890 2891 2892 2893 2894 2895 2896 2897 2898 2899 2900 2901 2902 2903 2904 2905 2906 2907 2908 2909 2910 2911 2912 2913 2914 2915 2916 2917 2918 2919 2920 2921 2922 2923 2924 2925 2926 2927 2928 2929 2930 2931 2932 2933 2934 2935 2936 2937 2938 2939 2940 2941 2942 2943 2944 2945 2946 2947 2948 2949 2950 2951 2952 2953 2954 2955 2956 2957 2958 2959 2960 2961 2962 2963 2964 2965 2966 2967 2968 2969 2970 2971 2972 2973 2974 2975 2976 2977 2978 2979 2980 2981 2982 2983 2984 2985 2986 2987 2988 2989 2990 2991 2992 2993 2994 2995 2996 2997 2998 2999 3000 3001 3002 3003 3004 3005 3006 3007 3008 3009 3010 3011 3012 3013 3014 3015 3016 3017 3018 3019 3020 3021 3022 3023 3024 3025 3026 3027 3028 3029 3030 3031 3032 3033 3034 3035 3036 3037 3038 3039 3040 3041 3042 3043 3044 3045 3046 3047 3048 3049 3050 3051 3052 3053 3054 3055 3056 3057 3058 3059 3060 3061 3062 3063 3064 3065 3066 3067 3068 3069 3070 3071 3072 3073 3074 3075 3076 3077 3078 3079 3080 3081 3082 3083 3084 3085 3086 3087 3088 3089 3090 3091 3092 3093 3094 3095 3096 3097 3098 3099 3100 3101 3102 3103 3104 3105 3106 3107 3108 3109 3110 3111 3112 3113 3114 3115 3116 3117 3118 3119 3120 3121 3122 3123 3124 3125 3126 3127 3128 3129 3130 3131 3132 3133 3134 3135 3136 3137 3138 3139 3140 3141 3142 3143 3144 3145 3146 3147 3148 3149 3150 3151 3152 3153 3154 3155 3156 3157 3158 3159 3160 3161 3162 3163 3164 3165 3166 3167 3168 3169 3170 3171 3172 3173 3174 3175 3176 3177 3178 3179 3180 3181 3182 3183 3184 3185 3186 3187 3188 3189 3190 3191 3192 3193 3194 3195 3196 3197 3198 3199 3200 3201 3202 3203 3204 3205 3206 3207 3208 3209 3210 3211 3212 3213 3214 3215 3216 3217 3218 3219 3220 3221 3222 3223 3224 3225 3226 3227 3228 3229 3230 3231 3232 3233 3234 3235 3236 3237 3238 3239 3240 3241 3242 3243 3244 3245 3246 3247 3248 3249 3250 3251 3252 3253 3254 3255 3256 3257 3258 3259 3260 3261 3262 3263 3264 3265 3266 3267 3268 3269 3270 3271 3272 3273 3274 3275 3276 3277 3278 3279 3280 3281 3282 3283 3284 3285 3286 3287 3288 3289 3290 3291 3292 3293 3294 3295 3296 3297 3298 3299 3300 3301 3302 3303 3304 3305 3306 3307 3308 3309 3310 3311 3312 3313 3314 3315 3316 3317 3318 3319 3320 3321 3322 3323 3324 3325 3326 3327 3328 3329 3330 3331 3332 3333 3334 3335 3336 3337 3338 3339 3340 3341 3342 3343 3344 3345 3346 3347 3348 3349 3350 3351 3352 3353 3354 3355 3356 3357 3358 3359 3360 3361 3362 3363 3364 3365 3366 3367 3368 3369 3370 3371 3372 3373 3374 3375 3376 3377 3378 3379 3380 3381 3382 3383 3384 3385 3386 3387 3388 3389 3390 3391 3392 3393 3394 3395 3396 3397 3398 3399 3400 3401 3402 3403 3404 3405 3406 3407 3408 3409 3410 3411 3412 3413 3414 3415 3416 3417 3418 3419 3420 3421 3422 3423 3424 3425 3426 3427 3428 3429 3430 3431 3432 3433 3434 3435 3436 3437 3438 3439 3440 3441 3442 3443 3444 3445 3446 3447 3448 3449 3450 3451 3452 3453 3454 3455 3456 3457 3458 3459 3460 3461 3462 3463 3464 3465 3466 3467 3468 3469 3470 3471 3472 3473 3474 3475 3476 3477 3478 3479 3480 3481 3482 3483 3484 3485 3486 3487 3488 3489 3490 3491 3492 3493 3494 3495 3496 3497 3498 3499 3500 3501 3502 3503 3504 3505 3506 3507 3508 3509 3510 3511 3512 3513 3514 3515 3516 3517 3518 3519 3520 3521 3522 3523 3524 3525 3526 3527 3528 3529 3530 3531 3532 3533 3534 3535 3536 3537 3538 3539 3540 3541 3542 3543 3544 3545 3546 3547 3548 3549 3550 3551 3552 3553 3554 3555 3556 3557 3558 3559 3560 3561 3562 3563 3564 3565 3566 3567 3568 3569 3570 3571 3572 3573 3574 3575 3576 3577 3578 3579 3580 3581 3582 3583 3584 3585 3586 3587 3588 3589 3590 3591 3592 3593 3594 3595 3596 3597 3598 3599 3600 3601 3602 3603 3604 3605 3606 3607 3608 3609 3610 3611 3612 3613 3614 3615 3616 3617 3618 3619 3620 3621 3622 3623 3624 3625 3626 3627 3628 3629 3630 3631 3632 3633 3634 3635 3636 3637 3638 3639 3640 3641 3642 3643 3644 3645 3646 3647 3648 3649 3650 3651 3652 3653 3654 3655 3656 3657 3658 3659 3660 3661 3662 3663 3664 3665 3666 3667 3668 3669 3670 3671 3672 3673 3674 3675 3676 3677 3678 3679 3680 3681 3682 3683 3684 3685 3686 3687 3688 3689 3690 3691 3692 3693 3694 3695 3696 3697 3698 3699 3700 3701 3702 3703 3704 3705 3706 3707 3708 3709 3710 3711 3712 3713 3714 3715 3716 3717 3718 3719 3720 3721 3722 3723 3724 3725 3726 3727 3728 3729 3730 3731 3732 3733 3734 3735 3736 3737 3738 3739 3740 3741 3742 3743 3744 3745 3746 3747 3748 3749 3750 3751 3752 3753 3754 3755 3756 3757 3758 3759 3760 3761 3762 3763 3764 3765 3766 3767 3768 3769 3770 3771 3772 3773 3774 3775 3776 3777 3778 3779 3780 3781 3782 3783 3784 3785 3786 3787 3788 3789 3790 3791 3792 3793 3794 3795 3796 3797 3798 3799 3800 3801 3802 3803 3804 3805 3806 3807 3808 3809 3810 3811 3812 3813 3814 3815 3816 3817 3818 3819 3820 3821 3822 3823 3824 3825 3826 3827 3828 3829 3830 3831 3832 3833 3834 3835 3836 3837 3838 3839 3840 3841 3842 3843 3844 3845 3846 3847 3848 3849 3850 3851 3852 3853 3854 3855 3856 3857 3858 3859 3860 3861 3862 3863 3864 3865 3866 3867 3868 3869 3870 3871 3872 3873 3874 3875 3876 3877 3878 3879 3880 3881 3882 3883 3884 3885 3886 3887 3888 3889 3890 3891 3892 3893 3894 3895 3896 3897 3898 3899 3900 3901 3902 3903 3904 3905 3906 3907 3908 3909 3910 3911 3912 3913 3914 3915 3916 3917 3918 3919 3920 3921 3922 3923 3924 3925 3926 3927 3928 3929 3930 3931 3932 3933 3934 3935 3936 3937 3938 3939 3940 3941 3942 3943 3944 3945 3946 3947 3948 3949 3950 3951 3952 3953 3954 3955 3956 3957 3958 3959 3960 3961 3962 3963 3964 3965 3966 3967 3968 3969 3970 3971 3972 3973 3974 3975 3976 3977 3978 3979 3980 3981 3982 3983 3984 3985 3986 3987 3988 3989 3990 3991 3992 3993 3994 3995 3996 3997 3998 3999 4000 4001 4002 4003 4004 4005 4006 4007 4008 4009 4010 4011 4012 4013 4014 4015 4016 4017 4018 4019 4020 4021 4022 4023 4024 4025 4026 4027 4028 4029 4030 4031 4032 4033 4034 4035 4036 4037 4038 4039 4040 4041 4042 4043 4044 4045 4046 4047 4048 4049 4050 4051 4052 4053 4054 4055 4056 4057 4058 4059 4060 4061 4062 4063 4064 4065 4066 4067 4068 4069 4070 4071 4072 4073 4074 4075 4076 4077 4078 4079 4080 4081 4082 4083 4084 4085 4086 4087 4088 4089 4090 4091 4092 4093 4094 4095 4096 4097 4098 4099 4100 4101 4102 4103 4104 4105 4106 4107 4108 4109 4110 4111 4112 4113 4114 4115 4116 4117 4118 4119 4120 4121 4122 4123 4124 4125 4126 4127 4128 4129 4130 4131 4132 4133 4134 4135 4136 4137 4138 4139 4140 4141 4142 4143 4144 4145 4146 4147 4148 4149 4150 4151 4152 4153 4154 4155 4156 4157 4158 4159 4160 4161 4162 4163 4164 4165 4166 4167 4168 4169 4170 4171 4172 4173 4174 4175 4176 4177 4178 4179 4180 4181 4182 4183 4184 4185 4186 4187 4188 4189 4190 4191 4192 4193 4194 4195 4196 4197 4198 4199 4200 4201 4202 4203 4204 4205 4206 4207 4208 4209 4210 4211 4212 4213 4214 4215 4216 4217 4218 4219 4220 4221 4222 4223 4224 4225 4226 4227 4228 4229 4230 4231 4232 4233 4234 4235 4236 4237 4238 4239 4240 4241 4242 4243 4244 4245 4246 4247 4248 4249 4250 4251 4252 4253 4254 4255 4256 4257 4258 4259 4260 4261 4262 4263 4264 4265 4266 4267 4268 4269 4270 4271 4272 4273 4274 4275 4276 4277 4278 4279 4280 4281 4282 4283 4284 4285 4286 4287 4288 4289 4290 4291 4292 4293 4294 4295 4296 4297 4298 4299 4300 4301 4302 4303 4304 4305 4306 4307 4308 4309 4310 4311 4312 4313 4314 4315 4316 4317 4318 4319 4320 4321 4322 4323 4324 4325 4326 4327 4328 4329 4330 4331 4332 4333 4334 4335 4336 4337 4338 4339 4340 4341 4342 4343 4344 4345 4346 4347 4348 4349 4350 4351 4352 4353 4354 4355 4356 4357 4358 4359 4360 4361 4362 4363 4364 4365 4366 4367 4368 4369 4370 4371 4372 4373 4374 4375 4376 4377 4378 4379 4380 4381 4382 4383 4384 4385 4386 4387 4388 4389 4390 4391 4392 4393 4394 4395 4396 4397 4398 4399 4400 4401 4402 4403 4404 4405 4406 4407 4408 4409 4410 4411 4412 4413 4414 4415 4416 4417 4418 4419 4420 4421 4422 4423 4424 4425 4426 4427 4428 4429 4430 4431 4432 4433 4434 4435 4436 4437 4438 4439 4440 4441 4442 4443 4444 4445 4446 4447 4448 4449 4450 4451 4452 4453 4454 4455 4456 4457 4458 4459 4460 4461 4462 4463 4464 4465 4466 4467 4468 4469 4470 4471 4472 4473 4474 4475 4476 4477 4478 4479 4480 4481 4482 4483 4484 4485 4486 4487 4488 4489 4490 4491 4492 4493 4494 4495 4496 4497 4498 4499 4500 4501 4502 4503 4504 4505 4506 4507 4508 4509 4510 4511 4512 4513 4514 4515 4516 4517 4518 4519 4520 4521 4522 4523 4524 4525 4526 4527 4528 4529 4530 4531 4532 4533 4534 4535 4536 4537 4538 4539 4540 4541 4542 4543 4544 4545 4546 4547 4548 4549 4550 4551 4552 4553 4554 4555 4556 4557 4558 4559 4560 4561 4562 4563 4564 4565 4566 4567 4568 4569 4570 4571 4572 4573 4574 4575 4576 4577 4578 4579 4580 4581 4582 4583 4584 4585 4586 4587 4588 4589 4590 4591 4592 4593 4594 4595 4596 4597 4598 4599 4600 4601 4602 4603 4604 4605 4606 4607 4608 4609 4610 4611 4612 4613 4614 4615 4616 4617 4618 4619 4620 4621 4622 4623 4624 4625 4626 4627 4628 4629 4630 4631 4632 4633 4634 4635 4636 4637 4638 4639 4640 4641 4642 4643 4644 4645 4646 4647 4648 4649 4650 4651 4652 4653 4654 4655 4656 4657 4658 4659 4660 4661 4662 4663 4664 4665 4666 4667 4668 4669 4670 4671 4672 4673 4674 4675 4676 4677 4678 4679 4680 4681 4682 4683 4684 4685 4686 4687 4688 4689 4690 4691 4692 4693 4694 4695 4696 4697 4698 4699 4700 4701 4702 4703 4704 4705 4706 4707 4708 4709 4710 4711 4712 4713 4714 4715 4716 4717 4718 4719 4720 4721 4722 4723 4724 4725 4726 4727 4728 4729 4730 4731 4732 4733 4734 4735 4736 4737 4738 4739 4740 4741 4742 4743 4744 4745 4746 4747 4748 4749 4750 4751 4752 4753 4754 4755 4756 4757 4758 4759 4760 4761 4762 4763 4764 4765 4766 4767 4768 4769 4770 4771 4772 4773 4774 4775 4776 4777 4778 4779 4780 4781 4782 4783 4784 4785 4786 4787 4788 4789 4790 4791 4792 4793 4794 4795 4796 4797 4798 4799 4800 4801 4802 4803 4804 4805 4806 4807 4808 4809 4810 4811 4812 4813 4814 4815 4816 4817 4818 4819 4820 4821 4822 4823 4824 4825 4826 4827 4828 4829 4830 4831 4832 4833 4834 4835 4836 4837 4838 4839 4840 4841 4842 4843 4844 4845 4846 4847 4848 4849 4850 4851 4852 4853 4854 4855 4856 4857 4858 4859 4860 4861 4862 4863 4864 4865 4866 4867 4868 4869 4870 4871 4872 4873 4874 4875 4876 4877 4878 4879 4880 4881 4882 4883 4884 4885 4886 4887 4888 4889 4890 4891 4892 4893 4894 4895 4896 4897 4898 4899 4900 4901 4902 4903 4904 4905 4906 4907 4908 4909 4910 4911 4912 4913 4914 4915 4916 4917 4918 4919 4920 4921 4922 4923 4924 4925 4926 4927 4928 4929 4930 4931 4932 4933 4934 4935 4936 4937 4938 4939 4940 4941 4942 4943 4944 4945 4946 4947 4948 4949 4950 4951 4952 4953 4954 4955 4956 4957 4958 4959 4960 4961 4962 4963 4964 4965 4966 4967 4968 4969 4970 4971 4972 4973 4974 4975 4976 4977 4978 4979 4980 4981 4982 4983 4984 4985 4986 4987 4988 4989 4990 4991 4992 4993 4994 4995 4996 4997 4998 4999 5000 5001 5002 5003 5004 5005 5006 5007 5008 5009 5010 5011 5012 5013 5014 5015 5016 5017 5018 5019 5020 5021 5022 5023 5024 5025 5026 5027 5028 5029 5030 5031 5032 5033 5034 5035 5036 5037 5038 5039 5040 5041 5042 5043 5044 5045 5046 5047 5048 5049 5050 5051 5052 5053 5054 5055 5056 5057 5058 5059 5060 5061 5062 5063 5064 5065 5066 5067 5068 5069 5070 5071 5072 5073 5074 5075 5076 5077 5078 5079 5080 5081 5082 5083 5084 5085 5086 5087 5088 5089 5090 5091 5092 5093 5094 5095 5096 5097 5098 5099 5100 5101 5102 5103 5104 5105 5106 5107 5108 5109 5110 5111 5112 5113 5114 5115 5116 5117 5118 5119 5120 5121 5122 5123 5124 5125 5126 5127 5128 5129 5130 5131 5132 5133 5134 5135 5136 5137 5138 5139 5140 5141 5142 5143 5144 5145 5146 5147 5148 5149 5150 5151 5152 5153 5154 5155 5156 5157 5158 5159 5160 5161 5162 5163 5164 5165 5166 5167 5168 5169 5170 5171 5172 5173 5174 5175 5176 5177 5178 5179 5180 5181 5182 5183 5184 5185 5186 5187 5188 5189 5190 5191 5192 5193 5194 5195 5196 5197 5198 5199 5200 5201 5202 5203 5204 5205 5206 5207 5208 5209 5210 5211 5212 5213 5214 5215 5216 5217 5218 5219 5220 5221 5222 5223 5224 5225 5226 5227 5228 5229 5230 5231 5232 5233 5234 5235 5236 5237 5238 5239 5240 5241 5242 5243 5244 5245 5246 5247 5248 5249 5250 5251 5252 5253 5254 5255 5256 5257 5258 5259 5260 5261 5262 5263 5264 5265 5266 5267 5268 5269 5270 5271 5272 5273 5274 5275 5276 5277 5278 5279 5280 5281 5282 5283 5284 5285 5286 5287 5288 5289 5290 5291 5292 5293 5294 5295 5296 5297 5298 5299 5300 5301 5302 5303 5304 5305 5306 5307 5308 5309 5310 5311 5312 5313 5314 5315 5316 5317 5318 5319 5320 5321 5322 5323 5324 5325 5326 5327 5328 5329 5330 5331 5332 5333 5334 5335 5336 5337 5338 5339 5340 5341 5342 5343 5344 5345 5346 5347 5348 5349 5350 5351 5352 5353 5354 5355 5356 5357 5358 5359 5360 5361 5362 5363 5364 5365 5366 5367 5368 5369 5370 5371 5372 5373 5374 5375 5376 5377 5378 5379 5380 5381 5382 5383 5384 5385 5386 5387 5388 5389 5390 5391 5392 5393 5394 5395 5396 5397 5398 5399 5400 5401 5402 5403 5404 5405 5406 5407 5408 5409 5410 5411 5412 5413 5414 5415 5416 5417 5418 5419 5420 5421 5422 5423 5424 5425 5426 5427 5428 5429 5430 5431 5432 5433 5434 5435 5436 5437 5438 5439 5440 5441 5442 5443 5444 5445 5446 5447 5448 5449 5450 5451 5452 5453 5454 5455 5456 5457 5458 5459 5460 5461 5462 5463 5464 5465 5466 5467 5468 5469 5470 5471 5472 5473 5474 5475 5476 5477 5478 5479 5480 5481 5482 5483 5484 5485 5486 5487 5488 5489 5490 5491 5492 5493 5494 5495 5496 5497 5498 5499 5500 5501 5502 5503 5504 5505 5506 5507 5508 5509 5510 5511 5512 5513 5514 5515 5516 5517 5518 5519 5520 5521 5522 5523 5524 5525 5526 5527 5528 5529 5530 5531 5532 5533 5534 5535 5536 5537 5538 5539 5540 5541 5542 5543 5544 5545 5546 5547 5548 5549 5550 5551 5552 5553 5554 5555 5556 5557 5558 5559 5560 5561 5562 5563 5564 5565 5566 5567 5568 5569 5570 5571 5572 5573 5574 5575 5576 5577 5578 5579 5580 5581 5582 5583 5584 5585 5586 5587 5588 5589 5590 5591 5592 5593 5594 5595 5596 5597 5598 5599 5600 5601 5602 5603 5604 5605 5606 5607 5608 5609 5610 5611 5612 5613 5614 5615 5616 5617 5618 5619 5620 5621 5622 5623 5624 5625 5626 5627 5628 5629 5630 5631 5632 5633 5634 5635 5636 5637 5638 5639 5640 5641 5642 5643 5644 5645 5646 5647 5648 5649 5650 5651 5652 5653 5654 5655 5656 5657 5658 5659 5660 5661 5662 5663 5664 5665 5666 5667 5668 5669 5670 5671 5672 5673 5674 5675 5676 5677 5678 5679 5680 5681 5682 5683 5684 5685 5686 5687 5688 5689 5690 5691 5692 5693 5694 5695 5696 5697 5698 5699 5700 5701 5702 5703 5704 5705 5706 5707 5708 5709 5710 5711 5712 5713 5714 5715 5716 5717 5718 5719 5720 5721 5722 5723 5724 5725 5726 5727 5728 5729 5730 5731 5732 5733 5734 5735 5736 5737 5738 5739 5740 5741 5742 5743 5744 5745 5746 5747 5748 5749 5750 5751 5752 5753 5754 5755 5756 5757 5758 5759 5760 5761 5762 5763 5764 5765 5766 5767 5768 5769 5770 5771 5772 5773 5774 5775 5776 5777 5778 5779 5780 5781 5782 5783 5784 5785 5786 5787 5788 5789 5790 5791 5792 5793 5794 5795 5796 5797 5798 5799 5800 5801 5802 5803 5804 5805 5806 5807 5808 5809 5810 5811 5812 5813 5814 5815 5816 5817 5818 5819 5820 5821 5822 5823 5824 5825 5826 5827 5828 5829 5830 5831 5832 5833 5834 5835 5836 5837 5838 5839 5840 5841 5842 5843 5844 5845 5846 5847 5848 5849 5850 5851 5852 5853 5854 5855 5856 5857 5858 5859 5860 5861 5862 5863 5864 5865 5866 5867 5868 5869 5870 5871 5872 5873 5874 5875 5876 5877 5878 5879 5880 5881 5882 5883 5884 5885 5886 5887 5888 5889 5890 5891 5892 5893 5894 5895 5896 5897 5898 5899 5900 5901 5902 5903 5904 5905 5906 5907 5908 5909 5910 5911 5912 5913 5914 5915 5916 5917 5918 5919 5920 5921 5922 5923 5924 5925 5926 5927 5928 5929 5930 5931 5932 5933 5934 5935 5936 5937 5938 5939 5940 5941 5942 5943 5944 5945 5946 5947 5948 5949 5950 5951 5952 5953 5954 5955 5956 5957 5958 5959 5960 5961 5962 5963 5964 5965 5966 5967 5968 5969 5970 5971 5972 5973 5974 5975 5976 5977 5978 5979 5980 5981 5982 5983 5984 5985 5986 5987 5988 5989 5990 5991 5992 5993 5994 5995 5996 5997 5998 5999 6000 6001 6002 6003 6004 6005 6006 6007 6008 6009 6010 6011 6012 6013 6014 6015 6016 6017 6018 6019 6020 6021 6022 6023 6024 6025 6026 6027 6028 6029 6030 6031 6032 6033 6034 6035 6036 6037 6038 6039 6040 6041 6042 6043 6044 6045 6046 6047 6048 6049 6050 6051 6052 6053 6054 6055 6056 6057 6058 6059 6060 6061 6062 6063 6064 6065 6066 6067 6068 6069 6070 6071 6072 6073 6074 6075 6076 6077 6078 6079 6080 6081 6082 6083 6084 6085 6086 6087 6088 6089 6090 6091 6092 6093 6094 6095 6096 6097 6098 6099 6100 6101 6102 6103 6104 6105 6106 6107 6108 6109 6110 6111 6112 6113 6114 6115 6116 6117 6118 6119 6120 6121 6122 6123 6124 6125 6126 6127 6128 6129 6130 6131 6132 6133 6134 6135 6136 6137 6138 6139 6140 6141 6142 6143 6144 6145 6146 6147 6148 6149 6150 6151 6152 6153 6154 6155 6156 6157 6158 6159 6160 6161 6162 6163 6164 6165 6166 6167 6168 6169 6170 6171 6172 6173 6174 6175 6176 6177 6178 6179 6180 6181 6182 6183 6184 6185 6186 6187 6188 6189 6190 6191 6192 6193 6194 6195 6196 6197 6198 6199 6200 6201 6202 6203 6204 6205 6206 6207 6208 6209 6210 6211 6212 6213 6214 6215 6216 6217 6218 6219 6220 6221 6222 6223 6224 6225 6226 6227 6228 6229 6230 6231 6232 6233 6234 6235 6236 6237 6238 6239 6240 6241 6242 6243 6244 6245 6246 6247 6248 6249 6250 6251 6252 6253 6254 6255 6256 6257 6258 6259 6260 6261 6262 6263 6264 6265 6266 6267 6268 6269 6270 6271 6272 6273 6274 6275 6276 6277 6278 6279 6280 6281 6282 6283 6284 6285 6286 6287 6288 6289 6290 6291 6292 6293 6294 6295 6296 6297 6298 6299 6300 6301 6302 6303 6304 6305 6306 6307 6308 6309 6310 6311 6312 6313 6314 6315 6316 6317 6318 6319 6320 6321 6322 6323 6324 6325 6326 6327 6328 6329 6330 6331 6332 6333 6334 6335 6336 6337 6338 6339 6340 6341 6342 6343 6344 6345 6346 6347 6348 6349 6350 6351 6352 6353 6354 6355 6356 6357 6358 6359 6360 6361 6362 6363 6364 6365 6366 6367 6368 6369 6370 6371 6372 6373 6374 6375 6376 6377 6378 6379 6380 6381 6382 6383 6384 6385 6386 6387 6388 6389 6390 6391 6392 6393 6394 6395 6396 6397 6398 6399 6400 6401 6402 6403 6404 6405 6406 6407 6408 6409 6410 6411 6412 6413 6414 6415 6416 6417 6418 6419 6420 6421 6422 6423 6424 6425 6426 6427 6428 6429 6430 6431 6432 6433 6434 6435 6436 6437 6438 6439 6440 6441 6442 6443 6444 6445 6446 6447 6448 6449 6450 6451 6452 6453 6454 6455 6456 6457 6458 6459 6460 6461 6462 6463 6464 6465 6466 6467 6468 6469 6470 6471 6472 6473 6474 6475 6476 6477 6478 6479 6480 6481 6482 6483 6484 6485 6486 6487 6488 6489 6490 6491 6492 6493 6494 6495 6496 6497 6498 6499 6500 6501 6502 6503 6504 6505 6506 6507 6508 6509 6510 6511 6512 6513 6514 6515 6516 6517 6518 6519 6520 6521 6522 6523 6524 6525 6526 6527 6528 6529 6530 6531 6532 6533 6534 6535 6536 6537 6538 6539 6540 6541 6542 6543 6544 6545 6546 6547 6548 6549 6550 6551 6552 6553 6554 6555 6556 6557 6558 6559 6560 6561 6562 6563 6564 6565 6566 6567 6568 6569 6570 6571 6572 6573 6574 6575 6576 6577 6578 6579 6580 6581 6582 6583 6584 6585 6586 6587 6588 6589 6590 6591 6592 6593 6594 6595 6596 6597 6598 6599 6600 6601 6602 6603 6604 6605 6606 6607 6608 6609 6610 6611 6612 6613 6614 6615 6616 6617 6618 6619 6620 6621 6622 6623 6624 6625 6626 6627 6628 6629 6630 6631 6632 6633 6634 6635 6636 6637 6638 6639 6640 6641 6642 6643 6644 6645 6646 6647 6648 6649 6650 6651 6652 6653 6654 6655 6656 6657 6658 6659 6660 6661 6662 6663 6664 6665 6666 6667 6668 6669 6670 6671 6672 6673 6674 6675 6676 6677 6678 6679 6680 6681 6682 6683 6684 6685 6686 6687 6688 6689 6690 6691 6692 6693 6694 6695 6696 6697 6698 6699 6700 6701 6702 6703 6704 6705 6706 6707 6708 6709 6710 6711 6712 6713 6714 6715 6716 6717 6718 6719 6720 6721 6722 6723 6724 6725 6726 6727 6728 6729 6730 6731 6732 6733 6734 6735 6736 6737 6738 6739 6740 6741 6742 6743 6744 6745 6746 6747 6748 6749 6750 6751 6752 6753 6754 6755 6756 6757 6758 6759 6760 6761 6762 6763 6764 6765 6766 6767 6768 6769 6770 6771 6772 6773 6774 6775 6776 6777 6778 6779 6780 6781 6782 6783 6784 6785 6786 6787 6788 6789 6790 6791 6792 6793 6794 6795 6796 6797 6798 6799 6800 6801 6802 6803 6804 6805 6806 6807 6808 6809 6810 6811 6812 6813 6814 6815 6816 6817 6818 6819 6820 6821 6822 6823 6824 6825 6826 6827 6828 6829 6830 6831 6832 6833 6834 6835 6836 6837 6838 6839 6840 6841 6842 6843 6844 6845 6846 6847 6848 6849 6850 6851 6852 6853 6854 6855 6856 6857 6858 6859 6860 | <!--
***********************************************************************************************
Microsoft.Common.CurrentVersion.targets
WARNING: DO NOT MODIFY this file unless you are knowledgeable about MSBuild and have
created a backup copy. Incorrect changes to this file will make it
impossible to load or build your projects from the command-line or the IDE.
This file defines the steps in the standard build process for .NET projects. It
contains all the steps that are common among the different .NET languages, such as
Visual Basic, and Visual C#.
Copyright (C) Microsoft Corporation. All rights reserved.
***********************************************************************************************
-->
<Project DefaultTargets="Build" TreatAsLocalProperty="OutDir">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="'$(MicrosoftCommonPropsHasBeenImported)' != 'true' and Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<ImportByWildcardBeforeMicrosoftCommonTargets Condition="'$(ImportByWildcardBeforeMicrosoftCommonTargets)' == ''">true</ImportByWildcardBeforeMicrosoftCommonTargets>
<ImportByWildcardAfterMicrosoftCommonTargets Condition="'$(ImportByWildcardAfterMicrosoftCommonTargets)' == ''">true</ImportByWildcardAfterMicrosoftCommonTargets>
<ImportUserLocationsByWildcardBeforeMicrosoftCommonTargets Condition="'$(ImportUserLocationsByWildcardBeforeMicrosoftCommonTargets)' == ''">true</ImportUserLocationsByWildcardBeforeMicrosoftCommonTargets>
<ImportUserLocationsByWildcardAfterMicrosoftCommonTargets Condition="'$(ImportUserLocationsByWildcardAfterMicrosoftCommonTargets)' == ''">true</ImportUserLocationsByWildcardAfterMicrosoftCommonTargets>
</PropertyGroup>
<Import Project="$(MSBuildUserExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.targets\ImportBefore\*" Condition="'$(ImportUserLocationsByWildcardBeforeMicrosoftCommonTargets)' == 'true' and exists('$(MSBuildUserExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.targets\ImportBefore')"/>
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.targets\ImportBefore\*" Condition="'$(ImportByWildcardBeforeMicrosoftCommonTargets)' == 'true' and exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.targets\ImportBefore')"/>
<Import Project="$(MSBuildProjectFullPath).user" Condition="Exists('$(MSBuildProjectFullPath).user')"/>
<!-- VS10 without SP1 and without VS11 will not have VisualStudioVersion set, so do that here -->
<PropertyGroup>
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">10.0</VisualStudioVersion>
</PropertyGroup>
<PropertyGroup>
<CustomBeforeMicrosoftCommonTargets Condition="'$(CustomBeforeMicrosoftCommonTargets)'==''">$(MSBuildExtensionsPath)\v$(MSBuildToolsVersion)\Custom.Before.Microsoft.Common.targets</CustomBeforeMicrosoftCommonTargets>
<CustomAfterMicrosoftCommonTargets Condition="'$(CustomAfterMicrosoftCommonTargets)'==''">$(MSBuildExtensionsPath)\v$(MSBuildToolsVersion)\Custom.After.Microsoft.Common.targets</CustomAfterMicrosoftCommonTargets>
<ReportingServicesTargets Condition="'$(ReportingServicesTargets)'==''">$(MSBuildExtensionsPath)\Microsoft\VisualStudio\v$(VisualStudioVersion)\ReportingServices\Microsoft.ReportingServices.targets</ReportingServicesTargets>
</PropertyGroup>
<Import Project="$(CustomBeforeMicrosoftCommonTargets)" Condition="'$(CustomBeforeMicrosoftCommonTargets)' != '' and Exists('$(CustomBeforeMicrosoftCommonTargets)')"/>
<!-- By default, we are creating a managed app because .NET 2.0 projects did not have this property. -->
<PropertyGroup Condition="'$(TargetRuntime)' == ''">
<TargetRuntime>Managed</TargetRuntime>
</PropertyGroup>
<!-- Because .NET 2.0 apps did not set TargetFrameworkIdentifier, we need to set it for them here by default. If
the runtime is set to Managed, we also need to set these. Otherwise they should be blank (for instance Javascript or
Native apps) because they do not target a .NET Framework. -->
<PropertyGroup Condition="'$(TargetRuntime)' == 'Managed'">
<TargetFrameworkIdentifier Condition="'$(TargetFrameworkIdentifier)' == ''">.NETFramework</TargetFrameworkIdentifier>
<TargetFrameworkVersion Condition=" '$(TargetFrameworkVersion)' == '' ">v4.0</TargetFrameworkVersion>
</PropertyGroup>
<!-- AvailablePlatforms is the list of platform targets available. -->
<PropertyGroup>
<AvailablePlatforms Condition="'$(VisualStudioVersion)' == '10.0' or '$(VisualStudioVersion)' == ''">Any CPU,x86,x64,Itanium</AvailablePlatforms>
<AvailablePlatforms Condition="'$(VisualStudioVersion)' != '' and '$(VisualStudioVersion)' > '10.0'">Any CPU,x86,x64</AvailablePlatforms>
</PropertyGroup>
<!-- Import depends on if it is .NETCore. Imports for .NETFramework is a superset of that for .NETCore-->
<Import Project="Microsoft.NETFramework.props" Condition="'$(TargetFrameworkIdentifier)' == '.NETFramework' or '$(TargetFrameworkIdentifier)' == 'Silverlight'"/>
<Import Project="Microsoft.NET.props" Condition="'$(TargetFrameworkIdentifier)' == '.NETStandard' or '$(TargetFrameworkIdentifier)' == '.NETCoreApp'"/>
<PropertyGroup>
<!-- Generates full paths for the 'File' property in errors, warnings and messages in many targets -->
<GenerateFullPaths Condition="'$(GenerateFullPaths)' == ''">true</GenerateFullPaths>
<!-- Yield optimization properties -->
<YieldDuringToolExecution Condition="'$(YieldDuringToolExecution)' == ''">true</YieldDuringToolExecution>
</PropertyGroup>
<PropertyGroup Condition="'$(TargetFrameworkIdentifier)' != '' and '$(TargetFrameworkVersion)' != ''">
<TargetFrameworkMoniker Condition="'$(TargetFrameworkMoniker)' == '' and '$([System.String]::IsNullOrWhitespace($(TargetFrameworkProfile)))' != 'true'">$(TargetFrameworkIdentifier),Version=$(TargetFrameworkVersion),Profile=$(TargetFrameworkProfile)</TargetFrameworkMoniker>
<TargetFrameworkMoniker Condition="'$(TargetFrameworkMoniker)' == ''">$(TargetFrameworkIdentifier),Version=$(TargetFrameworkVersion)</TargetFrameworkMoniker>
<!-- When working off a packaged reference assemblies, do not go to machine-global locations. This property is target-framework-specific, so it cannot be overridden in msbuild.exe.config once and for all. -->
<FrameworkPathOverride Condition="'$(EnableFrameworkPathOverride)' != 'false' And '$(FrameworkPathOverride)' == '' And Exists('$(TargetFrameworkRootPath)$(TargetFrameworkIdentifier)\$(TargetFrameworkVersion)')">$(TargetFrameworkRootPath)$(TargetFrameworkIdentifier)\$(TargetFrameworkVersion)</FrameworkPathOverride>
<!-- The FrameworkPathOverride is required for the inproc visual basic compiler to initialize when targeting target frameworks less than 4.0. If .net 2.0 is not installed then the property value above will not provide the location
of mscorlib. This is also true if the build author overrides this property to some other directory which does not contain mscorlib.dll. In the case we cannot find mscorlib.dll at the correct location
we need to find a directory which does contain mscorlib to allow the inproc compiler to initialize and give us the chance to show certain dialogs in the IDE (which only happen after initialization).-->
<FrameworkPathOverride Condition="'$(EnableFrameworkPathOverride)' != 'false' And '$(FrameworkPathOverride)' == ''">$([Microsoft.Build.Utilities.ToolLocationHelper]::GetPathToStandardLibraries($(TargetFrameworkIdentifier), $(TargetFrameworkVersion), $(TargetFrameworkProfile), $(PlatformTarget), $(TargetFrameworkRootPath), $(TargetFrameworkFallbackSearchPaths)))</FrameworkPathOverride>
<FrameworkPathOverride Condition="'$(EnableFrameworkPathOverride)' != 'false' And !Exists('$(FrameworkPathOverride)\mscorlib.dll')">$(MSBuildFrameworkToolsPath)</FrameworkPathOverride>
</PropertyGroup>
<PropertyGroup>
<TargetPlatformIdentifier Condition="'$(TargetPlatformIdentifier)' == '' and '$(_EnableDefaultWindowsPlatform)' != 'false'">Windows</TargetPlatformIdentifier>
<TargetPlatformVersion Condition="'$(TargetPlatformVersion)' == '' and '$(_EnableDefaultWindowsPlatform)' != 'false'">7.0</TargetPlatformVersion>
<TargetPlatformSdkPath Condition="'$(TargetPlatformSdkPath)' == '' and '$(TargetPlatformSdkRootOverride)' != ''">$(TargetPlatformSdkRootOverride)\</TargetPlatformSdkPath>
<TargetPlatformSdkPath Condition="'$(TargetPlatformSdkPath)' == '' and '$(TargetPlatformIdentifier)' == 'Windows' and $([MSBuild]::IsOSPlatform('Windows')) and '$(MSBuildRuntimeType)' != 'Core'">$([MSBuild]::GetRegistryValueFromView('HKEY_LOCAL_MACHINE\Software\Microsoft\Microsoft SDKs\Windows\v$(TargetPlatformVersion)', InstallationFolder, null, RegistryView.Registry32, RegistryView.Default))</TargetPlatformSdkPath>
<TargetPlatformSdkPath Condition="'$(TargetPlatformSdkPath)' == ''">$([Microsoft.Build.Utilities.ToolLocationHelper]::GetPlatformSDKLocation($(TargetPlatformIdentifier), $(TargetPlatformVersion)))</TargetPlatformSdkPath>
<TargetPlatformSdkMetadataLocation Condition="'$(TargetPlatformSdkMetadataLocation)' == '' and Exists('$(TargetPlatformSdkPath)')">$(TargetPlatformSdkPath)Windows Metadata</TargetPlatformSdkMetadataLocation>
<TargetPlatformSdkMetadataLocation Condition="Exists('$(TargetPlatformSdkPath)') and ('$(TargetPlatformSdkMetadataLocation)' == '' or !Exists('$(TargetPlatformSdkMetadataLocation)'))">$(TargetPlatformSdkPath)References\CommonConfiguration\Neutral</TargetPlatformSdkMetadataLocation>
<TargetPlatformWinMDLocation Condition="'$(TargetPlatformWinMDLocation)' == '' and Exists('$(TargetPlatformSdkMetadataLocation)')">$(TargetPlatformSdkMetadataLocation)</TargetPlatformWinMDLocation>
<UseOSWinMdReferences Condition="'$(UseOSWinMdReferences)' == '' and ('$(TargetPlatformWinMDLocation)' == '' and '$(TargetPlatformIdentifier)' == 'Windows' and '$(TargetPlatformVersion)' > '7.0')">true</UseOSWinMdReferences>
<TargetPlatformWinMDLocation Condition="'$(UseOsWinMdReferences)' == 'true'">$(WinDir)\System32\WinMetadata</TargetPlatformWinMDLocation>
<TargetPlatformMoniker Condition="'$(TargetPlatformMoniker)' == '' and '$(TargetPlatformIdentifier)' != '' and '$(TargetPlatformVersion)' != ''">$(TargetPlatformIdentifier),Version=$(TargetPlatformVersion)</TargetPlatformMoniker>
<TargetPlatformDisplayName Condition="'$(TargetPlatformDisplayName)' == ''">$([Microsoft.Build.Utilities.ToolLocationHelper]::GetPlatformSDKDisplayName($(TargetPlatformIdentifier), $(TargetPlatformVersion)))</TargetPlatformDisplayName>
</PropertyGroup>
<!--
Several properties must be set in the main project file, before using this .TARGETS file.
However, if the properties are not set, we pick some defaults.
OutDir:
Indicates the final output location for the project or solution. When building a solution,
OutDir can be used to gather multiple project outputs in one location. In addition,
OutDir is included in AssemblySearchPaths used for resolving references.
BaseOutputPath:
This is the top level folder where all configuration specific output folders will be created.
Default value is bin\
OutputPath:
This is the full Output Path, and is derived from BaseOutputPath, if none specified
(eg. bin\Debug). If this property is overridden, then setting BaseOutputPath has no effect.
For Legacy projects using only Common targets, this property is usually specified in the project file
and is used to initialize OutDir. Some SDKs including the .NET SDK derive this automatically.
OutDir and OutputPath are distinguished for legacy reasons, and OutDir should be used if at all possible.
BaseIntermediateOutputPath:
This is the top level folder where all configuration specific intermediate output folders will be created.
Default value is obj\
IntermediateOutputPath:
This is the full intermediate Output Path, and is derived from BaseIntermediateOutputPath, if none specified
(eg. obj\Debug). If this property is overridden, then setting BaseIntermediateOutputPath has no effect.
Ensure any and all path property has a trailing slash, so it can be concatenated.
-->
<PropertyGroup>
<!-- Example, AnyCPU -->
<_OriginalPlatform>$(Platform)</_OriginalPlatform>
<!-- Example, Debug -->
<_OriginalConfiguration>$(Configuration)</_OriginalConfiguration>
<!-- Check whether OutputPath was specified for valid Configuration/Platform combination -->
<_OutputPathWasMissing Condition="'$(_OriginalPlatform)' != '' and '$(_OriginalConfiguration)' != '' and '$(OutputPath)' == ''">true</_OutputPathWasMissing>
<!-- Check whether BaseOutputPath was specified -->
<BaseOutputPathWasSpecified Condition="'$(BaseOutputPath)' != ''">true</BaseOutputPathWasSpecified>
</PropertyGroup>
<PropertyGroup>
<Platform Condition="'$(Platform)' == ''">AnyCPU</Platform>
<PlatformName Condition="'$(PlatformName)' == ''">$(Platform)</PlatformName>
<Configuration Condition="'$(Configuration)' == ''">Debug</Configuration>
<ConfigurationName Condition="'$(ConfigurationName)' == ''">$(Configuration)</ConfigurationName>
<BaseOutputPath Condition="'$(BaseOutputPath)' == ''">bin\</BaseOutputPath>
<BaseOutputPath Condition="!HasTrailingSlash('$(BaseOutputPath)')">$(BaseOutputPath)\</BaseOutputPath>
<OutputPath Condition="'$(OutputPath)' == '' and '$(PlatformName)' == 'AnyCPU'">$(BaseOutputPath)$(Configuration)\</OutputPath>
<OutputPath Condition="'$(OutputPath)' == '' and '$(PlatformName)' != 'AnyCPU'">$(BaseOutputPath)$(PlatformName)\$(Configuration)\</OutputPath>
<OutputPath Condition="!HasTrailingSlash('$(OutputPath)')">$(OutputPath)\</OutputPath>
<BaseIntermediateOutputPath Condition="'$(BaseIntermediateOutputPath)' == ''">obj\</BaseIntermediateOutputPath>
<BaseIntermediateOutputPath Condition="!HasTrailingSlash('$(BaseIntermediateOutputPath)')">$(BaseIntermediateOutputPath)\</BaseIntermediateOutputPath>
<IntermediateOutputPath Condition="'$(IntermediateOutputPath)' == '' and '$(PlatformName)' == 'AnyCPU'">$(BaseIntermediateOutputPath)$(Configuration)\</IntermediateOutputPath>
<IntermediateOutputPath Condition="'$(IntermediateOutputPath)' == '' and '$(PlatformName)' != 'AnyCPU'">$(BaseIntermediateOutputPath)$(PlatformName)\$(Configuration)\</IntermediateOutputPath>
<IntermediateOutputPath Condition="!HasTrailingSlash('$(IntermediateOutputPath)')">$(IntermediateOutputPath)\</IntermediateOutputPath>
</PropertyGroup>
<PropertyGroup>
<!-- Determine OutputType property from the legacy TargetType property -->
<OutputType Condition=" '$(TargetType)' != ''">$(TargetType)</OutputType>
<OutputType Condition=" '$(TargetType)' == 'Container' or '$(TargetType)' == 'DocumentContainer' ">library</OutputType>
<OutputType Condition=" '$(OutputType)' == '' ">exe</OutputType>
<DebugSymbols Condition=" '$(ConfigurationName)' == 'Debug' and '$(DebugSymbols)' == '' and '$(DebugType)'==''">true</DebugSymbols>
<!-- Whether or not a .pdb file is produced. -->
<_DebugSymbolsProduced>false</_DebugSymbolsProduced>
<_DebugSymbolsProduced Condition="'$(DebugSymbols)'=='true'">true</_DebugSymbolsProduced>
<_DebugSymbolsProduced Condition="'$(DebugType)'=='none'">false</_DebugSymbolsProduced>
<_DebugSymbolsProduced Condition="'$(DebugType)'=='pdbonly'">true</_DebugSymbolsProduced>
<_DebugSymbolsProduced Condition="'$(DebugType)'=='full'">true</_DebugSymbolsProduced>
<_DebugSymbolsProduced Condition="'$(DebugType)'=='portable'">true</_DebugSymbolsProduced>
<_DebugSymbolsProduced Condition="'$(DebugType)'=='embedded'">false</_DebugSymbolsProduced>
<_DebugSymbolsProduced Condition="'$(ProduceOnlyReferenceAssembly)'=='true'">false</_DebugSymbolsProduced>
<!-- Whether or not a .xml file is produced. -->
<_DocumentationFileProduced>true</_DocumentationFileProduced>
<_DocumentationFileProduced Condition="'$(DocumentationFile)'==''">false</_DocumentationFileProduced>
<!-- Whether or not a reference assembly is produced. -->
<ProduceReferenceAssembly Condition="'$(ProduceReferenceAssembly)' == ''">false</ProduceReferenceAssembly>
</PropertyGroup>
<!--
For Legacy projects that define properties per Configuration/Platform combination, the validity of an
invalid combination is determined by the non-empty value of the 'OutputPath' property specified under
the IDE generated Configuration/Platform specific 'PropertyGroup' section.
If 'BaseOutputPath' is specified, we can skip the validation, since, we assume the 'OutputPath' property
will be derived (e.g.: from the 'BaseOutputPath' property).
-->
<PropertyGroup Condition="'$(BaseOutputPathWasSpecified)' != 'true' and '$(_OutputPathWasMissing)' == 'true'">
<!--
When 'OutputPath' is missing or empty (along with non-existent 'BaseOutputPath') at this point means,
we're in legacy mode and we shall assume the current Configuration/Platform combination as invalid.
Whether this is considered an error or a warning depends on the value of $(SkipInvalidConfigurations).
-->
<_InvalidConfigurationError Condition=" '$(SkipInvalidConfigurations)' != 'true' ">true</_InvalidConfigurationError>
<_InvalidConfigurationWarning Condition=" '$(SkipInvalidConfigurations)' == 'true' ">true</_InvalidConfigurationWarning>
</PropertyGroup>
<!--
IDE Macros available from both integrated builds and from command line builds.
The following properties are 'macros' that are available via IDE for
pre and post build steps.
-->
<PropertyGroup>
<TargetExt Condition="'$(TargetExt)' == '' and '$(OutputType)'=='exe'">.exe</TargetExt>
<TargetExt Condition="'$(TargetExt)' == '' and '$(OutputType)'=='winexe'">.exe</TargetExt>
<TargetExt Condition="'$(TargetExt)' == '' and '$(OutputType)'=='appcontainerexe'">.exe</TargetExt>
<TargetExt Condition="'$(TargetExt)' == '' and '$(OutputType)'=='library'">.dll</TargetExt>
<TargetExt Condition="'$(TargetExt)' == '' and '$(OutputType)'=='module'">.netmodule</TargetExt>
<TargetExt Condition="'$(TargetExt)' == '' and '$(OutputType)'=='winmdobj'">.winmdobj</TargetExt>
</PropertyGroup>
<PropertyGroup>
<!-- Required for enabling Team Build for packaging app package-generating projects -->
<OutDirWasSpecified Condition=" '$(OutDir)'!='' and '$(OutDirWasSpecified)'=='' ">true</OutDirWasSpecified>
<OutDir Condition=" '$(OutDir)' == '' ">$(OutputPath)</OutDir>
<!-- Example, bin\Debug\ -->
<!-- Ensure OutDir has a trailing slash, so it can be concatenated -->
<OutDir Condition="'$(OutDir)' != '' and !HasTrailingSlash('$(OutDir)')">$(OutDir)\</OutDir>
<ProjectName Condition=" '$(ProjectName)' == '' ">$(MSBuildProjectName)</ProjectName>
<!-- Example, MyProject -->
<!-- For projects that generate app packages or ones that want a per-project output directory, update OutDir to include the project name -->
<OutDir Condition="'$(OutDir)' != '' and '$(OutDirWasSpecified)' == 'true' and (('$(WindowsAppContainer)' == 'true' and '$(GenerateProjectSpecificOutputFolder)' != 'false') or '$(GenerateProjectSpecificOutputFolder)' == 'true')">$(OutDir)$(ProjectName)\</OutDir>
<AssemblyName Condition=" '$(AssemblyName)'=='' ">$(MSBuildProjectName)</AssemblyName>
<TargetName Condition="'$(TargetName)' == '' and '$(OutputType)' == 'winmdobj' and '$(RootNamespace)' != ''">$(RootNamespace)</TargetName>
<TargetName Condition=" '$(TargetName)' == '' ">$(AssemblyName)</TargetName>
<!-- Example, MyAssembly -->
<ProjectFileName Condition=" '$(ProjectFileName)' == '' ">$(MSBuildProjectFile)</ProjectFileName>
<!-- Example, MyProject.csproj -->
<ProjectExt Condition=" '$(ProjectExt)' == '' ">$(MSBuildProjectExtension)</ProjectExt>
<!-- Example, .csproj -->
<WinMDExpOutputWindowsMetadataFilename Condition="'$(WinMDExpOutputWindowsMetadataFilename)' == '' and '$(OutputType)' == 'winmdobj'">$(TargetName).winmd</WinMDExpOutputWindowsMetadataFilename>
<TargetFileName Condition=" '$(TargetFileName)' == '' and '$(OutputType)' == 'winmdobj'">$(WinMDExpOutputWindowsMetadataFilename)</TargetFileName>
<TargetFileName Condition=" '$(TargetFileName)' == '' ">$(TargetName)$(TargetExt)</TargetFileName>
<!-- Example, MyAssembly.dll -->
</PropertyGroup>
<PropertyGroup>
<!--
The PublishableProject property is used when invoking the publish target on a solution that
contains multiple projects. The property determines which projects should be published, and
which projects should be skipped in the publish target. By default any "Windows Application"
or "Console Application" project type is publishable. However, a project that would otherwise
be published can be skipped by defining the PublishableProject property in the project itself.
-->
<_DeploymentPublishableProjectDefault Condition="'$(OutputType)'=='winexe' or '$(OutputType)'=='exe' or '$(OutputType)'=='appcontainerexe'">true</_DeploymentPublishableProjectDefault>
<PublishableProject Condition="'$(PublishableProject)'==''">$(_DeploymentPublishableProjectDefault)</PublishableProject>
<_DeploymentTargetApplicationManifestFileName Condition="'$(OutputType)'=='library'">Native.$(AssemblyName).manifest</_DeploymentTargetApplicationManifestFileName>
<!-- Example, Native.MyAssembly.manifest -->
<_DeploymentTargetApplicationManifestFileName Condition="'$(OutputType)'=='winexe'">$(TargetFileName).manifest</_DeploymentTargetApplicationManifestFileName>
<!-- Example, MyAssembly.exe.manifest -->
<_DeploymentTargetApplicationManifestFileName Condition="'$(OutputType)'=='exe'">$(TargetFileName).manifest</_DeploymentTargetApplicationManifestFileName>
<!-- Example, MyAssembly.exe.manifest -->
<_DeploymentTargetApplicationManifestFileName Condition="'$(OutputType)'=='appcontainerexe'">$(TargetFileName).manifest</_DeploymentTargetApplicationManifestFileName>
<!-- Example, MyAssembly.exe.manifest -->
<TargetDeployManifestFileName Condition="'$(TargetDeployManifestFileName)' == '' and '$(HostInBrowser)' != 'true'">$(AssemblyName).application</TargetDeployManifestFileName>
<!-- Example, MyAssembly.application -->
<TargetDeployManifestFileName Condition="'$(TargetDeployManifestFileName)' == '' and '$(HostInBrowser)' == 'true'">$(AssemblyName).xbap</TargetDeployManifestFileName>
<!-- Example, MyAssembly.xbap -->
<GenerateClickOnceManifests Condition="'$(OutputType)'=='winexe' or '$(OutputType)'=='exe' or '$(OutputType)'=='appcontainerexe'">$(GenerateManifests)</GenerateClickOnceManifests>
<_DeploymentApplicationManifestIdentity Condition="'$(OutputType)'=='library'">Native.$(AssemblyName)</_DeploymentApplicationManifestIdentity>
<_DeploymentApplicationManifestIdentity Condition="'$(OutputType)'=='winexe'">$(AssemblyName).exe</_DeploymentApplicationManifestIdentity>
<_DeploymentApplicationManifestIdentity Condition="'$(OutputType)'=='exe'">$(AssemblyName).exe</_DeploymentApplicationManifestIdentity>
<_DeploymentApplicationManifestIdentity Condition="'$(OutputType)'=='appcontainerexe'">$(AssemblyName).exe</_DeploymentApplicationManifestIdentity>
<_DeploymentDeployManifestIdentity Condition="'$(HostInBrowser)' != 'true'">$(AssemblyName).application</_DeploymentDeployManifestIdentity>
<_DeploymentDeployManifestIdentity Condition="'$(HostInBrowser)' == 'true'">$(AssemblyName).xbap</_DeploymentDeployManifestIdentity>
<_DeploymentFileMappingExtension Condition="'$(MapFileExtensions)'=='true'">.deploy</_DeploymentFileMappingExtension>
<_DeploymentFileMappingExtension Condition="'$(MapFileExtensions)'!='true'"></_DeploymentFileMappingExtension>
<_DeploymentBuiltUpdateInterval Condition="'$(UpdatePeriodically)'=='true'">$(UpdateInterval)</_DeploymentBuiltUpdateInterval>
<_DeploymentBuiltUpdateIntervalUnits Condition="'$(UpdatePeriodically)'=='true'">$(UpdateIntervalUnits)</_DeploymentBuiltUpdateIntervalUnits>
<_DeploymentBuiltUpdateInterval Condition="'$(UpdatePeriodically)'!='true'">0</_DeploymentBuiltUpdateInterval>
<_DeploymentBuiltUpdateIntervalUnits Condition="'$(UpdatePeriodically)'!='true'">Days</_DeploymentBuiltUpdateIntervalUnits>
<_DeploymentBuiltMinimumRequiredVersion Condition="'$(UpdateRequired)'=='true' and '$(Install)'=='true'">$(MinimumRequiredVersion)</_DeploymentBuiltMinimumRequiredVersion>
<_DeploymentLauncherBased Condition="'$(TargetFrameworkIdentifier)' == '.NETCoreApp'">true</_DeploymentLauncherBased>
<MaxTargetPath Condition="'$(MaxTargetPath)'==''">100</MaxTargetPath>
</PropertyGroup>
<PropertyGroup>
<!--
By default, GenerateApplicationManifest puts all satellite assemblies to the manifest
record by default by setting TargetCulture to *.
-->
<TargetCulture Condition="'$(TargetCulture)'==''">*</TargetCulture>
<FallbackCulture Condition="'$(UICulture)'!='' and '$(FallbackCulture)'==''">$(UICulture)</FallbackCulture>
</PropertyGroup>
<ItemGroup>
<!-- Not used any more-->
<_OutputPathItem Include="$(OutDir)"/>
<_UnmanagedRegistrationCache Include="$(BaseIntermediateOutputPath)$(MSBuildProjectFile).UnmanagedRegistration.cache"/>
<_ResolveComReferenceCache Include="$(IntermediateOutputPath)$(MSBuildProjectFile).ResolveComReference.cache"/>
</ItemGroup>
<PropertyGroup>
<!-- Example, C:\MyProjects\MyProject\bin\Debug\ -->
<!--
Condition intentionally omitted on this one, because it causes problems
when we pick up the value of an environment variable named TargetDir
-->
<TargetDir Condition="'$(OutDir)' != ''">$([MSBuild]::Escape($([System.IO.Path]::GetFullPath(`$([System.IO.Path]::Combine(`$(MSBuildProjectDirectory)`, `$(OutDir)`))`))))</TargetDir>
<!-- Example, C:\MyProjects\MyProject\bin\Debug\MyAssembly.dll -->
<TargetPath Condition=" '$(TargetPath)' == '' ">$(TargetDir)$(TargetFileName)</TargetPath>
<TargetRefPath Condition=" '$(TargetRefPath)' == '' and '$(ProduceReferenceAssembly)' == 'true' and '$(ProduceReferenceAssemblyInOutDir)' == 'true' ">$([MSBuild]::NormalizePath($(TargetDir), 'ref', $(TargetFileName)))</TargetRefPath>
<TargetRefPath Condition=" '$(TargetRefPath)' == '' and '$(ProduceReferenceAssembly)' == 'true' ">$([MSBuild]::NormalizePath($(MSBuildProjectDirectory), $(IntermediateOutputPath), 'ref', $(TargetFileName)))</TargetRefPath>
<!-- Example, C:\MyProjects\MyProject\ -->
<ProjectDir Condition=" '$(ProjectDir)' == '' ">$([MSBuild]::EnsureTrailingSlash($(MSBuildProjectDirectory)))</ProjectDir>
<!-- Example, C:\MyProjects\MyProject\MyProject.csproj -->
<ProjectPath Condition=" '$(ProjectPath)' == '' ">$(ProjectDir)$(ProjectFileName)</ProjectPath>
</PropertyGroup>
<ItemGroup>
<!-- This is not used here but remains for backwards compatibility -->
<AppConfigFileDestination Include="$(OutDir)$(TargetFileName).config"/>
</ItemGroup>
<!--
IDE Macros available only from integrated builds.
The following properties are 'macros' that are available via IDE for
pre and post build steps. However, they are not defined when directly building
a project from the command line, only when building a solution.
-->
<PropertyGroup>
<DevEnvDir Condition="'$(DevEnvDir)'==''">*Undefined*</DevEnvDir>
<SolutionName Condition="'$(SolutionName)'==''">*Undefined*</SolutionName>
<!-- Example, MySolution -->
<SolutionFileName Condition="'$(SolutionFileName)'==''">*Undefined*</SolutionFileName>
<!-- Example, MySolution.sln -->
<SolutionPath Condition="'$(SolutionPath)'==''">*Undefined*</SolutionPath>
<!-- Example, f:\MySolutions\MySolution\MySolution.sln -->
<SolutionDir Condition="'$(SolutionDir)'==''">*Undefined*</SolutionDir>
<!-- Example, f:\MySolutions\MySolution\ -->
<SolutionExt Condition="'$(SolutionExt)'==''">*Undefined*</SolutionExt>
<!-- Example, .sln -->
</PropertyGroup>
<PropertyGroup>
<GenerateBindingRedirectsOutputType Condition="'$(OutputType)'=='exe' or '$(OutputType)'=='winexe'">true</GenerateBindingRedirectsOutputType>
<!-- It would be a breaking change to automatically turn on binding redirects for existing projects, so turn them on only when opting into a new framework. -->
<AutoGenerateBindingRedirects Condition="'$(AutoGenerateBindingRedirects)' == '' and '$(TargetFrameworkIdentifier)' == '.NETFramework' and '$(TargetFrameworkVersion.TrimStart(vV))' >= '4.7.2'">true</AutoGenerateBindingRedirects>
</PropertyGroup>
<PropertyGroup Condition="'$(AutoUnifyAssemblyReferences)' == ''">
<AutoUnifyAssemblyReferences>true</AutoUnifyAssemblyReferences>
<AutoUnifyAssemblyReferences Condition="'$(GenerateBindingRedirectsOutputType)' == 'true' and '$(AutoGenerateBindingRedirects)' != 'true'">false</AutoUnifyAssemblyReferences>
</PropertyGroup>
<PropertyGroup>
<CleanFile Condition="'$(CleanFile)'==''">$(MSBuildProjectFile).FileListAbsolute.txt</CleanFile>
<!-- During DesignTime Builds, skip project reference build as Design time is only queueing information.-->
<BuildProjectReferences Condition="'$(BuildProjectReferences)' == '' and '$(DesignTimeBuild)' == 'true'">false</BuildProjectReferences>
<!-- By default we will build (and if applicable, clean) all project references. But this can be used to disable that-->
<BuildProjectReferences Condition="'$(BuildProjectReferences)' == ''">true</BuildProjectReferences>
<BuildInParallel Condition="'$(BuildInParallel)' == ''">true</BuildInParallel>
<_ResolveReferenceDependencies Condition="'$(_ResolveReferenceDependencies)' == ''">false</_ResolveReferenceDependencies>
<_GetChildProjectCopyToOutputDirectoryItems Condition="'$(_GetChildProjectCopyToOutputDirectoryItems)' == ''">true</_GetChildProjectCopyToOutputDirectoryItems>
<OverwriteReadOnlyFiles Condition="'$(OverwriteReadOnlyFiles)' == ''">false</OverwriteReadOnlyFiles>
<ComReferenceNoClassMembers Condition="'$(ComReferenceNoClassMembers)' == ''">false</ComReferenceNoClassMembers>
</PropertyGroup>
<PropertyGroup>
<_GenerateBindingRedirectsIntermediateAppConfig>$(IntermediateOutputPath)$(TargetFileName).config</_GenerateBindingRedirectsIntermediateAppConfig>
</PropertyGroup>
<PropertyGroup Condition="'$(MSBuildCopyMarkerName)' == ''">
<MSBuildCopyMarkerName>$(MSBuildProjectFile)</MSBuildCopyMarkerName>
<!-- For a long MSBuildProjectFile let's shorten this to 17 chars - using the first 8 chars of the filename and a filename hash. -->
<MSBuildCopyMarkerName Condition="'$(MSBuildCopyMarkerName.Length)' > '17'">$(MSBuildProjectFile.Substring(0,8)).$([MSBuild]::StableStringHash($(MSBuildProjectFile)).ToString("X8"))</MSBuildCopyMarkerName>
<MSBuildCopyMarkerName>$(MSBuildCopyMarkerName).Up2Date</MSBuildCopyMarkerName>
</PropertyGroup>
<ItemGroup>
<IntermediateAssembly Include="$(IntermediateOutputPath)$(TargetName)$(TargetExt)"/>
<FinalDocFile Include="@(DocFileItem->'$(OutDir)%(Filename)%(Extension)')"/>
<CopyUpToDateMarker Include="$([MSBuild]::NormalizePath('$(MSBuildProjectDirectory)', '$(IntermediateOutputPath)', '$(MSBuildCopyMarkerName)'))" />
</ItemGroup>
<ItemGroup Condition="'$(ProduceReferenceAssembly)' == 'true'">
<IntermediateRefAssembly Include="$(IntermediateOutputPath)refint\$(TargetName)$(TargetExt)" Condition="'@(IntermediateRefAssembly)' == ''" />
<CreateDirectory Include="@(IntermediateRefAssembly->'%(RootDir)%(Directory)')" />
<CreateDirectory Include="$(OutDir)ref" Condition=" '$(ProduceReferenceAssemblyInOutDir)' == 'true'" />
<CreateDirectory Include="$(IntermediateOutputPath)ref" Condition=" '$(ProduceReferenceAssemblyInOutDir)' != 'true'" />
</ItemGroup>
<ItemGroup Condition="'$(_DebugSymbolsProduced)' == 'true'">
<_DebugSymbolsIntermediatePath Include="$(IntermediateOutputPath)$(TargetName).compile.pdb" Condition="'$(OutputType)' == 'winmdobj' and '@(_DebugSymbolsIntermediatePath)' == ''"/>
<_DebugSymbolsIntermediatePath Include="$(IntermediateOutputPath)$(TargetName).pdb" Condition="'$(OutputType)' != 'winmdobj' and '@(_DebugSymbolsIntermediatePath)' == ''"/>
<_DebugSymbolsOutputPath Include="@(_DebugSymbolsIntermediatePath->'$(OutDir)%(Filename)%(Extension)')" />
</ItemGroup>
<PropertyGroup Condition="'$(_DebugSymbolsProduced)' == 'true' and '$(OutputType)' == 'winmdobj'">
<WinMDExpOutputPdb Condition="'$(WinMDExpOutputPdb)' == ''">$(IntermediateOutputPath)$(TargetName).pdb</WinMDExpOutputPdb>
<_WinMDDebugSymbolsOutputPath>$([System.IO.Path]::Combine('$(OutDir)', $([System.IO.Path]::GetFileName('$(WinMDExpOutputPdb)'))))</_WinMDDebugSymbolsOutputPath>
</PropertyGroup>
<PropertyGroup Condition="'$(OutputType)' == 'winmdobj' and '$(DocumentationFile)'!=''">
<WinMDOutputDocumentationFile Condition="'$(WinMDOutputDocumentationFile)' == ''">$(IntermediateOutputPath)$(TargetName).xml</WinMDOutputDocumentationFile>
<_WinMDDocFileOutputPath>$([System.IO.Path]::Combine('$(OutDir)', $([System.IO.Path]::GetFileName('$(WinMDOutputDocumentationFile)'))))</_WinMDDocFileOutputPath>
</PropertyGroup>
<PropertyGroup Condition="'$(WinMDExpOutputWindowsMetadataFilename)' != ''">
<_IntermediateWindowsMetadataPath>$(IntermediateOutputPath)$(WinMDExpOutputWindowsMetadataFilename)</_IntermediateWindowsMetadataPath>
<_WindowsMetadataOutputPath>$(OutDir)$(WinMDExpOutputWindowsMetadataFilename)</_WindowsMetadataOutputPath>
</PropertyGroup>
<ItemGroup>
<!-- Create an item for entry point of the ClickOnce application (Example: WindowsApplication1.exe) -->
<_DeploymentManifestEntryPoint Include="@(IntermediateAssembly)">
<TargetPath>$(TargetFileName)</TargetPath>
</_DeploymentManifestEntryPoint>
<!-- Create an item for the application icon if one exists in the project (Example: app.ico) -->
<!-- NOTE: The item Include and the Exists function are operating relative to the PROJECT (.csproj, .vbproj etc.) directory in this case -->
<_DeploymentManifestIconFile Include="$(ApplicationIcon)" Condition="Exists('$(ApplicationIcon)')">
<TargetPath>$(ApplicationIcon)</TargetPath>
</_DeploymentManifestIconFile>
<!-- Create an item for the output application manifest (Example: WindowsApplication1.exe.manifeset) -->
<ApplicationManifest Include="$(IntermediateOutputPath)$(_DeploymentTargetApplicationManifestFileName)">
<TargetPath>$(_DeploymentTargetApplicationManifestFileName)</TargetPath>
</ApplicationManifest>
<!-- Create an item for the final application manifest (Example: WindowsApplication1.exe.manifeset)
This item represents the final output application manifest used for project-to-project
references and for copying to the publish output location. -->
<_ApplicationManifestFinal Include="$(OutDir)$(_DeploymentTargetApplicationManifestFileName)">
<TargetPath>$(_DeploymentTargetApplicationManifestFileName)</TargetPath>
</_ApplicationManifestFinal>
<!-- Create an item for the output deploy manifest (Example: WindowsApplication1.application) -->
<DeployManifest Include="$(IntermediateOutputPath)$(TargetDeployManifestFileName)">
<TargetPath>$(TargetDeployManifestFileName)</TargetPath>
</DeployManifest>
<!-- Create an item for the intermediate trust info file -->
<_DeploymentIntermediateTrustInfoFile Include="$(IntermediateOutputPath)$(TargetName).TrustInfo.xml" Condition="'$(TargetZone)'!=''"/>
</ItemGroup>
<!--
Determine the <deploymentProvider> (_DeploymentUrl) for the ClickOnce deployment manifest.
Prefer the UpdateUrl, falling back to InstallUrl or PublishUrl if not specified.
If the UpdateUrl is specified then _DeploymentUrl is always set to the UpdateUrl.
Otherwise, only set the _DeploymentUrl if it's an installed app and updates are enabled.
-->
<PropertyGroup>
<_DeploymentUrl Condition="'$(_DeploymentUrl)'==''">$(UpdateUrl)</_DeploymentUrl>
<_DeploymentUrl Condition="'$(_DeploymentUrl)'==''">$(InstallUrl)</_DeploymentUrl>
<_DeploymentUrl Condition="'$(_DeploymentUrl)'==''">$(PublishUrl)</_DeploymentUrl>
<_DeploymentUrl Condition="!('$(UpdateUrl)'=='') and '$(Install)'=='false'"></_DeploymentUrl>
<_DeploymentUrl Condition="'$(_DeploymentUrl)'!=''">$(_DeploymentUrl)$(TargetDeployManifestFileName)</_DeploymentUrl>
<!--
Need to explicitly blank out the _DeploymentUrl when it's not used. Otherwise an
inappropriate value may be used. For example a local path from the PublishUrl
is something we never want to see in the manifest because it means you could
only install the app from that machine.
-->
<_DeploymentUrl Condition="'$(UpdateUrl)'=='' and !('$(Install)'=='true' and '$(UpdateEnabled)'=='true')"></_DeploymentUrl>
<_DeploymentUrl Condition="'$(ExcludeDeploymentUrl)'=='true'"></_DeploymentUrl>
</PropertyGroup>
<!-- Determine the URLs for the bootstrapper. -->
<PropertyGroup>
<_DeploymentApplicationUrl Condition="'$(IsWebBootstrapper)'=='true'">$(InstallUrl)</_DeploymentApplicationUrl>
<_DeploymentApplicationUrl Condition="'$(IsWebBootstrapper)'=='true' and '$(InstallUrl)'==''">$(PublishUrl)</_DeploymentApplicationUrl>
<_DeploymentComponentsUrl Condition="'$(BootstrapperComponentsLocation)'=='Absolute'">$(BootstrapperComponentsUrl)</_DeploymentComponentsUrl>
</PropertyGroup>
<!-- Output location for publish target. -->
<PropertyGroup>
<PublishDir Condition="'$(PublishDir)' != '' and !HasTrailingSlash('$(PublishDir)')">$(PublishDir)\</PublishDir>
<PublishDir Condition="'$(PublishDir)'==''">$(OutputPath)app.publish\</PublishDir>
</PropertyGroup>
<!--
ClickOncePublishDir property is the output location used by all ClickOnce publish targets. This should be same as PublishDir except
for a trailing slash. PublishDir when specified as a global property on the command line cannot be changed to add a trailing slash.
-->
<PropertyGroup>
<ClickOncePublishDir>$(PublishDir)</ClickOncePublishDir>
<ClickOncePublishDir Condition="!HasTrailingSlash('$(ClickOncePublishDir)')">$(ClickOncePublishDir)\</ClickOncePublishDir>
</PropertyGroup>
<!--
ProcessorArchitecture is the target processor architecture.
-->
<PropertyGroup Condition="'$(ProcessorArchitecture)'==''">
<!--
If ProcessorArchitecture is not set, set it to PlatformTarget
Note: if $(PlatformTarget) is also blank resolve assembly reference defaults to msil which is the
desired behavior in this case
-->
<ProcessorArchitecture>$(PlatformTarget)</ProcessorArchitecture>
<!--
If Processor architecture is not set and PlatformTarget is a known target translate the
PlatformTarget into something ResolveAssemblyReference knows about
-->
<ProcessorArchitecture Condition=" '$(PlatformTarget)' == 'AnyCpu' ">msil</ProcessorArchitecture>
<ProcessorArchitecture Condition=" '$(PlatformTarget)' == 'x64' ">amd64</ProcessorArchitecture>
<ProcessorArchitecture Condition=" '$(PlatformTarget)' == 'Itanium' ">ia64</ProcessorArchitecture>
<ProcessorArchitecture Condition=" '$(PlatformTarget)' == 'x86' ">x86</ProcessorArchitecture>
<ProcessorArchitecture Condition=" '$(PlatformTarget)' == 'ARM' ">arm</ProcessorArchitecture>
</PropertyGroup>
<PropertyGroup>
<ConsiderPlatformAsProcessorArchitecture Condition="'$(ConsiderPlatformAsProcessorArchitecture)' == ''">true</ConsiderPlatformAsProcessorArchitecture>
</PropertyGroup>
<PropertyGroup Condition="'$(ProcessorArchitecture)' == '' and '$(ConsiderPlatformAsProcessorArchitecture)' == 'true'">
<!-- We need to do this here because if we were to just compare against platform visual would parse them out as available platforms which may not be the case -->
<ProcessorArchitectureAsPlatform>$(Platform)</ProcessorArchitectureAsPlatform>
<ProcessorArchitecture Condition=" '$(ProcessorArchitectureAsPlatform)' == 'AnyCpu' or '$(ProcessorArchitectureAsPlatform)' == 'Any Cpu'">msil</ProcessorArchitecture>
<ProcessorArchitecture Condition=" '$(ProcessorArchitectureAsPlatform)' == 'x64' or '$(ProcessorArchitectureAsPlatform)' == 'amd64'">amd64</ProcessorArchitecture>
<ProcessorArchitecture Condition=" '$(ProcessorArchitectureAsPlatform)' == 'Itanium' ">ia64</ProcessorArchitecture>
<ProcessorArchitecture Condition=" '$(ProcessorArchitectureAsPlatform)' == 'x86' or '$(ProcessorArchitectureAsPlatform)' == 'win32'">x86</ProcessorArchitecture>
<ProcessorArchitecture Condition=" '$(ProcessorArchitectureAsPlatform)' == 'ARM' ">arm</ProcessorArchitecture>
<!--For compatibility with the 4.0 behavior, if not set above, default to the environment. To override this, set ProcessorArchitecture explicitly. We also need to disable the warning since we do not know if what the environment is set to is correct-->
<ResolveAssemblyWarnOrErrorOnTargetArchitectureMismatch Condition="'$(ProcessorArchitecture)'==''">None</ResolveAssemblyWarnOrErrorOnTargetArchitectureMismatch>
<ProcessorArchitecture Condition="'$(ProcessorArchitecture)'==''">$(PROCESSOR_ARCHITECTURE)</ProcessorArchitecture>
</PropertyGroup>
<!-- Sensible defaults for the most-commonly-desired MSBuildRuntime and MSBuildArchitecture values. The Core runtime does not currently support specifying task architecture or runtime.
If support for out-of-proc task execution is added on other runtimes, make sure each task's logic is checked against the current state of support. -->
<PropertyGroup Condition="'$(DisableOutOfProcTaskHost)' == '' and '$(MSBuildRuntimeType)' == 'Full'">
<TargetFrameworkAsMSBuildRuntime Condition="'$(TargetFrameworkVersion)' == 'v2.0' or '$(TargetFrameworkVersion)' == 'v3.0' or '$(TargetFrameworkVersion)' == 'v3.5'">CLR2</TargetFrameworkAsMSBuildRuntime>
<TargetFrameworkAsMSBuildRuntime Condition="'$(TargetFrameworkVersion)' == 'v4.0' or '$(TargetFrameworkVersion)' == 'v4.5'">CLR4</TargetFrameworkAsMSBuildRuntime>
<TargetFrameworkAsMSBuildRuntime Condition="'$(TargetFrameworkAsMSBuildRuntime)' == ''">CurrentRuntime</TargetFrameworkAsMSBuildRuntime>
<PlatformTargetAsMSBuildArchitectureExplicitlySet Condition="'$(PlatformTargetAsMSBuildArchitecture)' != ''">true</PlatformTargetAsMSBuildArchitectureExplicitlySet>
<PlatformTargetAsMSBuildArchitectureExplicitlySet Condition="'$(PlatformTargetAsMSBuildArchitecture)' == ''">false</PlatformTargetAsMSBuildArchitectureExplicitlySet>
<PlatformTargetAsMSBuildArchitecture Condition="'$(PlatformTarget)' == 'x86' or ('$(PlatformTarget)' == 'x64' and '$(MSBuildExtensionsPath64)' != '')">$(PlatformTarget)</PlatformTargetAsMSBuildArchitecture>
<PlatformTargetAsMSBuildArchitecture Condition="'$(PlatformTarget)' == 'arm'">x86</PlatformTargetAsMSBuildArchitecture>
<PlatformTargetAsMSBuildArchitecture Condition="('$(PlatformTarget)' == 'ia64' and '$(MSBuildExtensionsPath64)' != '')">x64</PlatformTargetAsMSBuildArchitecture>
<PlatformTargetAsMSBuildArchitecture Condition="'$(PlatformTargetAsMSBuildArchitecture)' == ''">CurrentArchitecture</PlatformTargetAsMSBuildArchitecture>
</PropertyGroup>
<!-- Flavor is the project flavor. For example, Client, Smart Devices, SQL Server, etc. -->
<PropertyGroup>
<ProjectFlavor Condition="'$(ProjectFlavor)'==''">Client</ProjectFlavor>
</PropertyGroup>
<!--
The default for compilers is to not delay-sign. If $(DelaySign) is false, let the compiler
use its default rather than forcing a no-delay-sign flag to be passed in. This is so that
attributes in the source code can override this decision.
-->
<PropertyGroup>
<DelaySign Condition="'$(SignAssembly)' != 'true'">false</DelaySign>
<DelaySign Condition="'$(DelaySign)'!='true'"></DelaySign>
</PropertyGroup>
<!-- These properties control web reference proxy generation. -->
<PropertyGroup>
<WebReference_EnableProperties Condition=" '$(WebReference_EnableProperties)' == '' ">true</WebReference_EnableProperties>
<WebReference_EnableSQLTypes Condition=" '$(WebReference_EnableSQLTypes)' == '' ">true</WebReference_EnableSQLTypes>
<WebReference_EnableLegacyEventingModel Condition=" '$(WebReference_EnableLegacyEventingModel)' == '' ">false</WebReference_EnableLegacyEventingModel>
</PropertyGroup>
<!--
These parameters control where to look in the registry for directories to search for
assemblies in the assembly resolution tasks.
-->
<PropertyGroup>
<AssemblyFoldersSuffix Condition=" '$(AssemblyFoldersSuffix)' == '' ">AssemblyFoldersEx</AssemblyFoldersSuffix>
<FrameworkRegistryBase Condition=" '$(FrameworkRegistryBase)' == '' ">Software\Microsoft\$(TargetFrameworkIdentifier)</FrameworkRegistryBase>
<TargetPlatformRegistryBase Condition="'$(TargetPlatformRegistryBase)' == ''">Software\Microsoft\Microsoft SDKs\$(TargetPlatformIdentifier)</TargetPlatformRegistryBase>
<AssemblyFoldersConfigFile Condition="'$(AssemblyFoldersConfigFile)' == ''">$([MSBuild]::GetToolsDirectory32())\AssemblyFolders.config</AssemblyFoldersConfigFile>
<AssemblyFoldersConfigFileSearchPath Condition="Exists('$(AssemblyFoldersConfigFile)')">{AssemblyFoldersFromConfig:$(AssemblyFoldersConfigFile),$(TargetFrameworkVersion)};</AssemblyFoldersConfigFileSearchPath>
<!--
These are the extensions that assembly reference resolution will consider for resolution.
Add new extensions here if you want to add new file types to consider (for example, .metadata_dll).
Put the most likely extensions first for reference resolution speed.
-->
<AllowedReferenceAssemblyFileExtensions Condition=" '$(AllowedReferenceAssemblyFileExtensions)' == '' ">
.winmd;
.dll;
.exe
</AllowedReferenceAssemblyFileExtensions>
<!--
These are the extensions that reference resolution will consider when looking for files related
to resolved references. Add new extensions here if you want to add new file types to consider.
-->
<AllowedReferenceRelatedFileExtensions Condition=" '$(AllowedReferenceRelatedFileExtensions)' == '' ">
.pdb;
.xml;
.pri;
.dll.config;
.exe.config
</AllowedReferenceRelatedFileExtensions>
<!--
These names are used when determining which TargetFramework subset to use. If the any of the FullReferenceAssemblyNames
are seen in the list of client subsets, RAR will assume that no client subset is being used. The list is semicolon seperated
For example : Full;Complete;AllThere
-->
<FullReferenceAssemblyNames Condition="'$(FullReferenceAssemblyNames)' == ''">Full</FullReferenceAssemblyNames>
</PropertyGroup>
<PropertyGroup Condition="$(AssemblySearchPaths) == ''">
<!--
The SearchPaths property is set to find assemblies in the following order:
(1) Files from current project - indicated by {CandidateAssemblyFiles}
(2) $(ReferencePath) - the reference path property, which comes from the .USER file.
(3) The hintpath from the referenced item itself, indicated by {HintPathFromItem}.
(4) The directory of MSBuild's "target" runtime from GetFrameworkPath.
The "target" runtime folder is the folder of the runtime that MSBuild is a part of.
(5) Assembly folders from AssemblyFolders.config file (provided by Visual Studio Dev15+).
(6) Registered assembly folders, indicated by {Registry:*,*,*}
(7) Legacy registered assembly folders, indicated by {AssemblyFolders}
(8) Resolve to the GAC.
(9) Treat the reference's Include as if it were a real file name.
(10) Look in the application's output folder (like bin\debug)
-->
<AssemblySearchPaths Condition="'$(AssemblySearchPath_UseCandidateAssemblyFiles)' != 'false'">{CandidateAssemblyFiles}</AssemblySearchPaths>
<AssemblySearchPaths Condition="'$(AssemblySearchPath_UseReferencePath)' != 'false'">$(AssemblySearchPaths);$(ReferencePath)</AssemblySearchPaths>
<AssemblySearchPaths Condition="'$(AssemblySearchPath_UseHintPathFromItem)' != 'false'">$(AssemblySearchPaths);{HintPathFromItem}</AssemblySearchPaths>
<AssemblySearchPaths Condition="'$(AssemblySearchPath_UseTargetFrameworkDirectory)' != 'false'">$(AssemblySearchPaths);{TargetFrameworkDirectory}</AssemblySearchPaths>
<AssemblySearchPaths Condition="'$(AssemblySearchPath_UseAssemblyFoldersConfigFileSearchPath)' != 'false'">$(AssemblySearchPaths);$(AssemblyFoldersConfigFileSearchPath)</AssemblySearchPaths>
<AssemblySearchPaths Condition="'$(AssemblySearchPath_UseRegistry)' != 'false'">$(AssemblySearchPaths);{Registry:$(FrameworkRegistryBase),$(TargetFrameworkVersion),$(AssemblyFoldersSuffix)$(AssemblyFoldersExConditions)}</AssemblySearchPaths>
<AssemblySearchPaths Condition="'$(AssemblySearchPath_UseAssemblyFolders)' != 'false'">$(AssemblySearchPaths);{AssemblyFolders}</AssemblySearchPaths>
<AssemblySearchPaths Condition="'$(AssemblySearchPath_UseGAC)' != 'false'">$(AssemblySearchPaths);{GAC}</AssemblySearchPaths>
<AssemblySearchPaths Condition="'$(AssemblySearchPath_UseRawFileName)' != 'false'">$(AssemblySearchPaths);{RawFileName}</AssemblySearchPaths>
<AssemblySearchPaths Condition="'$(AssemblySearchPath_UseOutDir)' != 'false'">$(AssemblySearchPaths);$(OutDir)</AssemblySearchPaths>
</PropertyGroup>
<!-- ContinueOnError takes 3 values: WarnAndContinue (true), ErrorAndStop (false), and ErrorAndContinue.
Default to ErrorAndStop, since that matches the behaviour in previous versions, and what users
typically expect -->
<PropertyGroup>
<ContinueOnError Condition="'$(ContinueOnError)' == ''">false</ContinueOnError>
</PropertyGroup>
<!-- Users familiar with how some other repos work try to use NoWarn with MSBuild in place of MSBuildWarningsAsMessages. -->
<PropertyGroup>
<MSBuildWarningsAsMessages Condition="'$(MSBuildWarningsAsMessages)'==''">$(NoWarn)</MSBuildWarningsAsMessages>
<MSBuildWarningsAsErrors Condition="'$(MSBuildWarningsAsErrors)'==''">$(WarningsAsErrors)</MSBuildWarningsAsErrors>
<MSBuildWarningsNotAsErrors Condition="'$(MSBuildWarningsNotAsErrors)'==''">$(WarningsNotAsErrors)</MSBuildWarningsNotAsErrors>
</PropertyGroup>
<!-- Common Project System support -->
<PropertyGroup>
<CommonXamlResourcesDirectory Condition=" '$(CommonXamlResourcesDirectory)' == '' ">$(MSBuildThisFileDirectory)$(LangName)\</CommonXamlResourcesDirectory>
</PropertyGroup>
<!-- We need to fallback to en-US in case the xaml rules are not localized (possibly happen on community languages). -->
<PropertyGroup Condition="!Exists('$(CommonXamlResourcesDirectory)')">
<CommonXamlResourcesDirectory>$(MSBuildThisFileDirectory)en-US\</CommonXamlResourcesDirectory>
</PropertyGroup>
<ItemGroup Condition=" '$(DefineCommonItemSchemas)' == 'true' ">
<PropertyPageSchema Include="$(CommonXamlResourcesDirectory)ProjectItemsSchema.xaml"/>
<PropertyPageSchema Include="
$(CommonXamlResourcesDirectory)General.xaml;
$(CommonXamlResourcesDirectory)Debugger_General.xaml">
<Context>Project</Context>
</PropertyPageSchema>
<PropertyPageSchema Include="$(CommonXamlResourcesDirectory)General.BrowseObject.xaml">
<Context>BrowseObject</Context>
</PropertyPageSchema>
<PropertyPageSchema Include="$(CommonXamlResourcesDirectory)General_File.xaml">
<Context>File</Context>
</PropertyPageSchema>
<PropertyPageSchema Include="$(CommonXamlResourcesDirectory)SCC.xaml">
<Context>Invisible</Context>
</PropertyPageSchema>
<PropertyPageSchema Include="
$(CommonXamlResourcesDirectory)Folder.xaml;
$(CommonXamlResourcesDirectory)None.xaml;
$(CommonXamlResourcesDirectory)Content.xaml;
$(CommonXamlResourcesDirectory)EmbeddedResource.xaml;
">
<Context>File;BrowseObject</Context>
</PropertyPageSchema>
<PropertyPageSchema Include="$(CommonXamlResourcesDirectory)SpecialFolder.xaml;">
<Context>File;ProjectSubscriptionService</Context>
</PropertyPageSchema>
</ItemGroup>
<PropertyGroup>
<DefineCommonReferenceSchemas Condition=" '$(DefineCommonReferenceSchemas)' == '' ">$(DefineCommonItemSchemas)</DefineCommonReferenceSchemas>
</PropertyGroup>
<ItemGroup Condition=" '$(DefineCommonReferenceSchemas)' == 'true' ">
<!-- Assembly references -->
<PropertyPageSchema Include="$(CommonXamlResourcesDirectory)assemblyreference.xaml">
<Context>;BrowseObject</Context>
</PropertyPageSchema>
<PropertyPageSchema Include="$(CommonXamlResourcesDirectory)ResolvedAssemblyReference.xaml">
<Context>ProjectSubscriptionService;BrowseObject</Context>
</PropertyPageSchema>
<!-- COM references -->
<PropertyPageSchema Include="$(CommonXamlResourcesDirectory)COMReference.xaml">
<Context>;BrowseObject</Context>
</PropertyPageSchema>
<PropertyPageSchema Include="$(CommonXamlResourcesDirectory)ResolvedCOMReference.xaml">
<Context>ProjectSubscriptionService;BrowseObject</Context>
</PropertyPageSchema>
<!-- Project references -->
<PropertyPageSchema Include="$(CommonXamlResourcesDirectory)ProjectReference.xaml">
<Context>;BrowseObject</Context>
</PropertyPageSchema>
<PropertyPageSchema Include="$(CommonXamlResourcesDirectory)ResolvedProjectReference.xaml">
<Context>ProjectSubscriptionService;BrowseObject</Context>
</PropertyPageSchema>
</ItemGroup>
<ItemGroup Condition=" '$(DefineCommonCapabilities)' == 'true' ">
<ProjectCapability Include="
AssemblyReferences;
COMReferences;
ProjectReferences;
SharedProjectReferences;
OutputGroups;
AllTargetOutputGroups;
VisualStudioWellKnownOutputGroups;
SingleFileGenerators;
DeclaredSourceItems;
UserSourceItems;
" />
<ProjectCapability Condition=" '$(TargetPlatformIdentifier)' == 'Windows' and '$(TargetPlatformVersion)' < 8.0 "
Include="BuildWindowsDesktopTarget" />
</ItemGroup>
<ItemDefinitionGroup Condition=" '$(DefineExplicitDefaults)' == 'true' ">
<None>
<CopyToOutputDirectory>Never</CopyToOutputDirectory>
</None>
<Content>
<CopyToOutputDirectory>Never</CopyToOutputDirectory>
</Content>
<Compile>
<CopyToOutputDirectory>Never</CopyToOutputDirectory>
</Compile>
<EmbeddedResource>
<CopyToOutputDirectory>Never</CopyToOutputDirectory>
</EmbeddedResource>
</ItemDefinitionGroup>
<!--
Target that allows targets consuming source control confirmation to establish a dependency on targets producing this information.
Any target that reads SourceRevisionId, PrivateRepositoryUrl, SourceRoot, and other source control properties and items
should depend on this target and be conditioned on '$(SourceControlInformationFeatureSupported)' == 'true'.
SourceRevisionId property uniquely identifies the source control revision of the repository the project belongs to.
For Git repositories this id is a commit hash, for TFVC repositories it's the changeset number, etc.
PrivateRepositoryUrl property stores the URL of the repository supplied by the CI server or retrieved from source control manager.
Targets consuming this property shall not publish its value implicitly as it might inadvertently reveal an internal URL.
Instead, they shall only do so if the project sets PublishRepositoryUrl property to true. For example, the NuGet Pack target
may include the repository URL in the nuspec file generated for NuGet package produced by the project if PublishRepositoryUrl is true.
SourceRoot item group lists all source roots that the project source files reside under and their mapping to source control server URLs,
if available. This includes both source files under source control as well as source files in source packages. SourceRoot items are
used by compilers to determine path map in deterministic build and by SourceLink provider, which maps local paths to URLs of source files
stored on the source control server.
Source control information provider that sets these properties and items shall execute before this target (by including
InitializeSourceControlInformation in its BeforeTargets) and set source control properties and items that haven't been initialized yet.
-->
<Target Name="InitializeSourceControlInformation" />
<PropertyGroup>
<SourceControlInformationFeatureSupported>true</SourceControlInformationFeatureSupported>
</PropertyGroup>
<!--
***********************************************************************************************
***********************************************************************************************
Build Section
***********************************************************************************************
***********************************************************************************************
-->
<Target Name="_AddOutputPathToGlobalPropertiesToRemove">
<PropertyGroup>
<_GlobalPropertiesToRemoveFromProjectReferences Condition="'$(PassOutputPathToReferencedProjects)'=='false'">$(_GlobalPropertiesToRemoveFromProjectReferences);OutputPath</_GlobalPropertiesToRemoveFromProjectReferences>
</PropertyGroup>
</Target>
<!--
============================================================
_CheckForInvalidConfigurationAndPlatform
This target checks for errors in statically defined properties. By setting BeforeTargets, we try
to ensure that the target runs before any build related targets.
If your target requires this check and is running as a BeforeTargets of one of the first targets
of $(BuildDependsOn), $(RebuildDependsOn), or $(CleanDependsOn) you will need to set your DependsOn
to this target.
============================================================
-->
<Target
Name="_CheckForInvalidConfigurationAndPlatform"
BeforeTargets="$(BuildDependsOn);Build;$(RebuildDependsOn);Rebuild;$(CleanDependsOn);Clean">
<PropertyGroup>
<_InvalidConfigurationMessageText>The BaseOutputPath/OutputPath property is not set for project '$(MSBuildProjectFile)'. Please check to make sure that you have specified a valid combination of Configuration and Platform for this project. Configuration='$(_OriginalConfiguration)' Platform='$(_OriginalPlatform)'.</_InvalidConfigurationMessageText>
<_InvalidConfigurationMessageText Condition="'$(BuildingInsideVisualStudio)' == 'true'">$(_InvalidConfigurationMessageText) This error may also appear if some other project is trying to follow a project-to-project reference to this project, this project has been unloaded or is not included in the solution, and the referencing project does not build using the same or an equivalent Configuration or Platform.</_InvalidConfigurationMessageText>
<_InvalidConfigurationMessageText Condition="'$(BuildingInsideVisualStudio)' != 'true'">$(_InvalidConfigurationMessageText) You may be seeing this message because you are trying to build a project without a solution file, and have specified a non-default Configuration or Platform that doesn't exist for this project.</_InvalidConfigurationMessageText>
</PropertyGroup>
<Error Condition=" '$(_InvalidConfigurationError)' == 'true' " Text="$(_InvalidConfigurationMessageText)"/>
<Warning Condition=" '$(_InvalidConfigurationWarning)' == 'true' " Text="$(_InvalidConfigurationMessageText)"/>
<Message Condition="'$(DesignTimeBuild)' != 'true'" Text="Configuration=$(Configuration)" Importance="Low" />
<Message Condition="'$(DesignTimeBuild)' != 'true'" Text="Platform=$(Platform)" Importance="Low" />
<!-- Although we try to ensure a trailing slash, it's possible to circumvent this if the property is set on the command line -->
<Error Condition="'$(OutDir)' != '' and !HasTrailingSlash('$(OutDir)')" Text="The OutDir property must end with a trailing slash." />
<Error Condition="'$(IntermediateOutputPath)' != '' and !HasTrailingSlash('$(IntermediateOutputPath)')" Text="The IntermediateOutputPath must end with a trailing slash." />
<Error Condition="'$(BaseIntermediateOutputPath)' != '' and !HasTrailingSlash('$(BaseIntermediateOutputPath)')" Text="The BaseIntermediateOutputPath must end with a trailing slash." />
<!-- Also update the value of PlatformTargetAsMSBuildArchitecture per the value of Prefer32Bit. We are doing
this here because Prefer32Bit may be set anywhere in the targets, so we can't depend on it having the
correct value when we're trying to figure out PlatformTargetAsMSBuildArchitecture -->
<PropertyGroup Condition="'$(Prefer32Bit)' == 'true' and ('$(PlatformTarget)' == 'AnyCPU' or '$(PlatformTarget)' == '') and '$(PlatformTargetAsMSBuildArchitectureExplicitlySet)' != 'true'">
<PlatformTargetAsMSBuildArchitecture>x86</PlatformTargetAsMSBuildArchitecture>
</PropertyGroup>
<!--
Log an error if the user set MSBuildProjectExtensionsPath in the body of a project. In an SDK style project
if you set a value in the body, the value is not used by the top implicit import but is used by the bottom.
This can lead to confusing behavior and builds can fail for obscure reasons.
-->
<Error Condition=" '$(_InitialMSBuildProjectExtensionsPath)' != '' And '$(MSBuildProjectExtensionsPath)' != '$(_InitialMSBuildProjectExtensionsPath)' "
Code="MSB3540"
Text="The value of the property "MSBuildProjectExtensionsPath" was modified after it was used by MSBuild which can lead to unexpected build results. To set this property, you must do so before Microsoft.Common.props is imported, for example by using Directory.Build.props. For more information, please visit https://go.microsoft.com/fwlink/?linkid=869650"
/>
<!--
Log a warning if:
1. $(EnableBaseIntermediateOutputPathMismatchWarning) is 'true'
2. $(BaseIntermediateOutputPath) was set in the body of a project after its default value was set in Microsoft.Common.props
3. $(BaseIntermediateOutputPath) is not the same as $(MSBuildProjectExtensionsPath)
Similar to the error above, there are cases when users set $(BaseIntermediateOutputPath) in the body of their project and things build but only by coincidence.
MSBuild does not know if $(BaseIntermediateOutputPath) changing would cause problems so tools like NuGet must set $(EnableBaseIntermediateOutputPathMismatchWarning)
to 'true'.
-->
<Warning Condition=" '$(EnableBaseIntermediateOutputPathMismatchWarning)' == 'true' And '$(_InitialBaseIntermediateOutputPath)' != '$(BaseIntermediateOutputPath)' And '$(BaseIntermediateOutputPath)' != '$(MSBuildProjectExtensionsPath)' "
Code="MSB3539"
Text="The value of the property "BaseIntermediateOutputPath" was modified after it was used by MSBuild which can lead to unexpected build results. Tools such as NuGet will write outputs to the path specified by the "MSBuildProjectExtensionsPath" instead. To set this property, you must do so before Microsoft.Common.props is imported, for example by using Directory.Build.props. For more information, please visit https://go.microsoft.com/fwlink/?linkid=869650"
/>
</Target>
<!--
============================================================
Build
The main build entry point.
============================================================
-->
<PropertyGroup>
<BuildDependsOn>
BeforeBuild;
CoreBuild;
AfterBuild
</BuildDependsOn>
</PropertyGroup>
<Target
Name="Build"
Condition=" '$(_InvalidConfigurationWarning)' != 'true' "
DependsOnTargets="$(BuildDependsOn)"
Returns="@(TargetPathWithTargetPlatformMoniker)" />
<!--
============================================================
BeforeBuild
Redefine this target in your project in order to run tasks just before Build
============================================================
-->
<Target Name="BeforeBuild"/>
<!--
============================================================
AfterBuild
Redefine this target in your project in order to run tasks just after Build
============================================================
-->
<Target Name="AfterBuild"/>
<!--
============================================================
CoreBuild
The core build step calls each of the build targets.
============================================================
-->
<PropertyGroup>
<CoreBuildDependsOn>
BuildOnlySettings;
PrepareForBuild;
PreBuildEvent;
ResolveReferences;
PrepareResources;
ResolveKeySource;
Compile;
ExportWindowsMDFile;
UnmanagedUnregistration;
GenerateSerializationAssemblies;
CreateSatelliteAssemblies;
GenerateManifests;
GetTargetPath;
PrepareForRun;
UnmanagedRegistration;
IncrementalClean;
PostBuildEvent
</CoreBuildDependsOn>
</PropertyGroup>
<Target
Name="CoreBuild"
DependsOnTargets="$(CoreBuildDependsOn)">
<OnError ExecuteTargets="_TimeStampAfterCompile;PostBuildEvent" Condition="'$(RunPostBuildEvent)'=='Always' or '$(RunPostBuildEvent)'=='OnOutputUpdated'"/>
<OnError ExecuteTargets="_CleanRecordFileWrites"/>
</Target>
<!--
============================================================
Rebuild
Delete all intermediate and final build outputs, and then build the project from scratch.
============================================================
-->
<PropertyGroup>
<_ProjectDefaultTargets Condition="'$(MSBuildProjectDefaultTargets)' != ''">$(MSBuildProjectDefaultTargets)</_ProjectDefaultTargets>
<_ProjectDefaultTargets Condition="'$(MSBuildProjectDefaultTargets)' == ''">Build</_ProjectDefaultTargets>
<RebuildDependsOn>
BeforeRebuild;
Clean;
$(_ProjectDefaultTargets);
AfterRebuild;
</RebuildDependsOn>
<RebuildDependsOn Condition=" '$(MSBuildProjectDefaultTargets)' == 'Rebuild' " >
BeforeRebuild;
Clean;
Build;
AfterRebuild;
</RebuildDependsOn>
</PropertyGroup>
<Target
Name="Rebuild"
Condition=" '$(_InvalidConfigurationWarning)' != 'true' "
DependsOnTargets="$(RebuildDependsOn)"
Returns="$(TargetPath)"/>
<!--
============================================================
BeforeRebuild
Redefine this target in your project in order to run tasks just before Rebuild
============================================================
-->
<Target Name="BeforeRebuild"/>
<!--
============================================================
AfterRebuild
Redefine this target in your project in order to run tasks just after Rebuild
============================================================
-->
<Target Name="AfterRebuild"/>
<!--
============================================================
BuildGenerateSources
Redefine this target in your project in order to run tasks for BuildGenerateSources
Set BuildPassReferences to enable P2P builds
============================================================
-->
<PropertyGroup>
<BuildGenerateSourcesAction>Build</BuildGenerateSourcesAction>
</PropertyGroup>
<Target Name="BuildGenerateSources" DependsOnTargets="BuildGenerateSourcesTraverse;$(BuildGenerateSourcesAction)" />
<Target Name="BuildGenerateSourcesTraverse" DependsOnTargets="PrepareProjectReferences">
<MSBuild
Projects="@(_MSBuildProjectReferenceExistent)"
Targets="BuildGenerateSources"
BuildInParallel="$(BuildInParallel)"
Properties="%(_MSBuildProjectReferenceExistent.SetConfiguration); %(_MSBuildProjectReferenceExistent.SetPlatform); %(_MSBuildProjectReferenceExistent.SetTargetFramework);"
Condition="'$(BuildPassReferences)' == 'true' and '@(ProjectReferenceWithConfiguration)' != '' and '@(_MSBuildProjectReferenceExistent)' != '' and '%(_MSBuildProjectReferenceExistent.BuildReference)' == 'true'"
ContinueOnError="!$(BuildingProject)"
RemoveProperties="%(_MSBuildProjectReferenceExistent.GlobalPropertiesToRemove)$(_GlobalPropertiesToRemoveFromProjectReferences)">
</MSBuild>
</Target>
<ItemGroup Condition="'$(IsGraphBuild)' == 'true' and '$(BuildPassReferences)' == 'true'">
<ProjectReferenceTargets Include="BuildGenerateSources" Targets="BuildGenerateSources" />
</ItemGroup>
<!--
============================================================
BuildCompile
Redefine this target in your project in order to run tasks for BuildCompile
============================================================
-->
<PropertyGroup>
<BuildCompileAction>Build</BuildCompileAction>
</PropertyGroup>
<Target Name="BuildCompile" DependsOnTargets="BuildCompileTraverse;$(BuildCompileAction)" />
<Target Name="BuildCompileTraverse" DependsOnTargets="PrepareProjectReferences">
<MSBuild
Projects="@(_MSBuildProjectReferenceExistent)"
Targets="BuildCompile"
BuildInParallel="$(BuildInParallel)"
Properties="%(_MSBuildProjectReferenceExistent.SetConfiguration); %(_MSBuildProjectReferenceExistent.SetPlatform); %(_MSBuildProjectReferenceExistent.SetTargetFramework)"
Condition="'$(BuildPassReferences)' == 'true' and '@(ProjectReferenceWithConfiguration)' != '' and '@(_MSBuildProjectReferenceExistent)' != '' and '%(_MSBuildProjectReferenceExistent.BuildReference)' == 'true'"
ContinueOnError="!$(BuildingProject)"
RemoveProperties="%(_MSBuildProjectReferenceExistent.GlobalPropertiesToRemove)$(_GlobalPropertiesToRemoveFromProjectReferences)">
</MSBuild>
</Target>
<ItemGroup Condition="'$(IsGraphBuild)' == 'true' and '$(BuildPassReferences)' == 'true'">
<ProjectReferenceTargets Include="BuildCompile" Targets="BuildCompile" />
</ItemGroup>
<!--
============================================================
BuildLink
Redefine this target in your project in order to run tasks for BuildLink
============================================================
-->
<PropertyGroup>
<BuildLinkAction>Build</BuildLinkAction>
</PropertyGroup>
<Target Name="BuildLink" DependsOnTargets="BuildLinkTraverse;$(BuildLinkAction)" />
<Target Name="BuildLinkTraverse" DependsOnTargets="PrepareProjectReferences" >
<MSBuild
Projects="@(_MSBuildProjectReferenceExistent)"
Targets="BuildLink"
BuildInParallel="$(BuildInParallel)"
Properties="%(_MSBuildProjectReferenceExistent.SetConfiguration); %(_MSBuildProjectReferenceExistent.SetPlatform); %(_MSBuildProjectReferenceExistent.SetTargetFramework)"
Condition="'$(BuildPassReferences)' == 'true' and '@(ProjectReferenceWithConfiguration)' != '' and '@(_MSBuildProjectReferenceExistent)' != '' and '%(_MSBuildProjectReferenceExistent.BuildReference)' == 'true'"
ContinueOnError="!$(BuildingProject)"
RemoveProperties="%(_MSBuildProjectReferenceExistent.GlobalPropertiesToRemove)$(_GlobalPropertiesToRemoveFromProjectReferences)">
</MSBuild>
</Target>
<ItemGroup Condition="'$(IsGraphBuild)' == 'true' and '$(BuildPassReferences)' == 'true'">
<ProjectReferenceTargets Include="BuildLink" Targets="BuildLink" />
</ItemGroup>
<!--
============================================================
CopyRunEnvironmentFiles
Copy environment files necessary to run the user's app to the final directory.
This is a public target that can be invoked by an IDE.
This may be used by an IDE to make the app.config file available for running
the target app.
============================================================
-->
<Target
Name="CopyRunEnvironmentFiles"
DependsOnTargets="PrepareForBuild;SetWin32ManifestProperties;_CopyAppConfigFile;_CleanRecordFileWrites"/>
<!--
============================================================
Run
Run the final build output if it is a .EXE
============================================================
-->
<PropertyGroup>
<RunDependsOn></RunDependsOn>
</PropertyGroup>
<Target
Name="Run"
DependsOnTargets="$(RunDependsOn)">
<Error Text="Cannot run '$(TargetPath)' because project output type is not '.exe'" Condition="'$(TargetExt)'!='.exe'"/>
<Exec Command="$(TargetPath) $(StartArguments)" WorkingDirectory="$(OutDir)" Condition=" '$(StartWorkingDirectory)' == '' "/>
<Exec Command="$(TargetPath) $(StartArguments)" WorkingDirectory="$(StartWorkingDirectory)" Condition=" '$(StartWorkingDirectory)' != '' "/>
</Target>
<!--
***********************************************************************************************
***********************************************************************************************
BuildOnlySettings Section
***********************************************************************************************
***********************************************************************************************
-->
<!--
============================================================
BuildOnlySettings
This target is called only when doing a real build. It is specifically not called during project load.
============================================================
-->
<PropertyGroup>
<BuildingProject>false</BuildingProject>
</PropertyGroup>
<Target
Name="BuildOnlySettings">
<PropertyGroup>
<BuildingProject>true</BuildingProject>
</PropertyGroup>
</Target>
<!--
***********************************************************************************************
***********************************************************************************************
PrepareForBuild Section
***********************************************************************************************
***********************************************************************************************
-->
<!--
============================================================
PrepareForBuild
Prepare the prerequisites for building.
============================================================
-->
<PropertyGroup>
<PrepareForBuildDependsOn>$(PrepareForBuildDependsOn);GetFrameworkPaths;GetReferenceAssemblyPaths;AssignLinkMetadata</PrepareForBuildDependsOn>
</PropertyGroup>
<Target
Name="PrepareForBuild"
DependsOnTargets="$(PrepareForBuildDependsOn)">
<ItemGroup>
<AppConfigWithTargetPath Include="$(AppConfig)" Condition="'$(AppConfig)'!=''">
<TargetPath>$(TargetFileName).config</TargetPath>
</AppConfigWithTargetPath>
</ItemGroup>
<FindAppConfigFile PrimaryList="@(None)" SecondaryList="@(Content)" TargetPath="$(TargetFileName).config" Condition="'$(AppConfig)'==''">
<Output TaskParameter="AppConfigFile" ItemName="AppConfigWithTargetPath"/>
<Output TaskParameter="AppConfigFile" PropertyName="AppConfig"/>
</FindAppConfigFile>
<!-- Create the directories for intermediate and final build products, and any other arbitrary directories. -->
<!-- We are going to continue on error here so that if the tree is read only we will still get intellisense -->
<MakeDir Directories="$(OutDir);$(IntermediateOutputPath);@(DocFileItem->'%(RelativeDir)');@(CreateDirectory)" ContinueOnError="true"/>
</Target>
<!--
============================================================
GetFrameworkPaths
Get the paths for the .NET Framework installation directory
These paths are not used directly by this .targets file but are available for pre and
post build steps.
============================================================
-->
<PropertyGroup>
<Framework40Dir>@(_TargetFramework40DirectoryItem)</Framework40Dir>
<Framework35Dir>@(_TargetFramework35DirectoryItem)</Framework35Dir>
<Framework30Dir>@(_TargetFramework30DirectoryItem)</Framework30Dir>
<Framework20Dir>@(_TargetFramework20DirectoryItem)</Framework20Dir>
<!-- Note we need to make the 4.0 FrameworkDir point to the 2.0 location by default since we shipped msbuild 4.0 that way and to change it would be a breaking change.-->
<FrameworkDir Condition="'$(FrameworkDir)' == '' and ('$(TargetFrameworkVersion)' == 'v2.0' or '$(TargetFrameworkVersion)' == 'v3.5' or '$(TargetFrameworkVersion)' == 'v4.0')">@(_TargetFramework20DirectoryItem)</FrameworkDir>
<FrameworkDir Condition="'$(FrameworkDir)' == ''">@(_TargetFramework40DirectoryItem)</FrameworkDir>
<TargetedFrameworkDir Condition="'$(TargetedFrameworkDir)' == ''">@(_TargetedFrameworkDirectoryItem)</TargetedFrameworkDir>
<FrameworkSDKDir Condition="'$(FrameworkSDKDir)' == ''">@(_TargetFrameworkSDKDirectoryItem)</FrameworkSDKDir>
<GetFrameworkPathsDependsOn></GetFrameworkPathsDependsOn>
</PropertyGroup>
<!-- This is a generally overriden target, for example it is overriden in the Microsoft.NETFramework.targets file -->
<Target Name="GetFrameworkPaths"/>
<!--
============================================================
GetReferenceAssemblyPaths
Get the paths for the Reference Assemblies for the known versions of the
.NET Framework.
These paths are used by the build process in order to resolve the correct
assemblies from the various directories, and to support multi-targeting
============================================================
-->
<Target
Name="GetReferenceAssemblyPaths"
DependsOnTargets="$(GetReferenceAssemblyPathsDependsOn);GetFrameworkPaths">
<!-- if TargetFrameworkDirectory doesn't have a custom value, clear it out; that way we can get reference paths and target framework directories all in the right order -->
<PropertyGroup>
<TargetFrameworkDirectory Condition="'@(_CombinedTargetFrameworkDirectoriesItem)' == '$(TargetFrameworkDirectory)'"/>
</PropertyGroup>
<!-- By default if there is no root path set then the task will assume it is Program Files\Reference Assemblies\Microsoft\Framework-->
<GetReferenceAssemblyPaths
Condition="'$(TargetFrameworkMoniker)' != '' and ('$(_TargetFrameworkDirectories)' == '' or '$(_FullFrameworkReferenceAssemblyPaths)' == '')"
TargetFrameworkMoniker="$(TargetFrameworkMoniker)"
RootPath="$(TargetFrameworkRootPath)"
TargetFrameworkFallbackSearchPaths="$(TargetFrameworkFallbackSearchPaths)"
BypassFrameworkInstallChecks="$(BypassFrameworkInstallChecks)"
ContinueOnError="!$(BuildingProject)">
<Output TaskParameter="ReferenceAssemblyPaths" PropertyName="_TargetFrameworkDirectories"/>
<Output TaskParameter="FullFrameworkReferenceAssemblyPaths" PropertyName="_FullFrameworkReferenceAssemblyPaths"/>
<Output TaskParameter="TargetFrameworkMonikerDisplayName" PropertyName="TargetFrameworkMonikerDisplayName" Condition="'$(TargetFrameworkMonikerDisplayName)' == ''"/>
</GetReferenceAssemblyPaths>
<PropertyGroup>
<TargetFrameworkDirectory>$(_TargetFrameworkDirectories);$(TargetFrameworkDirectory);$(WinFXAssemblyDirectory)</TargetFrameworkDirectory>
<TargetFrameworkDirectory Condition="'$(TargetPlatformWinMDLocation)' != '' and Exists('$(TargetPlatformWinMDLocation)')">$(TargetFrameworkDirectory);$(TargetPlatformWinMDLocation)</TargetFrameworkDirectory>
</PropertyGroup>
<!-- Remove the AssemblyFolders if no target framework directories could be found. This is to prevent us from
resolving from the assemblyfolders global location if we are not acutally targeting a framework-->
<PropertyGroup>
<RemoveAssemblyFoldersIfNoTargetFramework Condition="'$(RemoveAssemblyFoldersIfNoTargetFramework)' == ''">true</RemoveAssemblyFoldersIfNoTargetFramework>
</PropertyGroup>
<PropertyGroup Condition="'$(_TargetFrameworkDirectories)' == '' and '$(AssemblySearchPaths)' != '' and '$(RemoveAssemblyFoldersIfNoTargetFramework)' == 'true'">
<AssemblySearchPaths>$(AssemblySearchPaths.Replace('{AssemblyFolders}', '').Split(';'))</AssemblySearchPaths>
</PropertyGroup>
<ItemGroup Condition="'$(ImplicitlyExpandDesignTimeFacades)' == 'true'">
<DesignTimeFacadeDirectoryRoots Include="$(TargetFrameworkDirectory)" />
<DesignTimeFacadeDirectories Include="%(DesignTimeFacadeDirectoryRoots.Identity)Facades\" Condition="Exists('%(DesignTimeFacadeDirectoryRoots.Identity)Facades\')" />
</ItemGroup>
<PropertyGroup Condition="'@(DesignTimeFacadeDirectories)' != ''">
<TargetFrameworkDirectory>$(TargetFrameworkDirectory);@(DesignTimeFacadeDirectories)</TargetFrameworkDirectory>
</PropertyGroup>
<PropertyGroup Condition="'$(_TargetFrameworkDirectories)' == ''">
<TargetFrameworkProfile/>
</PropertyGroup>
</Target>
<!-- Returns target framework moniker. E.g. ".NETFramework,Version=v4.0.1" -->
<Target Name="GetTargetFrameworkMoniker"
Returns="$(TargetFrameworkMoniker)"/>
<!-- Returns target framework moniker display name. E.g. ".NET Framework 4 Platform Update 1 (KB2478063)" -->
<Target Name="GetTargetFrameworkMonikerDisplayName"
DependsOnTargets="GetFrameworkPaths;GetReferenceAssemblyPaths"
Returns="$(TargetFrameworkMonikerDisplayName)"/>
<!-- Returns semicolon separated list of target framework directories.
E.g "C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.0.1\;C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.0\" -->
<Target Name="GetTargetFrameworkDirectories"
DependsOnTargets="GetFrameworkPaths;GetReferenceAssemblyPaths"
Returns="$(TargetFrameworkDirectory)"/>
<!--
============================================================
AssignLinkMetadata
For items of a certain set of allowlisted types, make sure that
if they are defined in a file other than the project file, that
they have "Link" metadata set to an appropriate default.
============================================================
-->
<Target Name="AssignLinkMetadata" Condition=" '$(SynthesizeLinkMetadata)' == 'true' ">
<!-- NONE ITEMS -->
<AssignLinkMetadata Items="@(None)"
Condition="'@(None)' != '' and '%(None.DefiningProjectFullPath)' != '$(MSBuildProjectFullPath)'">
<Output TaskParameter="OutputItems" ItemName="_Temp" />
</AssignLinkMetadata>
<ItemGroup>
<None Remove="@(_Temp)" />
<None Include="@(_Temp)" />
<_Temp Remove="@(_Temp)" />
</ItemGroup>
<!-- CONTENT ITEMS -->
<AssignLinkMetadata Items="@(Content)"
Condition="'@(Content)' != '' and '%(Content.DefiningProjectFullPath)' != '$(MSBuildProjectFullPath)'">
<Output TaskParameter="OutputItems" ItemName="_Temp" />
</AssignLinkMetadata>
<ItemGroup>
<Content Remove="@(_Temp)" />
<Content Include="@(_Temp)" />
<_Temp Remove="@(_Temp)" />
</ItemGroup>
<!-- PAGE ITEMS -->
<AssignLinkMetadata Items="@(Page)"
Condition="'@(Page)' != '' and '%(Page.DefiningProjectFullPath)' != '$(MSBuildProjectFullPath)'">
<Output TaskParameter="OutputItems" ItemName="_Temp" />
</AssignLinkMetadata>
<ItemGroup>
<Page Remove="@(_Temp)" />
<Page Include="@(_Temp)" />
<_Temp Remove="@(_Temp)" />
</ItemGroup>
<!-- APPLICATIONDEFINITION ITEMS -->
<AssignLinkMetadata Items="@(ApplicationDefinition)"
Condition="'@(ApplicationDefinition)' != '' and '%(ApplicationDefinition.DefiningProjectFullPath)' != '$(MSBuildProjectFullPath)'">
<Output TaskParameter="OutputItems" ItemName="_Temp" />
</AssignLinkMetadata>
<ItemGroup>
<ApplicationDefinition Remove="@(_Temp)" />
<ApplicationDefinition Include="@(_Temp)" />
<_Temp Remove="@(_Temp)" />
</ItemGroup>
<!-- EMBEDDEDRESOURCE ITEMS -->
<AssignLinkMetadata Items="@(EmbeddedResource)"
Condition="'@(EmbeddedResource)' != '' and '%(EmbeddedResource.DefiningProjectFullPath)' != '$(MSBuildProjectFullPath)'">
<Output TaskParameter="OutputItems" ItemName="_Temp" />
</AssignLinkMetadata>
<ItemGroup>
<EmbeddedResource Remove="@(_Temp)" />
<EmbeddedResource Include="@(_Temp)" />
<_Temp Remove="@(_Temp)" />
</ItemGroup>
<!-- RESOURCE ITEMS -->
<AssignLinkMetadata Items="@(Resource)"
Condition="'@(Resource)' != '' and '%(Resource.DefiningProjectFullPath)' != '$(MSBuildProjectFullPath)' and $([MSBuild]::AreFeaturesEnabled('17.10'))">
<Output TaskParameter="OutputItems" ItemName="_Temp" />
</AssignLinkMetadata>
<ItemGroup Condition="$([MSBuild]::AreFeaturesEnabled('17.10'))">
<Resource Remove="@(_Temp)" />
<Resource Include="@(_Temp)" />
<_Temp Remove="@(_Temp)" />
</ItemGroup>
</Target>
<!--
***********************************************************************************************
***********************************************************************************************
PreBuildEvent Section
***********************************************************************************************
***********************************************************************************************
-->
<!--
============================================================
PreBuildEvent
Run the pre-build event if there is one.
============================================================
-->
<PropertyGroup>
<PreBuildEventDependsOn></PreBuildEventDependsOn>
</PropertyGroup>
<Target
Name="PreBuildEvent"
Condition="'$(PreBuildEvent)'!=''"
DependsOnTargets="$(PreBuildEventDependsOn)">
<Exec WorkingDirectory="$(OutDir)" Command="$(PreBuildEvent)" />
</Target>
<!--
***********************************************************************************************
***********************************************************************************************
UnmanagedUnregistration Section
***********************************************************************************************
***********************************************************************************************
-->
<!--
============================================================
UnmanagedUnregistration
If the main assembly had previously been registered for COM interop, unregister it now.
We will re-register the new version after it has been built.
============================================================
-->
<PropertyGroup>
<UnmanagedUnregistrationDependsOn></UnmanagedUnregistrationDependsOn>
</PropertyGroup>
<Target
Name="UnmanagedUnregistration"
Condition="(('$(_AssemblyTimestampBeforeCompile)' != '$(_AssemblyTimestampAfterCompile)' or '$(RegisterForComInterop)' != 'true' or '$(OutputType)' != 'library') or
('$(_AssemblyTimestampBeforeCompile)' == '')) and
Exists('@(_UnmanagedRegistrationCache)')"
DependsOnTargets="$(UnmanagedUnregistrationDependsOn)">
<PropertyGroup>
<UnregisterAssemblyMSBuildArchitecture Condition="'$(UnregisterAssemblyMSBuildArchitecture)' == ''">$(PlatformTargetAsMSBuildArchitecture)</UnregisterAssemblyMSBuildArchitecture>
</PropertyGroup>
<PropertyGroup Condition="'$(TargetFrameworkAsMSBuildRuntime)' != '' and '$(UnregisterAssemblyMSBuildArchitecture)' != ''">
<!-- Falling back to the current runtime if we are targeting CLR2 and the task host doesn't exist will lead to
incorrect behavior in some cases, but it's the same incorrect behavior as Visual Studio 2010, and thus better
than causing build breaks on upgrade to Win8 the way not doing so would. For more details, see the
corresponding comment in GenerateResource. -->
<UnregisterAssemblyMSBuildRuntime
Condition="'$(UnregisterAssemblyMSBuildRuntime)' == '' and
$([MSBuild]::DoesTaskHostExist(`$(TargetFrameworkAsMSBuildRuntime)`, `$(UnregisterAssemblyMSBuildArchitecture)`))">$(TargetFrameworkAsMSBuildRuntime)</UnregisterAssemblyMSBuildRuntime>
<!-- If the targeted runtime doesn't exist, fall back to current -->
<UnregisterAssemblyMSBuildRuntime Condition="'$(UnregisterAssemblyMSBuildRuntime)' == ''">CurrentRuntime</UnregisterAssemblyMSBuildRuntime>
</PropertyGroup>
<UnregisterAssembly AssemblyListFile="@(_UnmanagedRegistrationCache)"
MSBuildArchitecture="$(UnregisterAssemblyMSBuildArchitecture)"
MSBuildRuntime="$(UnregisterAssemblyMSBuildRuntime)" />
</Target>
<!--
***********************************************************************************************
***********************************************************************************************
ResolveReferences Section
***********************************************************************************************
***********************************************************************************************
-->
<!--
============================================================
GetTargetFrameworkVersion
This stand-alone target returns the target framework version (i.e. v3.5, v4.0, etc.)
that would be used if we built this project.
============================================================
-->
<Target
Name="GetTargetFrameworkVersion"
Returns="$(TargetFrameworkVersion)">
</Target>
<!--
============================================================
ResolveReferences
============================================================
-->
<PropertyGroup>
<ResolveReferencesDependsOn>
BeforeResolveReferences;
AssignProjectConfiguration;
ResolveProjectReferences;
FindInvalidProjectReferences;
ResolveNativeReferences;
ResolveAssemblyReferences;
GenerateBindingRedirects;
GenerateBindingRedirectsUpdateAppConfig;
ResolveComReferences;
AfterResolveReferences
</ResolveReferencesDependsOn>
</PropertyGroup>
<Target
Name="ResolveReferences"
Returns="@(ReferencePath)"
DependsOnTargets="$(ResolveReferencesDependsOn)"/>
<!--
============================================================
BeforeResolveReferences
Redefine this target in your project in order to run tasks just before ResolveReferences
============================================================
-->
<Target Name="BeforeResolveReferences"/>
<!--
============================================================
AfterResolveReferences
Redefine this target in your project in order to run tasks just after ResolveReferences
============================================================
-->
<Target Name="AfterResolveReferences"/>
<!--
============================================================
IgnoreJavaScriptOutputAssembly
esproj are JavaScript or TypeScript Projects that never produce an assembly.
Set ReferenceOutputAssembly to false in any reference to an esproj.
============================================================
-->
<Target Name="IgnoreJavaScriptOutputAssembly"
BeforeTargets="AssignProjectConfiguration"
Condition="$([MSBuild]::AreFeaturesEnabled('17.8'))">
<ItemGroup>
<ProjectReference Condition="'%(ProjectReference.Extension)' == '.esproj' and '%(ProjectReference.ReferenceOutputAssembly)' == ''">
<ReferenceOutputAssembly>false</ReferenceOutputAssembly>
</ProjectReference>
</ItemGroup>
</Target>
<!--
============================================================
AssignProjectConfiguration
Assigns the appropriate configuration to each project in the list of project references passed in.
Adds to the project references passed in any project references implied by dependencies expressed in the solution file, if any.
[IN]
@(ProjectReference) - the list of all project references
[OUT]
@(ProjectReferenceWithConfiguration) - the list of project references (MSBuild and potentially VSIP projects)
with metadata values FullConfiguration, Configuration, Platform,
SetConfiguration, and SetPlatform
============================================================
-->
<Target
Name="AssignProjectConfiguration"
Condition="'$(CurrentSolutionConfigurationContents)' != '' or '@(ProjectReference)'!=''">
<PropertyGroup>
<OnlyReferenceAndBuildProjectsEnabledInSolutionConfiguration Condition="'$(OnlyReferenceAndBuildProjectsEnabledInSolutionConfiguration)' == ''">true</OnlyReferenceAndBuildProjectsEnabledInSolutionConfiguration>
<ShouldUnsetParentConfigurationAndPlatform Condition="'$(ShouldUnsetParentConfigurationAndPlatform)' == '' and ('$(BuildingInsideVisualStudio)' == 'true' or '$(BuildingSolutionFile)' == 'true')">true</ShouldUnsetParentConfigurationAndPlatform>
<ShouldUnsetParentConfigurationAndPlatform Condition="'$(ShouldUnsetParentConfigurationAndPlatform)' == ''">false</ShouldUnsetParentConfigurationAndPlatform>
<!-- Web Application projects can "secretly" reference Silverlight projects, which can take project dependencies on that same Web Application. If the project
dependencies are promoted to project references, this ends up creating a situation where we have a circular reference between the two projects. We don't
want this to happen, so just turn off synthetic project reference generation for Silverlight projects. -->
<AddSyntheticProjectReferencesForSolutionDependencies Condition="'$(AddSyntheticProjectReferencesForSolutionDependencies)' == '' and '$(TargetFrameworkIdentifier)' == 'Silverlight'">false</AddSyntheticProjectReferencesForSolutionDependencies>
<!-- Inside VS, we do not need to add synthetic references, as VS already organizes the build per any solution-level dependencies; we only do this on the command line-->
<AddSyntheticProjectReferencesForSolutionDependencies Condition="'$(AddSyntheticProjectReferencesForSolutionDependencies)' == '' and '$(BuildingInsideVisualStudio)' != 'true'">true</AddSyntheticProjectReferencesForSolutionDependencies>
</PropertyGroup>
<!-- Assign a project configuration to each project reference if we're building a solution file. -->
<AssignProjectConfiguration
ProjectReferences="@(ProjectReference)"
CurrentProject="$(MSBuildProjectFullPath)"
CurrentProjectConfiguration="$(Configuration)"
CurrentProjectPlatform="$(Platform)"
DefaultToVcxPlatformMapping="$(DefaultToVcxPlatformMapping)"
VcxToDefaultPlatformMapping="$(VcxToDefaultPlatformMapping)"
OutputType="$(OutputType)"
ResolveConfigurationPlatformUsingMappings="false"
SolutionConfigurationContents="$(CurrentSolutionConfigurationContents)"
AddSyntheticProjectReferencesForSolutionDependencies="$(AddSyntheticProjectReferencesForSolutionDependencies)"
OnlyReferenceAndBuildProjectsEnabledInSolutionConfiguration = "$(OnlyReferenceAndBuildProjectsEnabledInSolutionConfiguration)"
ShouldUnsetParentConfigurationAndPlatform = "$(ShouldUnsetParentConfigurationAndPlatform)" >
<!-- EMITTED FOR COMPATIBILITY REASONS ONLY. CONSUME PROJECTREFERENCEWITHCONFIGURATION INSTEAD -->
<Output TaskParameter="AssignedProjects" ItemName="_ProjectReferenceWithConfiguration"/>
<Output TaskParameter="UnassignedProjects" ItemName="_ProjectReferenceWithConfiguration"/>
<Output TaskParameter="AssignedProjects" ItemName="ProjectReferenceWithConfiguration"/>
<Output TaskParameter="UnassignedProjects" ItemName="ProjectReferenceWithConfiguration"/>
</AssignProjectConfiguration>
<ItemGroup>
<_ProjectReferenceWithConfiguration>
<BuildReference Condition="'%(_ProjectReferenceWithConfiguration.BuildReference)' == ''">true</BuildReference>
<ReferenceOutputAssembly Condition="'%(_ProjectReferenceWithConfiguration.ReferenceOutputAssembly)' == ''">true</ReferenceOutputAssembly>
</_ProjectReferenceWithConfiguration>
<ProjectReferenceWithConfiguration>
<BuildReference Condition="'%(ProjectReferenceWithConfiguration.BuildReference)' == ''">true</BuildReference>
<ReferenceOutputAssembly Condition="'%(ProjectReferenceWithConfiguration.ReferenceOutputAssembly)' == ''">true</ReferenceOutputAssembly>
</ProjectReferenceWithConfiguration>
</ItemGroup>
</Target>
<!--
============================================================
_SplitProjectReferencesByFileExistence
Split referenced projects into two lists: those that exist on
disk and those that don't.
============================================================
-->
<Target
Name="_SplitProjectReferencesByFileExistence">
<!--
Use this task for matching projects with pre-resolved project outputs set by the IDE
if building inside the IDE. The IDE only includes non-MSBuild projects in the output list. We'll
use MSBuild to resolve MSBuild projects.
This task will resolve VSIP (3rd party) project references and create a new item list with only project references
to projects in the MSBuild format.
-->
<ResolveNonMSBuildProjectOutput
ProjectReferences="@(ProjectReferenceWithConfiguration)"
PreresolvedProjectOutputs="$(VSIDEResolvedNonMSBuildProjectOutputs)"
Condition="'$(BuildingInsideVisualStudio)'=='true' and '@(ProjectReferenceWithConfiguration)'!=''">
<Output TaskParameter="ResolvedOutputPaths" ItemName="_ResolvedProjectReferencePaths"/>
<Output TaskParameter="UnresolvedProjectReferences" ItemName="_MSBuildProjectReference"/>
</ResolveNonMSBuildProjectOutput>
<!--
If building from the command line, simply copy the ProjectReferenceWithConfiguration item list to _MSBuildProjectReference,
since we have to assume all projects are in the MSBuild format. We have no way of building
VSIP (3rd party) projects from the command line.
-->
<ItemGroup>
<_MSBuildProjectReference Include="@(ProjectReferenceWithConfiguration)" Condition="'$(BuildingInsideVisualStudio)'!='true' and '@(ProjectReferenceWithConfiguration)'!=''"/>
</ItemGroup>
<!-- Break the project list into two lists: those that exist on disk and those that don't. -->
<ItemGroup>
<_MSBuildProjectReferenceExistent Include="@(_MSBuildProjectReference)" Condition="Exists('%(Identity)')"/>
<_MSBuildProjectReferenceNonexistent Include="@(_MSBuildProjectReference)" Condition="!Exists('%(Identity)')"/>
</ItemGroup>
</Target>
<!--
====================================================================================
_GetProjectReferencePlatformProperties
If a project is opted in via $(EnableDynamicPlatformResolution), this target calls the
GetCompatiblePlatform task on all ProjectReference items to determine the most compatible
platform for each project. It then sets SetPlatform metadata on each ProjectReference.
This prevents overbuilding a project when 'AnyCPU' is available.
======================================================================================
-->
<PropertyGroup>
<UseDefaultPlatformLookupTables Condition="'$(UseDefaultPlatformLookupTables)' == ''">true</UseDefaultPlatformLookupTables>
</PropertyGroup>
<!-- This target skips sln-based builds because they already supply Platform and
Configuration information. See AssignProjectConfiguration -->
<Target Name="_GetProjectReferencePlatformProperties"
Condition="'$(EnableDynamicPlatformResolution)' == 'true'
and '@(_MSBuildProjectReferenceExistent)' != ''">
<!-- Allow preset SetPlatform to override this operation -->
<ItemGroup>
<_MSBuildProjectReferenceExistent Condition="'%(_MSBuildProjectReferenceExistent.SetPlatform)' != ''">
<SkipGetPlatformProperties>true</SkipGetPlatformProperties>
</_MSBuildProjectReferenceExistent>
</ItemGroup>
<ItemGroup>
<_ProjectReferencePlatformPossibilities Include="@(_MSBuildProjectReferenceExistent)"
Condition="'%(_MSBuildProjectReferenceExistent.SkipGetPlatformProperties)' != 'true'"/>
</ItemGroup>
<!-- Assign default PlatformLookupTables when doing Managed <-> Unmanaged hops -->
<ItemGroup>
<!-- If we're looking at a c++ project from a managed project, map managed platforms to native platforms. -->
<_ProjectReferencePlatformPossibilities Condition="'$(MSBuildProjectExtension)' != '.vcxproj' and '$(MSBuildProjectExtension)' != '.nativeproj' and '%(_ProjectReferencePlatformPossibilities.IsVcxOrNativeProj)' == 'true'">
<!-- Taken from https://docs.microsoft.com/visualstudio/msbuild/assignprojectconfiguration-task -->
<PlatformLookupTable Condition="'$(UseDefaultPlatformLookupTables)' == 'true' and '$(PlatformLookupTable)' == ''">x86=Win32</PlatformLookupTable>
</_ProjectReferencePlatformPossibilities>
<!-- If we're looking at a managed project from a cpp project, map native to managed platforms. -->
<_ProjectReferencePlatformPossibilities Condition="('$(MSBuildProjectExtension)' == '.vcxproj' or '$(MSBuildProjectExtension)' == '.nativeproj') and '%(_ProjectReferencePlatformPossibilities.IsVcxOrNativeProj)' != 'true'">
<PlatformLookupTable Condition="'$(UseDefaultPlatformLookupTables)' == 'true' and '$(PlatformLookupTable)' == ''">Win32=x86</PlatformLookupTable>
</_ProjectReferencePlatformPossibilities>
</ItemGroup>
<GetCompatiblePlatform AnnotatedProjects="@(_ProjectReferencePlatformPossibilities)"
CurrentProjectPlatform="$(Platform)"
PlatformLookupTable="$(PlatformLookupTable)"
Condition="'@(_ProjectReferencePlatformPossibilities)' != ''">
<Output ItemName="_ProjectsWithPlatformAssignment" TaskParameter="AssignedProjectsWithPlatform" />
</GetCompatiblePlatform>
<!-- If GetCompatiblePlatform didn't run, @(ProjectsWithPlatformAssignment) will be empty.
Don't do anything in this case. Ex: A project references many projects
that can't multiplatform. -->
<ItemGroup Condition="'@(_ProjectsWithPlatformAssignment)' != ''">
<ProjectsWithNearestPlatform Include="@(_ProjectsWithPlatformAssignment)"/>
<ProjectsWithNearestPlatform Condition="'@(ProjectsWithNearestPlatform)' == '%(Identity)' and '%(ProjectsWithNearestPlatform.NearestPlatform)' != ''">
<SetPlatform>Platform=%(ProjectsWithNearestPlatform.NearestPlatform)</SetPlatform>
</ProjectsWithNearestPlatform>
<!-- When GetCompatiblePlatform fails to assign NearestPlatform, undefine Platform and let that project build "on its own" -->
<ProjectsWithNearestPlatform Condition="'@(ProjectsWithNearestPlatform)' == '%(Identity)' and '%(ProjectsWithNearestPlatform.NearestPlatform)' == ''">
<UndefineProperties>%(ProjectsWithNearestPlatform.UndefineProperties);Platform</UndefineProperties>
</ProjectsWithNearestPlatform>
<_MSBuildProjectReferenceExistent Remove="@(_MSBuildProjectReferenceExistent)" Condition="'%(_MSBuildProjectReferenceExistent.SkipGetPlatformProperties)' != 'true'"/>
<_MSBuildProjectReferenceExistent Include="@(ProjectsWithNearestPlatform)"/>
</ItemGroup>
</Target>
<!--
====================================================================================
_GetProjectReferenceTargetFrameworkProperties
Builds the GetTargetFrameworks target of all existent project references to get a list
of all supported TargetFrameworks of the referenced projects. Calls the
GetReferenceNearestTargetFrameworkTask to determine the closest match for each project.
This allows a cross-targeting project to select how it should be configured to build
against the most appropriate target for the referring target framework.
======================================================================================
-->
<Target Name="_GetProjectReferenceTargetFrameworkProperties" DependsOnTargets="_AddOutputPathToGlobalPropertiesToRemove">
<!--
Select the moniker to send to each project reference if not already set. NugetTargetMoniker (NTM) is preferred by default over
TargetFrameworkMoniker (TFM) because it is required to disambiguate the UWP case where TFM is fixed at .NETCore,Version=v5.0 and
has floating NTM=UAP,Version=vX.Y.Z. However, in other cases (classic PCLs), NTM contains multiple values and that will cause the MSBuild
invocation below to fail by passing invalid properties. Therefore we do not use the NTM if it contains a semicolon.
-->
<PropertyGroup Condition="'$(ReferringTargetFrameworkForProjectReferences)' == ''">
<ReferringTargetFrameworkForProjectReferences Condition="'$(NuGetTargetMoniker)' != '' and !$(NuGetTargetMoniker.Contains(';'))">$(NuGetTargetMoniker)</ReferringTargetFrameworkForProjectReferences>
<ReferringTargetFrameworkForProjectReferences Condition="'$(NuGetTargetMoniker)' == ''">$(TargetFrameworkMoniker)</ReferringTargetFrameworkForProjectReferences>
</PropertyGroup>
<!--
Honor SkipGetTargetFrameworkProperties=true metadata on project references
to mean that the project reference is known not to target multiple frameworks
and the mechanism here for selecting the best one can be skipped as an optimization.
We give this treatment to .vcxproj by default since no .vcxproj can target more
than one framework currently. The user must specify exactly one TargetFramework.
vcxproj files compile down to OS-specific binaries, either native or .NET. In the
_GetProjectReferenceTargetFrameworkProperties target of Microsoft.Common.CurrentVersion.targets,
SkipTargetFrameworkProperties is set to true for vcxproj to account for that.
This means we do not fill the Item _ProjectReferenceTargetFrameworkPossibilities or, by extension,
the AnnotatedProjects Item.
For single-targeted projects, we normally decorate the AnnotatedProjects Item with
UndefineProperties metadata specifying that TargetFramework should be undefined. Because it
isn't defined properly at that stage, however, this does not happen, and TargetFramework is
defined at this point in addition to having been defined globally. Currently, this is always
true for vcxproj.
MSBuild permits building the same project twice as long as it has different sets of global properties.
Because the TargetFramework global property is not being removed as expected by the multitargeting
part of MSBuild, the engine recognizes that there are differences and builds it twice. This can
become more noticeable if the projects build in parallel, since they could try to access the same
resources and conflict, failing the build. Note, however, that building the same project twice in
this way is always wrong even if it seems minor because they do not conflict, and the second build is
relatively fast.
-->
<ItemGroup>
<_MSBuildProjectReferenceExistent Condition="'%(_MSBuildProjectReferenceExistent.SkipGetTargetFrameworkProperties)' == '' and ('%(Extension)' == '.vcxproj' or '%(Extension)' == '.nativeproj')">
<!--
Platform negotiation requires the MSBuild task call to GetTargetFrameworks.
Don't skip when opted into the feature.
-->
<SkipGetTargetFrameworkProperties Condition="'$(EnableDynamicPlatformResolution)' != 'true'">true</SkipGetTargetFrameworkProperties>
<UndefineProperties>%(_MSBuildProjectReferenceExistent.UndefineProperties);TargetFramework</UndefineProperties>
</_MSBuildProjectReferenceExistent>
</ItemGroup>
<!--
Allow project references to specify which target framework properties to set and their values
without consulting the referenced project. This has two use cases:
1. A caller may wish to pick a compatible but sub-optimal target framework. For example,
to unit test the .NETStandard implementation using a .NETFramework caller even though
there is also a .NETFramework implementation.
2. As an escape hatch for cases where the compatibility check performed by
GetTargetFrameworkProperties is faulty.
-->
<ItemGroup>
<_MSBuildProjectReferenceExistent Condition="'%(_MSBuildProjectReferenceExistent.SetTargetFramework)' != ''">
<!--
Platform negotiation requires the MSBuild task call to GetTargetFrameworks.
Don't skip when opted into the feature.
-->
<SkipGetTargetFrameworkProperties Condition="'$(EnableDynamicPlatformResolution)' != 'true'">true</SkipGetTargetFrameworkProperties>
</_MSBuildProjectReferenceExistent>
</ItemGroup>
<!--
Get reference target framework lists.
Note: A future optimization could cache the closest match and set the target framework on
this MSBuild task invocation. This would (optimistically) save an evaluation of the referenced
project when the answer is the same.
-->
<MSBuild
Projects="@(_MSBuildProjectReferenceExistent)"
Targets="GetTargetFrameworks"
BuildInParallel="$(BuildInParallel)"
Properties="%(_MSBuildProjectReferenceExistent.SetConfiguration); %(_MSBuildProjectReferenceExistent.SetPlatform)"
ContinueOnError="!$(BuildingProject)"
RemoveProperties="%(_MSBuildProjectReferenceExistent.GlobalPropertiesToRemove);TargetFramework;RuntimeIdentifier;SelfContained;$(_GlobalPropertiesToRemoveFromProjectReferences)"
Condition="'%(_MSBuildProjectReferenceExistent.SkipGetTargetFrameworkProperties)' != 'true' and '$(EnableDynamicPlatformResolution)' != 'true'"
SkipNonexistentTargets="true">
<Output TaskParameter="TargetOutputs" ItemName="_ProjectReferenceTargetFrameworkPossibilities" />
</MSBuild>
<!--
SetPlatform negotiation requires the 'GetTargetFrameworks' MSBuild call to NOT pass global properties. This is to verify
whether or not the referenced project would build as the same platform as the current project by default. The above
MSBuild call is kept for legacy scenarios that may depend on passing %(SetConfiguration) and %(SetPlatform).
-->
<MSBuild
Projects="@(_MSBuildProjectReferenceExistent)"
Targets="GetTargetFrameworks"
BuildInParallel="$(BuildInParallel)"
ContinueOnError="!$(BuildingProject)"
RemoveProperties="%(_MSBuildProjectReferenceExistent.GlobalPropertiesToRemove);TargetFramework;RuntimeIdentifier;SelfContained;Platform;Configuration;$(_GlobalPropertiesToRemoveFromProjectReferences)"
Condition="'%(_MSBuildProjectReferenceExistent.SkipGetTargetFrameworkProperties)' != 'true' and '$(EnableDynamicPlatformResolution)' == 'true'"
SkipNonexistentTargets="true">
<Output TaskParameter="TargetOutputs" ItemName="_ProjectReferenceTargetFrameworkPossibilities" />
</MSBuild>
<ItemGroup>
<!--
Preserve the ItemSpec value on the _ProjectReferenceTargetFrameworkPossibilities. Because relative paths in another project
context would be incorrect, the MSBuild task invocation needs expands the project reference paths in the MSBuild task above.
This is generally OK, but if the list is copied the OriginalItemSpec can become the expanded value and cause issues correlating
a project reference back to an Item instance.
-->
<_ProjectReferenceTargetFrameworkPossibilitiesOriginalItemSpec Include="@(_ProjectReferenceTargetFrameworkPossibilities->'%(OriginalItemSpec)')"/>
<_ProjectReferenceTargetFrameworkPossibilities Remove="@(_ProjectReferenceTargetFrameworkPossibilities)" />
<_ProjectReferenceTargetFrameworkPossibilities Include="@(_ProjectReferenceTargetFrameworkPossibilitiesOriginalItemSpec)"/>
</ItemGroup>
<!-- For each reference, get closest match -->
<!-- Pass the CurrentProjectTargetPlatform parameter to the task only if GetReferenceNearestTargetFrameworkTaskSupportsTargetPlatformParameter is true. This means
that we are using a version of NuGet which supports that parameter on this task. -->
<GetReferenceNearestTargetFrameworkTask AnnotatedProjectReferences="@(_ProjectReferenceTargetFrameworkPossibilities)"
CurrentProjectTargetFramework="$(ReferringTargetFrameworkForProjectReferences)"
CurrentProjectTargetPlatform="$(TargetPlatformMoniker)"
CurrentProjectName="$(MSBuildProjectName)"
FallbackTargetFrameworks="$(AssetTargetFallback)"
Condition="'@(_ProjectReferenceTargetFrameworkPossibilities)' != '' and '$(ReferringTargetFrameworkForProjectReferences)' != ''
And '$(GetReferenceNearestTargetFrameworkTaskSupportsTargetPlatformParameter)' == 'true' and '%(_ProjectReferenceTargetFrameworkPossibilities.IsVcxOrNativeProj)' != 'true'">
<Output ItemName="AnnotatedProjects" TaskParameter="AssignedProjects" />
</GetReferenceNearestTargetFrameworkTask>
<GetReferenceNearestTargetFrameworkTask AnnotatedProjectReferences="@(_ProjectReferenceTargetFrameworkPossibilities)"
CurrentProjectTargetFramework="$(ReferringTargetFrameworkForProjectReferences)"
CurrentProjectName="$(MSBuildProjectName)"
FallbackTargetFrameworks="$(AssetTargetFallback)"
Condition="'@(_ProjectReferenceTargetFrameworkPossibilities)' != '' and '$(ReferringTargetFrameworkForProjectReferences)' != ''
And '$(GetReferenceNearestTargetFrameworkTaskSupportsTargetPlatformParameter)' != 'true' and '%(_ProjectReferenceTargetFrameworkPossibilities.IsVcxOrNativeProj)' != 'true'">
<Output ItemName="AnnotatedProjects" TaskParameter="AssignedProjects" />
</GetReferenceNearestTargetFrameworkTask>
<ItemGroup>
<!--
If the task was skipped or the current TargetFramework is empty, AnnotatedProjects will be empty.
In this case, copy _ProjectReferenceTargetFrameworkPossibilities as is. See:
https://github.com/dotnet/sdk/issues/416
Furthermore, if we're referencing a .vcxproj or .nativeproj, those items won't be populated into `AnnotatedProjects`
by `GetReferenceNearestTargetFrameworkTask`, so let them flow when `EnableDynamicPlatformResolution` is set.
-->
<AnnotatedProjects Include="@(_ProjectReferenceTargetFrameworkPossibilities)"
Condition="'$(ReferringTargetFrameworkForProjectReferences)' == '' or
('$(EnableDynamicPlatformResolution)' == 'true' and '%(_ProjectReferenceTargetFrameworkPossibilities.IsVcxOrNativeProj)' == 'true')" />
</ItemGroup>
<!-- IsRidAgnostic metadata is used to determine whether global properties such as RuntimeIdentifier and SelfContained flow to a referenced project.
However, for multi-targeted projects there may be a different IsRidAgnostic value for each TargetFramework. In that case, this task selects
the IsRidAgnostic value for the NearestTargetFramework for the project. -->
<SetRidAgnosticValueForProjects Projects="@(AnnotatedProjects)">
<Output ItemName="UpdatedAnnotatedProjects" TaskParameter="UpdatedProjects" />
</SetRidAgnosticValueForProjects>
<ItemGroup>
<AnnotatedProjects Remove="@(AnnotatedProjects)" />
<AnnotatedProjects Include="@(UpdatedAnnotatedProjects)" />
<UpdatedAnnotatedProjects Remove="@(UpdatedAnnotatedProjects)" />
<!-- If the NearestTargetFramework property was set and the project multi-targets, SetTargetFramework must be set. -->
<AnnotatedProjects Condition="'@(AnnotatedProjects)' == '%(Identity)' and '%(AnnotatedProjects.NearestTargetFramework)' != '' and '%(AnnotatedProjects.HasSingleTargetFramework)' != 'true'">
<SetTargetFramework>TargetFramework=%(AnnotatedProjects.NearestTargetFramework)</SetTargetFramework>
</AnnotatedProjects>
<!--
If the NearestTargetFramework property was not set or the project has a single TargetFramework, we need to Undefine
TargetFramework to avoid another project evaluation.
-->
<AnnotatedProjects Condition="'@(AnnotatedProjects)' == '%(Identity)' and ('%(AnnotatedProjects.NearestTargetFramework)' == '' or '%(AnnotatedProjects.HasSingleTargetFramework)' == 'true')">
<UndefineProperties>%(AnnotatedProjects.UndefineProperties);TargetFramework</UndefineProperties>
</AnnotatedProjects>
<!-- Add RuntimeIdentifier and SelfContained to the list of global properties that should not flow to the referenced project,
unless the project is expecting those properties to flow. -->
<AnnotatedProjects Condition="'@(AnnotatedProjects)' == '%(Identity)' and '%(AnnotatedProjects.IsRidAgnostic)' != 'false'">
<UndefineProperties>%(AnnotatedProjects.UndefineProperties);RuntimeIdentifier;SelfContained</UndefineProperties>
</AnnotatedProjects>
<!--
Remove the items we've touched from _MSBuildProjectReferenceExistent. This will leave all projects where
SkipGetTargetFrameworkProperties was set. Then add all AnnotatedProjects back.
-->
<_MSBuildProjectReferenceExistent Remove="@(_MSBuildProjectReferenceExistent)" Condition="'%(_MSBuildProjectReferenceExistent.SkipGetTargetFrameworkProperties)' != 'true'" />
<_MSBuildProjectReferenceExistent Include="@(AnnotatedProjects)" />
</ItemGroup>
</Target>
<Target Name="GetTargetFrameworks"
DependsOnTargets="GetTargetFrameworksWithPlatformForSingleTargetFramework"
Returns="@(_ThisProjectBuildMetadata)">
<Error Condition="'$(IsCrossTargetingBuild)' == 'true'"
Text="Internal MSBuild error: Non-CrossTargeting GetTargetFrameworks target should not be used in cross targeting (outer) build" />
<CombineXmlElements
RootElementName="AdditionalProjectProperties"
XmlElements="@(_TargetFrameworkInfo->'%(AdditionalPropertiesFromProject)')">
<Output TaskParameter="Result"
PropertyName="_AdditionalPropertiesFromProject"/>
</CombineXmlElements>
<ItemGroup>
<_ThisProjectBuildMetadata Include="$(MSBuildProjectFullPath)">
<TargetFrameworks>@(_TargetFrameworkInfo)</TargetFrameworks>
<TargetFrameworkMonikers>@(_TargetFrameworkInfo->'%(TargetFrameworkMonikers)')</TargetFrameworkMonikers>
<TargetPlatformMonikers>@(_TargetFrameworkInfo->'%(TargetPlatformMonikers)')</TargetPlatformMonikers>
<AdditionalPropertiesFromProject>$(_AdditionalPropertiesFromProject)</AdditionalPropertiesFromProject>
<HasSingleTargetFramework>true</HasSingleTargetFramework>
<IsRidAgnostic>@(_TargetFrameworkInfo->'%(IsRidAgnostic)')</IsRidAgnostic>
<!-- Extract necessary information for SetPlatform negotiation -->
<IsVcxOrNativeProj Condition="'$(MSBuildProjectExtension)' == '.vcxproj' or '$(MSBuildProjectExtension)' == '.nativeproj'">true</IsVcxOrNativeProj>
<Platform Condition="$([MSBuild]::AreFeaturesEnabled('17.4'))">$(Platform)</Platform>
<Platforms>$(Platforms)</Platforms>
<!-- .vcxproj and .nativeproj contain a `ProjectConfiguration` item that have `Platform` metadata within.
Build the `Platforms` property from that. -->
<Platforms Condition="'$(UsePlatformFromProjectConfiguration)' != 'false' and '@(ProjectConfiguration)' != '' and ('$(MSBuildProjectExtension)' == '.vcxproj' or '$(MSBuildProjectExtension)' == '.nativeproj')">@(ProjectConfiguration->'%(Platform)'->Distinct())</Platforms>
</_ThisProjectBuildMetadata>
</ItemGroup>
</Target>
<Target Name="GetTargetFrameworksWithPlatformForSingleTargetFramework"
Returns="@(_TargetFrameworkInfo)">
<ItemGroup>
<_AdditionalTargetFrameworkInfoPropertyWithValue Include="@(AdditionalTargetFrameworkInfoProperty)">
<Value>$(%(AdditionalTargetFrameworkInfoProperty.Identity))</Value>
</_AdditionalTargetFrameworkInfoPropertyWithValue>
</ItemGroup>
<PropertyGroup>
<_UseAttributeForTargetFrameworkInfoPropertyNames Condition="'$(_UseAttributeForTargetFrameworkInfoPropertyNames)' == ''">false</_UseAttributeForTargetFrameworkInfoPropertyNames>
</PropertyGroup>
<CombineTargetFrameworkInfoProperties
RootElementName="$(TargetFramework)"
PropertiesAndValues="@(_AdditionalTargetFrameworkInfoPropertyWithValue)"
UseAttributeForTargetFrameworkInfoPropertyNames="$(_UseAttributeForTargetFrameworkInfoPropertyNames)">
<Output TaskParameter="Result"
PropertyName="_AdditionalTargetFrameworkInfoProperties"/>
</CombineTargetFrameworkInfoProperties>
<ItemGroup>
<_TargetFrameworkInfo Include="$(TargetFramework)">
<TargetFrameworks>$(TargetFramework)</TargetFrameworks>
<TargetFrameworkMonikers>$(TargetFrameworkMoniker)</TargetFrameworkMonikers>
<TargetPlatformMonikers>$(TargetPlatformMoniker)</TargetPlatformMonikers>
<TargetPlatformMonikers Condition="'$(TargetPlatformMoniker)' == ''">None</TargetPlatformMonikers>
<AdditionalPropertiesFromProject>$(_AdditionalTargetFrameworkInfoProperties)</AdditionalPropertiesFromProject>
<!-- Determine whether a project is "RID agnostic" for each TargetFramework. "RID agnostic" means that global properties such as
SelfContained and RuntimeIdentifier should not flow across project references. The IsRidAgnostic metadata value is consumed in the
_GetProjectReferenceTargetFrameworkProperties target, where those properties are added to a project's UndefineProperties if
IsRidAgnostic is set.
Generally we set the IsRidAgnostic metadata based on the IsRidAgnostic property set by the .NET SDK. If that's not set, then the
fallback logic here will be that the project is RID agnostic if it doesn't have RuntimeIdentifier or RuntimeIdentifiers properties set. -->
<IsRidAgnostic>$(IsRidAgnostic)</IsRidAgnostic>
<IsRidAgnostic Condition=" '%(IsRidAgnostic)' == '' and '$(RuntimeIdentifier)' == '' and '$(RuntimeIdentifiers)' == '' ">true</IsRidAgnostic>
<IsRidAgnostic Condition=" '%(IsRidAgnostic)' == ''">false</IsRidAgnostic>
</_TargetFrameworkInfo>
</ItemGroup>
</Target>
<!--
============================================================
GetTargetFrameworkProperties
OBSOLETE: present only for theoretical backward compatibility.
-->
<Target Name="GetTargetFrameworkProperties" />
<!--
============================================================
PrepareProjectReferences
Prepares project references for consumption by other targets.
[IN]
@(ProjectReference) - The list of project references.
[OUT]
@(ProjectReferenceWithConfiguration) - Project references with apporpriate metadata
@(_MSBuildProjectReferenceExistent) - Subset of @(ProjectReferenceWithConfiguration) that exist
with added SetTargetFramework metadata for cross-targeting
@(_MSBuildProjectReferenceNonExistent) - Subset of @(ProjectReferenceWithConfiguration) that do not exist
============================================================
-->
<PropertyGroup>
<PrepareProjectReferencesDependsOn>
AssignProjectConfiguration;
_SplitProjectReferencesByFileExistence;
_GetProjectReferenceTargetFrameworkProperties;
_GetProjectReferencePlatformProperties
</PrepareProjectReferencesDependsOn>
</PropertyGroup>
<Target Name="PrepareProjectReferences" DependsOnTargets="$(PrepareProjectReferencesDependsOn)" />
<!--
============================================================
ResolveProjectReferences
Build referenced projects:
[IN]
@(ProjectReferenceWithConfiguration) - The list of project references.
[OUT]
@(_ResolvedNativeProjectReferencePaths) - Paths to referenced native projects.
@(_ResolvedProjectReferencePaths) - Paths to referenced managed projects.
============================================================
-->
<!-- By default, the outputs of project references are passed to the compiler -->
<ItemDefinitionGroup>
<ProjectReference>
<!-- Target to build in the project reference; by default, this property is blank, indicating the default targets-->
<Targets>$(ProjectReferenceBuildTargets)</Targets>
<!-- Extra item type to emit outputs of the destination into. Defaults to blank. To emit only into this list, set the ReferenceOutputAssembly metadata to false as well. -->
<OutputItemType/>
<ReferenceSourceTarget>ProjectReference</ReferenceSourceTarget>
</ProjectReference>
</ItemDefinitionGroup>
<Target
Name="ResolveProjectReferences"
DependsOnTargets="PrepareProjectReferences"
Returns="@(_ResolvedNativeProjectReferencePaths);@(_ResolvedProjectReferencePaths)">
<!--
When building this project from the IDE, just gather the referenced build outputs.
The IDE will already have built the project, so there's no need to do it again here.
The ContinueOnError setting is here so that, during project load, as
much information as possible will be passed to the compilers.
-->
<MSBuild
Projects="@(_MSBuildProjectReferenceExistent)"
Targets="GetTargetPath"
BuildInParallel="$(BuildInParallel)"
Properties="%(_MSBuildProjectReferenceExistent.SetConfiguration); %(_MSBuildProjectReferenceExistent.SetPlatform); %(_MSBuildProjectReferenceExistent.SetTargetFramework)"
Condition="'%(_MSBuildProjectReferenceExistent.BuildReference)' == 'true' and '@(ProjectReferenceWithConfiguration)' != '' and ('$(BuildingInsideVisualStudio)' == 'true' or '$(BuildProjectReferences)' != 'true') and '$(VisualStudioVersion)' != '10.0' and '@(_MSBuildProjectReferenceExistent)' != ''"
ContinueOnError="!$(BuildingProject)"
RemoveProperties="%(_MSBuildProjectReferenceExistent.GlobalPropertiesToRemove)$(_GlobalPropertiesToRemoveFromProjectReferences)">
<Output TaskParameter="TargetOutputs" ItemName="_ResolvedProjectReferencePaths" Condition="'%(_MSBuildProjectReferenceExistent.ReferenceOutputAssembly)'=='true'"/>
<Output TaskParameter="TargetOutputs" ItemName="%(_MSBuildProjectReferenceExistent.OutputItemType)" Condition="'%(_MSBuildProjectReferenceExistent.OutputItemType)' != ''"/>
</MSBuild>
<!--
Build referenced projects when building from the command line.
-->
<MSBuild
Projects="@(_MSBuildProjectReferenceExistent)"
Targets="%(_MSBuildProjectReferenceExistent.Targets)"
BuildInParallel="$(BuildInParallel)"
Properties="%(_MSBuildProjectReferenceExistent.SetConfiguration); %(_MSBuildProjectReferenceExistent.SetPlatform); %(_MSBuildProjectReferenceExistent.SetTargetFramework)"
Condition="'%(_MSBuildProjectReferenceExistent.BuildReference)' == 'true' and '@(ProjectReferenceWithConfiguration)' != '' and '$(BuildingInsideVisualStudio)' != 'true' and '$(BuildProjectReferences)' == 'true' and '@(_MSBuildProjectReferenceExistent)' != ''"
ContinueOnError="$(ContinueOnError)"
RemoveProperties="%(_MSBuildProjectReferenceExistent.GlobalPropertiesToRemove)$(_GlobalPropertiesToRemoveFromProjectReferences)">
<Output TaskParameter="TargetOutputs" ItemName="_ResolvedProjectReferencePaths" Condition="'%(_MSBuildProjectReferenceExistent.ReferenceOutputAssembly)'=='true' or '$(DesignTimeBuild)' == 'true'"/>
<Output TaskParameter="TargetOutputs" ItemName="%(_MSBuildProjectReferenceExistent.OutputItemType)" Condition="'%(_MSBuildProjectReferenceExistent.OutputItemType)' != ''"/>
</MSBuild>
<!--
Get manifest items from the (non-exe) built project references (to feed them into ResolveNativeReference).
-->
<MSBuild
Projects="@(_MSBuildProjectReferenceExistent)"
Targets="GetNativeManifest"
BuildInParallel="$(BuildInParallel)"
Properties="%(_MSBuildProjectReferenceExistent.SetConfiguration); %(_MSBuildProjectReferenceExistent.SetPlatform); %(_MSBuildProjectReferenceExistent.SetTargetFramework)"
Condition="'%(_MSBuildProjectReferenceExistent.BuildReference)' == 'true' and '@(ProjectReferenceWithConfiguration)' != '' and '$(BuildingProject)' == 'true' and '@(_MSBuildProjectReferenceExistent)' != ''"
ContinueOnError="$(ContinueOnError)"
SkipNonexistentTargets="true"
RemoveProperties="%(_MSBuildProjectReferenceExistent.GlobalPropertiesToRemove)$(_GlobalPropertiesToRemoveFromProjectReferences)">
<Output TaskParameter="TargetOutputs" ItemName="NativeReference" Condition="'%(_MSBuildProjectReferenceExistent.ReferenceOutputAssembly)' == 'true'"/>
</MSBuild>
<ItemGroup>
<_ResolvedProjectReferencePaths Remove="@(_ResolvedProjectReferencePaths)" Condition="'%(_ResolvedProjectReferencePaths.ResolveableAssembly)' == 'false'" />
<!--
Copy OriginalItemSpec to OriginalProjectReferenceItemSpec, so that when ResolveAssemblyReferences
takes these items and resolves them to ReferencePath, we can still recover the _real_ OriginalItemSpec
for the unresolved reference items.
-->
<_ResolvedProjectReferencePaths>
<OriginalProjectReferenceItemSpec>%(_ResolvedProjectReferencePaths.OriginalItemSpec)</OriginalProjectReferenceItemSpec>
</_ResolvedProjectReferencePaths>
</ItemGroup>
<!-- Issue a warning for each non-existent project. -->
<Warning
Text="The referenced project '%(_MSBuildProjectReferenceNonexistent.Identity)' does not exist."
Condition="'@(ProjectReferenceWithConfiguration)' != '' and '@(_MSBuildProjectReferenceNonexistent)' != ''"/>
</Target>
<Target
Name="ResolveProjectReferencesDesignTime"
Returns="@(_ProjectReferencesFromRAR);@(_ResolvedNativeProjectReferencePaths)"
DependsOnTargets="ResolveProjectReferences;ResolveAssemblyReferences">
<!-- We need to do this here because we only want project references which have passed through rar and have not been unresolved due to violating some MT rule
which means we need to pull the project references out of the referencepath item because they will only exist there if they were correctly resolved.
-->
<ItemGroup>
<_ProjectReferencesFromRAR Include="@(ReferencePath->WithMetadataValue('ReferenceSourceTarget', 'ProjectReference'))">
<OriginalItemSpec>%(ReferencePath.ProjectReferenceOriginalItemSpec)</OriginalItemSpec>
</_ProjectReferencesFromRAR>
</ItemGroup>
</Target>
<Target
Name="ExpandSDKReferencesDesignTime"
Returns="@(ReferencesFromSDK)"
DependsOnTargets="ExpandSDKReferences"/>
<!--
============================================================
GetTargetPath
This target returns an item containing the build product (i.e. EXE, DLL)
that would be produced if we built this project, with some relevant
metadata.
============================================================
-->
<PropertyGroup>
<GetTargetPathDependsOn>$(GetTargetPathDependsOn)</GetTargetPathDependsOn>
</PropertyGroup>
<Target
Name="GetTargetPath"
DependsOnTargets="$(GetTargetPathDependsOn)"
Returns="@(TargetPathWithTargetPlatformMoniker)" />
<!--
============================================================
GetTargetPathWithTargetPlatformMoniker
This stand-alone target returns the name and version of the target platform for this project.
NOTE: The ProjectReference protocol uses only GetTargetPath. Computing the item
in this target allows projects to override GetTargetPath without having to reimplement
the details of the metadata computation.
============================================================
-->
<PropertyGroup>
<GetTargetPathWithTargetPlatformMonikerDependsOn>$(GetTargetPathDependsOn)</GetTargetPathWithTargetPlatformMonikerDependsOn>
</PropertyGroup>
<!--NOTE: since an overridden GetTargetPath might not include a DependsOn
for this target, it's safer to establish the dependency here with a
BeforeTargets. -->
<Target
Name="GetTargetPathWithTargetPlatformMoniker"
BeforeTargets="GetTargetPath"
DependsOnTargets="$(GetTargetPathWithTargetPlatformMonikerDependsOn)"
Returns="@(TargetPathWithTargetPlatformMoniker)">
<ItemGroup>
<TargetPathWithTargetPlatformMoniker Include="$(TargetPath)">
<TargetPlatformMoniker>$(TargetPlatformMoniker)</TargetPlatformMoniker>
<TargetPlatformIdentifier>$(TargetPlatformIdentifier)</TargetPlatformIdentifier>
<TargetFrameworkIdentifier>$(TargetFrameworkIdentifier)</TargetFrameworkIdentifier>
<TargetFrameworkVersion>$(TargetFrameworkVersion.TrimStart('vV'))</TargetFrameworkVersion>
<ReferenceAssembly Condition="'$(ProduceReferenceAssembly)' == 'true'">$(TargetRefPath)</ReferenceAssembly>
<CopyUpToDateMarker>@(CopyUpToDateMarker)</CopyUpToDateMarker>
</TargetPathWithTargetPlatformMoniker>
</ItemGroup>
</Target>
<!--
============================================================
GetNativeManifest
Compute the manifest item for this project.
[IN]
$(_DeploymentApplicationManifestIdentity) - the manifest identity
@(ApplicationManifest) - the original application manifest item
[OUT]
@(ComputedApplicationManifest) - application manifest item with full hint path, if generated
============================================================
-->
<Target
Name="GetNativeManifest"
Returns="@(ComputedApplicationManifest)">
<ItemGroup>
<ComputedApplicationManifest Include="$(_DeploymentApplicationManifestIdentity)" Condition="'$(OutputType)'!='winexe' and '$(OutputType)'!='exe' and '$(OutputType)'!='appcontainerexe' and Exists('%(_ApplicationManifestFinal.FullPath)')">
<HintPath>%(_ApplicationManifestFinal.FullPath)</HintPath>
</ComputedApplicationManifest>
</ItemGroup>
</Target>
<!--
============================================================
ResolveNativeReferences
Resolve native references
[IN]
@(NativeReference) - The manifest reference (or list of manifest references)
[OUT]
@(NativeReferenceFile) - List of manifest files referenced.
@(_DeploymentNativePrerequisite) - List of native assembly prerequisites contained in the manifest.
@(ComClassReference) - List of COM components contained in the manifest.
@(COMReferenceFromNative) List of type libraries contained in the manifest.
@(COMFileReference) - List of loose files contained in the manifest.
@(_DeploymentLooseManifestFile) - List of extra files that should be published.
============================================================
-->
<Target
Name="ResolveNativeReferences"
Condition="'@(NativeReference)'!=''"
DependsOnTargets="ResolveProjectReferences">
<ResolveNativeReference
NativeReferences="@(NativeReference)"
AdditionalSearchPaths="$(ReferencePath);$(OutDir)"
>
<Output TaskParameter="ContainingReferenceFiles" ItemName="NativeReferenceFile"/>
<Output TaskParameter="ContainedPrerequisiteAssemblies" ItemName="_DeploymentNativePrerequisite"/>
<Output TaskParameter="ContainedComComponents" ItemName="ComClassReference"/>
<Output TaskParameter="ContainedTypeLibraries" ItemName="COMReferenceFromNative"/>
<Output TaskParameter="ContainedLooseTlbFiles" ItemName="COMFileReference"/>
<Output TaskParameter="ContainedLooseEtcFiles" ItemName="_DeploymentLooseManifestFile"/>
</ResolveNativeReference>
</Target>
<!--
============================================================
ResolveAssemblyReferences
Given the list of assemblies, find the closure of all assemblies that they depend on. These are
what we need to copy to the output directory.
[IN]
@(Reference) - List of assembly references as fusion names.
@(_ResolvedProjectReferencePaths) - List of project references produced by projects that this project depends on.
The 'Private' attribute on the reference corresponds to the Copy Local flag in IDE.
The 'Private' flag can have three possible values:
- 'True' means the reference should be Copied Local
- 'False' means the reference should not be Copied Local
- [Missing] means this task will decide whether to treat this reference as CopyLocal or not.
[OUT]
@(ReferencePath) - Paths to resolved primary files.
@(ReferenceDependencyPaths) - Paths to resolved dependency files.
@(_ReferenceRelatedPaths) - Paths to .xmls and .pdbs.
@(ReferenceSatellitePaths) - Paths to satellites.
@(_ReferenceSerializationAssemblyPaths) - Paths to XML serialization assemblies created by sgen.
@(_ReferenceScatterPaths) - Paths to scatter files.
@(ReferenceCopyLocalPaths) - Paths to files that should be copied to the local directory.
============================================================
-->
<PropertyGroup>
<ResolveAssemblyReferencesDependsOn>
ResolveProjectReferences;
FindInvalidProjectReferences;
GetFrameworkPaths;
GetReferenceAssemblyPaths;
PrepareForBuild;
ResolveSDKReferences;
ExpandSDKReferences;
</ResolveAssemblyReferencesDependsOn>
</PropertyGroup>
<Target
Name="ResolveAssemblyReferences"
Returns="@(ReferencePath)"
DependsOnTargets="$(ResolveAssemblyReferencesDependsOn)">
<ItemGroup>
<_ReferenceInstalledAssemblyDirectory Include="$(TargetFrameworkDirectory)" />
<_ReferenceInstalledAssemblySubsets Include="$(TargetFrameworkSubset)" />
</ItemGroup>
<!--
Only read and write cache file at build time, skip it for load time because its more
expensive to write the newly created cache file.
-->
<PropertyGroup>
<ResolveAssemblyReferencesStateFile Condition="'$(DisableRarCache)'!='true' and '$(ResolveAssemblyReferencesStateFile)' == ''">$(IntermediateOutputPath)$(MSBuildProjectFile).AssemblyReference.cache</ResolveAssemblyReferencesStateFile>
</PropertyGroup>
<!-- Make an App.Config item that exists when AutoUnify is false. -->
<ItemGroup>
<_ResolveAssemblyReferencesApplicationConfigFileForExes Include="@(AppConfigWithTargetPath)" Condition="'$(AutoGenerateBindingRedirects)'=='true' or '$(AutoUnifyAssemblyReferences)'=='false'"/>
</ItemGroup>
<PropertyGroup>
<!-- Default in task is true -->
<_FindDependencies Condition="'$(BuildingProject)' != 'true' and '$(_ResolveReferenceDependencies)' != 'true'">false</_FindDependencies>
<ResolveAssemblyReferencesSilent Condition="'$(ResolveAssemblyReferencesSilent)' == '' and '$(TraceDesignTime)' != 'true' and '$(BuildingProject)' == 'false'">true</ResolveAssemblyReferencesSilent>
<ResolveAssemblyReferencesSilent Condition="'$(ResolveAssemblyReferencesSilent)' == ''">false</ResolveAssemblyReferencesSilent>
<ResolveAssemblyWarnOrErrorOnTargetArchitectureMismatch Condition="'$(ResolveAssemblyWarnOrErrorOnTargetArchitectureMismatch)' == ''">Warning</ResolveAssemblyWarnOrErrorOnTargetArchitectureMismatch>
<ResolveAssemblyReferencesFindRelatedSatellites Condition="'$(ResolveAssemblyReferencesFindRelatedSatellites)' == ''">$(BuildingProject)</ResolveAssemblyReferencesFindRelatedSatellites>
<ResolveAssemblyReferencesFindSerializationAssemblies Condition="'$(ResolveAssemblyReferencesFindSerializationAssemblies)' == ''">$(BuildingProject)</ResolveAssemblyReferencesFindSerializationAssemblies>
<ResolveAssemblyReferencesFindRelatedFiles Condition="'$(ResolveAssemblyReferencesFindRelatedFiles)' == ''">$(BuildingProject)</ResolveAssemblyReferencesFindRelatedFiles>
<ResolveAssemblyReferenceOutputUnresolvedAssemblyConflicts Condition="'$(ResolveAssemblyReferenceOutputUnresolvedAssemblyConflicts)' == ''">false</ResolveAssemblyReferenceOutputUnresolvedAssemblyConflicts>
</PropertyGroup>
<ItemGroup>
<!-- Remove any references which we have added as explicit reference so that we do not get duplicates. We need to make sure we do not have duplicates
because this confuses the IDE when it tries to compare the list of references passed in to the list of resolved references. If it does not match then the
ide will show one of the references as not resolved, this will not break the build but is a display issue -->
<Reference Remove="$(AdditionalExplicitAssemblyReferences)"/>
<Reference Include="$(AdditionalExplicitAssemblyReferences)">
<Implicit>true</Implicit>
</Reference>
</ItemGroup>
<!--
Normally, as an optimization, finding dependencies of references marked with ExternallyResolved=true metadata is skipped.
However, skipping that step breaks binding redirect generation when there are conflicting versions within the externally
resolved graph.
-->
<PropertyGroup Condition="'$(FindDependenciesOfExternallyResolvedReferences)' == ''">
<FindDependenciesOfExternallyResolvedReferences>false</FindDependenciesOfExternallyResolvedReferences>
<FindDependenciesOfExternallyResolvedReferences Condition="'$(AutoGenerateBindingRedirects)' == 'true'">true</FindDependenciesOfExternallyResolvedReferences>
</PropertyGroup>
<ResolveAssemblyReference
Assemblies="@(Reference)"
AssemblyFiles="@(_ResolvedProjectReferencePaths);@(_ExplicitReference)"
TargetFrameworkDirectories="@(_ReferenceInstalledAssemblyDirectory)"
InstalledAssemblyTables="@(InstalledAssemblyTables);@(RedistList)"
IgnoreDefaultInstalledAssemblyTables="$(IgnoreDefaultInstalledAssemblyTables)"
IgnoreDefaultInstalledAssemblySubsetTables="$(IgnoreInstalledAssemblySubsetTables)"
CandidateAssemblyFiles="@(Content);@(None)"
SearchPaths="$(AssemblySearchPaths)"
AllowedAssemblyExtensions="$(AllowedReferenceAssemblyFileExtensions)"
AllowedRelatedFileExtensions="$(AllowedReferenceRelatedFileExtensions)"
TargetProcessorArchitecture="$(ProcessorArchitecture)"
AppConfigFile="@(_ResolveAssemblyReferencesApplicationConfigFileForExes)"
AutoUnify="$(AutoUnifyAssemblyReferences)"
SupportsBindingRedirectGeneration="$(GenerateBindingRedirectsOutputType)"
IgnoreVersionForFrameworkReferences="$(IgnoreVersionForFrameworkReferences)"
FindDependencies="$(_FindDependencies)"
FindSatellites="$(ResolveAssemblyReferencesFindRelatedSatellites)"
FindSerializationAssemblies="$(ResolveAssemblyReferencesFindSerializationAssemblies)"
FindRelatedFiles="$(ResolveAssemblyReferencesFindRelatedFiles)"
Silent="$(ResolveAssemblyReferencesSilent)"
TargetFrameworkVersion="$(TargetFrameworkVersion)"
TargetFrameworkMoniker="$(TargetFrameworkMoniker)"
TargetFrameworkMonikerDisplayName="$(TargetFrameworkMonikerDisplayName)"
TargetedRuntimeVersion="$(TargetedRuntimeVersion)"
StateFile="$(ResolveAssemblyReferencesStateFile)"
AssemblyInformationCachePaths="$(AssemblyInformationCachePaths)"
AssemblyInformationCacheOutputPath="$(AssemblyInformationCacheOutputPath)"
InstalledAssemblySubsetTables="@(InstalledAssemblySubsetTables)"
TargetFrameworkSubsets="@(_ReferenceInstalledAssemblySubsets)"
FullTargetFrameworkSubsetNames="$(FullReferenceAssemblyNames)"
FullFrameworkFolders="$(_FullFrameworkReferenceAssemblyPaths)"
FullFrameworkAssemblyTables="@(FullFrameworkAssemblyTables)"
ProfileName="$(TargetFrameworkProfile)"
LatestTargetFrameworkDirectories="@(LatestTargetFrameworkDirectories)"
CopyLocalDependenciesWhenParentReferenceInGac="$(CopyLocalDependenciesWhenParentReferenceInGac)"
DoNotCopyLocalIfInGac="$(DoNotCopyLocalIfInGac)"
ResolvedSDKReferences="@(ResolvedSDKReference)"
WarnOrErrorOnTargetArchitectureMismatch="$(ResolveAssemblyWarnOrErrorOnTargetArchitectureMismatch)"
IgnoreTargetFrameworkAttributeVersionMismatch ="$(ResolveAssemblyReferenceIgnoreTargetFrameworkAttributeVersionMismatch)"
FindDependenciesOfExternallyResolvedReferences="$(FindDependenciesOfExternallyResolvedReferences)"
ContinueOnError="$(ContinueOnError)"
OutputUnresolvedAssemblyConflicts="$(ResolveAssemblyReferenceOutputUnresolvedAssemblyConflicts)"
Condition="'@(Reference)'!='' or '@(_ResolvedProjectReferencePaths)'!='' or '@(_ExplicitReference)' != ''"
>
<Output TaskParameter="ResolvedFiles" ItemName="ReferencePath"/>
<Output TaskParameter="ResolvedFiles" ItemName="_ResolveAssemblyReferenceResolvedFiles"/>
<Output TaskParameter="ResolvedDependencyFiles" ItemName="ReferenceDependencyPaths"/>
<Output TaskParameter="RelatedFiles" ItemName="_ReferenceRelatedPaths"/>
<Output TaskParameter="SatelliteFiles" ItemName="ReferenceSatellitePaths"/>
<Output TaskParameter="SerializationAssemblyFiles" ItemName="_ReferenceSerializationAssemblyPaths"/>
<Output TaskParameter="ScatterFiles" ItemName="_ReferenceScatterPaths"/>
<Output TaskParameter="CopyLocalFiles" ItemName="ReferenceCopyLocalPaths"/>
<Output TaskParameter="SuggestedRedirects" ItemName="SuggestedBindingRedirects"/>
<Output TaskParameter="FilesWritten" ItemName="FileWrites"/>
<Output TaskParameter="DependsOnSystemRuntime" PropertyName="DependsOnSystemRuntime"/>
<Output TaskParameter="DependsOnNETStandard" PropertyName="_DependsOnNETStandard"/>
<Output TaskParameter="UnresolvedAssemblyConflicts" ItemName="ResolveAssemblyReferenceUnresolvedAssemblyConflicts"/>
</ResolveAssemblyReference>
</Target>
<!--
============================================================
FindReferenceAssembliesForReferences
Given the list of references, create a list of assemblies to pass to the compiler that
includes reference assemblies rather than implementation assemblies where possible.
[IN]
@(ReferencePath) - List of assembly references as resolved paths with ReferenceAssembly metadata
[OUT]
@(ReferencePathWithRefAssemblies) - Paths to resolved reference (or implementation) assemblies.
============================================================
-->
<Target Name="FindReferenceAssembliesForReferences"
DependsOnTargets="ResolveReferences">
<ItemGroup>
<!-- Reference assemblies are not produced in all cases, but it's easier to consume them
if this metadatum is always populated. Ensure that it points to the implementation
assembly unless already specified. -->
<ReferencePath Condition="'%(ReferencePath.ReferenceAssembly)' == ''">
<ReferenceAssembly>%(FullPath)</ReferenceAssembly>
</ReferencePath>
<ReferencePathWithRefAssemblies Include="@(ReferencePath->'%(ReferenceAssembly)')"
Condition="'$(CompileUsingReferenceAssemblies)' != 'false'">
<OriginalPath Condition="'%(ReferencePath.Identity)' != '@(ReferencePath->'%(ReferenceAssembly)')'">%(ReferencePath.Identity)</OriginalPath>
</ReferencePathWithRefAssemblies>
<ReferencePathWithRefAssemblies Include="@(ReferencePath)"
Condition="'$(CompileUsingReferenceAssemblies)' == 'false'" />
</ItemGroup>
</Target>
<!--
====================================================================================================
GenerateBindingRedirects
Inject the binding redirects into the app config file based on suggested redirects as output from
ResolveAssemblyReferences.
[IN]
@(AppConfigWithTargetPath) - Path to the source app config file. This can be null if the project
doesn't contain an app config file.
$(TargetFileName) - The file name of the build target.
[OUT]
@(OutputAppConfigFile) - Path to the output app config file in the intermediate directory.
====================================================================================================
-->
<Target Name="GenerateBindingRedirects"
Inputs="$(MSBuildAllProjects);@(AppConfigWithTargetPath);$(SuggestedBindingRedirectsCacheFile)"
Outputs="$(_GenerateBindingRedirectsIntermediateAppConfig)"
Condition="'$(AutoGenerateBindingRedirects)' == 'true' and '$(GenerateBindingRedirectsOutputType)' == 'true' and '@(SuggestedBindingRedirects)' != '' and '$(DesignTimeBuild)' != 'true' and '$(BuildingProject)' == 'true'"
DependsOnTargets="_GenerateSuggestedBindingRedirectsCache">
<GenerateBindingRedirects
AppConfigFile="@(AppConfigWithTargetPath)"
TargetName="$(TargetFileName).config"
OutputAppConfigFile="$(_GenerateBindingRedirectsIntermediateAppConfig)"
SuggestedRedirects="@(SuggestedBindingRedirects)" />
<ItemGroup>
<FileWrites Include="$(_GenerateBindingRedirectsIntermediateAppConfig)" />
</ItemGroup>
</Target>
<!--
====================================================================================================
GenerateBindingRedirectsUpdateAppConfig
Updates the project to use the generated app.config content. This needs to run regardless of
inputs/outputs so it is seperate from GenerateBindingRedirects.
====================================================================================================
-->
<Target Name="GenerateBindingRedirectsUpdateAppConfig"
Condition="'$(AutoGenerateBindingRedirects)' == 'true' and '$(GenerateBindingRedirectsOutputType)' == 'true'">
<PropertyGroup>
<_NewGenerateBindingRedirectsIntermediateAppConfig Condition="Exists('$(_GenerateBindingRedirectsIntermediateAppConfig)')">true</_NewGenerateBindingRedirectsIntermediateAppConfig>
<AppConfig Condition="$(_NewGenerateBindingRedirectsIntermediateAppConfig) == 'true'">$(_GenerateBindingRedirectsIntermediateAppConfig)</AppConfig>
</PropertyGroup>
<ItemGroup Condition="$(_NewGenerateBindingRedirectsIntermediateAppConfig) == 'true'">
<AppConfigWithTargetPath Remove="@(AppConfigWithTargetPath)" />
<AppConfigWithTargetPath Include="$(AppConfig)">
<TargetPath>$(TargetFileName).config</TargetPath>
</AppConfigWithTargetPath>
</ItemGroup>
</Target>
<!--
===========================================================================================
GetInstalledSDKs
Gets the list of SDKs installed in the SDKDirectoryRoot and SDKRegistryRoot locations
These paths are used by the ResolveSDKReference task and the ResolveAssemblyReference task.
===========================================================================================
-->
<PropertyGroup>
<SDKReferenceRegistryRoot Condition="'$(SDKReferenceRegistryRoot)' == ''">Software\Microsoft\Microsoft SDKs</SDKReferenceRegistryRoot>
<SDKReferenceDirectoryRoot Condition="'$(SDKReferenceDirectoryRoot)' == ''">$(LocalAppData)\Microsoft SDKs;$(MSBuildProgramFiles32)\Microsoft SDKs</SDKReferenceDirectoryRoot>
<!-- Manifest driven extension SDK locations -->
<SDKExtensionDirectoryRoot Condition="'$(SDKExtensionDirectoryRoot)' == '' and '$(SDKIdentifier)' != ''">$(MSBuildProgramFiles32)\Microsoft SDKs\Windows Kits\10;$(MSBuildProgramFiles32)\Windows Kits\10</SDKExtensionDirectoryRoot>
<!-- UAP projects by default should support Windows 8.1 SDKs -->
<SupportWindows81SDKs Condition="'$(SupportWindows81SDKs)' == '' and '$(Support81SDKs)' != 'false' and '$(TargetPlatformIdentifier)' == 'UAP'">true</SupportWindows81SDKs>
<TargetPlatformIdentifierWindows81 Condition="'$(TargetPlatformIdentifierWindows81)' == '' and '$(SupportWindows81SDKs)' == 'true'">Windows</TargetPlatformIdentifierWindows81>
<TargetPlatformVersionWindows81 Condition="'$(TargetPlatformVersionWindows81)' == '' and '$(SupportWindows81SDKs)' == 'true'">8.1</TargetPlatformVersionWindows81>
<!-- Desktop and phone SDKs often have the exact same identifiers, don't enable phone by default -->
<SupportWindowsPhone81SDKs Condition="'$(SupportWindowsPhone81SDKs)' == '' and '$(Support81SDKs)' != 'false' and '$(TargetPlatformIdentifier)' == 'UAP'">false</SupportWindowsPhone81SDKs>
<TargetPlatformIdentifierWindowsPhone81 Condition="'$(TargetPlatformIdentifierWindowsPhone81)' == '' and '$(SupportWindowsPhone81SDKs)' == 'true'">WindowsPhoneApp</TargetPlatformIdentifierWindowsPhone81>
<TargetPlatformVersionWindowsPhone81 Condition="'$(TargetPlatformVersionWindowsPhone81)' == '' and '$(SupportWindowsPhone81SDKs)' == 'true'">8.1</TargetPlatformVersionWindowsPhone81>
</PropertyGroup>
<Target
Name="GetInstalledSDKLocations"
Condition="'@(SDKReference)' != ''"
DependsOnTargets="$(GetInstalledSDKLocationsDependsOn)"
Returns="@(InstalledSDKLocations)"
>
<GetInstalledSDKLocations
SDKDirectoryRoots="$(SDKReferenceDirectoryRoot)"
SDKExtensionDirectoryRoots="$(SDKExtensionDirectoryRoot)"
SDKRegistryRoot="$(SDKReferenceRegistryRoot)"
TargetPlatformVersion="$(TargetPlatformVersion)"
TargetPlatformIdentifier="$(TargetPlatformIdentifier)"
>
<Output TaskParameter="InstalledSDKs" ItemName="InstalledSDKLocations"/>
</GetInstalledSDKLocations>
<!-- Also lookup 8.1 SDKs if requested -->
<GetInstalledSDKLocations
SDKDirectoryRoots="$(SDKReferenceDirectoryRoot)"
SDKExtensionDirectoryRoots=""
SDKRegistryRoot="$(SDKReferenceRegistryRoot)"
TargetPlatformVersion="$(TargetPlatformVersionWindows81)"
TargetPlatformIdentifier="$(TargetPlatformIdentifierWindows81)"
Condition="'$(SupportWindows81SDKs)' == 'true' and '$(TargetPlatformIdentifierWindows81)' != '' and '$(TargetPlatformVersionWindows81)' != ''"
WarnWhenNoSDKsFound="false"
>
<Output TaskParameter="InstalledSDKs" ItemName="InstalledSDKLocations"/>
</GetInstalledSDKLocations>
<GetInstalledSDKLocations
SDKDirectoryRoots="$(SDKReferenceDirectoryRoot)"
SDKExtensionDirectoryRoots=""
SDKRegistryRoot="$(SDKReferenceRegistryRoot)"
TargetPlatformVersion="$(TargetPlatformVersionWindowsPhone81)"
TargetPlatformIdentifier="$(TargetPlatformIdentifierWindowsPhone81)"
Condition="'$(SupportWindowsPhone81SDKs)' == 'true' and '$(TargetPlatformIdentifierWindowsPhone81)' != '' and '$(TargetPlatformVersionWindowsPhone81)' != ''"
WarnWhenNoSDKsFound="false"
>
<Output TaskParameter="InstalledSDKs" ItemName="InstalledSDKLocations"/>
</GetInstalledSDKLocations>
</Target>
<!--
============================================================
ResolveSDKReferences
Given a list of SDKReference items and a list of resolved winmd files which may contain metadata as to which sdk they came from
we need to find the sdk root folders on disk and populate a ResolvedSDKReference item which has the full path to the SDK ROOT
and the sdk identity as a piece of metadata.
[IN]
@(SDKReference) - List of sdk references (the identity in the sdk manifest file).
@(ReferencePath) -List of resolved assemblies, we are interested in the ones which have IsWinMDFile set to true.
[OUT]
@(ResolvedSDKReference) - Full path to the root of the SDK
============================================================
-->
<PropertyGroup>
<ResolveSDKReferencesDependsOn>
GetInstalledSDKLocations
</ResolveSDKReferencesDependsOn>
</PropertyGroup>
<PropertyGroup>
<TargetedSDKConfiguration Condition="'$(TargetedSDKConfiguration)' == '' and '_$(Configuration)' == '_Debug'">Debug</TargetedSDKConfiguration>
<TargetedSDKConfiguration Condition="'$(TargetedSDKConfiguration)' == '' and '_$(Configuration)' == '_Release'">Retail</TargetedSDKConfiguration>
<TargetedSDKConfiguration Condition="'$(TargetedSDKConfiguration)' == ''">Retail</TargetedSDKConfiguration>
<TargetedSDKArchitecture Condition="'$(TargetedSDKArchitecture)' == ''">$(ProcessorArchitecture)</TargetedSDKArchitecture>
<TargetedSDKArchitecture Condition="'$(TargetedSDKArchitecture)' == ''">Neutral</TargetedSDKArchitecture>
</PropertyGroup>
<PropertyGroup>
<ShouldMarkCertainSDKReferencesAsRuntimeOnly Condition="'$(ShouldMarkCertainSDKReferencesAsRuntimeOnly)' == ''">true</ShouldMarkCertainSDKReferencesAsRuntimeOnly>
</PropertyGroup>
<ItemGroup Condition="'$(ShouldMarkCertainSDKReferencesAsRuntimeOnly)' == 'true'">
<!-- Dependencies that are specified as runtime-only dependencies. Therefore the associated files are not used to build Appx package. -->
<!-- TODO: Do we need to do anything like this for the new SDK? -->
<RuntimeReferenceOnlySDKDependencies Condition = "'$(TargetPlatformVersion)' == '8.1'" Include="Microsoft.VCLibs, Version=11.0"/>
</ItemGroup>
<Target
Name="ResolveSDKReferences"
Returns="@(ResolvedSDKReference)"
DependsOnTargets="$(ResolveSDKReferencesDependsOn)">
<ResolveSDKReference
SDKReferences="@(SDKReference)"
RuntimeReferenceOnlySDKDependencies="@(RuntimeReferenceOnlySDKDependencies)"
References="@(Reference)"
TargetPlatformVersion="$(TargetPlatformVersion)"
TargetPlatformIdentifier="$(TargetPlatformIdentifier)"
WarnOnMissingPlatformVersion="$(SDKReferenceWarnOnMissingMaxPlatformVersion)"
ProjectName="$(MSBuildProjectName)"
TargetedSDKConfiguration="$(TargetedSDKConfiguration)"
TargetedSDKArchitecture="$(TargetedSDKArchitecture)"
InstalledSDKs ="@(InstalledSDKLocations)"
LogResolutionErrorsAsWarnings ="$(LogSDKReferenceResolutionErrorsAsWarnings)"
Prefer32Bit ="$(Prefer32Bit)"
ContinueOnError="$(ContinueOnError)"
Condition="'@(SDKReference)'!=''">
<Output TaskParameter="ResolvedSDKReferences" ItemName="ResolvedSDKReference"/>
</ResolveSDKReference>
</Target>
<Target
Name="ResolveSDKReferencesDesignTime"
Returns="@(ResolvedSDKReference)"
DependsOnTargets="ResolveSDKReferences" />
<!--
============================================================
FindInvalidProjectReferences
Find project to project references with target platform version higher than the one used by the current project and
creates a list of invalid references to be unresolved. It issues a warning for each invalid reference.
[IN]
$(TargetPlatformVersion) - Project's target platform version
@(_ProjectReferenceTargetPlatformMonikers) - List of monikers of all referenced projects gathered by the helper
target GetTargetPlatformMonikers.
[OUT]
@(InvalidProjectReferences) - List of invalid project references
============================================================
-->
<PropertyGroup>
<FindInvalidProjectReferencesDependsOn>
GetReferenceTargetPlatformMonikers
</FindInvalidProjectReferencesDependsOn>
</PropertyGroup>
<Target
Name="FindInvalidProjectReferences"
Condition ="'$(FindInvalidProjectReferences)' == 'true'"
DependsOnTargets="$(FindInvalidProjectReferencesDependsOn)">
<FindInvalidProjectReferences
TargetPlatformVersion="$(TargetPlatformVersion)"
TargetPlatformIdentifier="$(TargetPlatformIdentifier)"
ProjectReferences="@(TargetPathWithTargetPlatformMoniker)">
<Output TaskParameter="InvalidReferences" ItemName="InvalidProjectReferences" />
</FindInvalidProjectReferences>
<ItemGroup>
<_ResolvedProjectReferencePaths Remove="@(InvalidProjectReferences)" />
</ItemGroup>
</Target>
<Target Name="GetReferenceTargetPlatformMonikers" DependsOnTargets="PrepareProjectReferences">
<MSBuild
Projects="@(_MSBuildProjectReferenceExistent)"
Properties="%(_MSBuildProjectReferenceExistent.SetConfiguration); %(_MSBuildProjectReferenceExistent.SetPlatform); %(_MSBuildProjectReferenceExistent.SetTargetFramework)"
Targets="GetTargetPathWithTargetPlatformMoniker"
BuildInParallel="$(BuildInParallel)"
ContinueOnError="!$(BuildingProject)"
RemoveProperties="%(_MSBuildProjectReferenceExistent.GlobalPropertiesToRemove)$(_GlobalPropertiesToRemoveFromProjectReferences)">
<Output TaskParameter="TargetOutputs" ItemName="TargetPathWithTargetPlatformMoniker" />
</MSBuild>
</Target>
<ItemGroup Condition="'$(IsGraphBuild)' == 'true' and '$(FindInvalidProjectReferences)' == 'true'">
<ProjectReferenceTargets Include="Build" Targets="GetTargetPathWithTargetPlatformMoniker" />
</ItemGroup>
<!--
============================================================
ExpandSDKReferences
After we have resolved the sdk refrence we need to make sure that we automatically include the references which are part of the SDK (both winmd and dll)
as part of the assemblies passed to the compiler.
Project systems or project which do not want to reference all dlls or winmd files should override this target to do nothing.
============================================================
-->
<PropertyGroup>
<ExpandSDKReferencesDependsOn>
ResolveSDKReferences
</ExpandSDKReferencesDependsOn>
<ExpandSDKAllowedReferenceExtensions Condition="'$(ExpandSDKAllowedReferenceExtensions)' == ''">
.winmd;
.dll
</ExpandSDKAllowedReferenceExtensions>
</PropertyGroup>
<Target Name="ExpandSDKReferences"
Returns="@(ReferencesFromSDK)"
DependsOnTargets="$(ExpandSDKReferencesDependsOn)"
>
<GetSDKReferenceFiles
ResolvedSDKReferences="@(ResolvedSDKReference)"
ReferenceExtensions="$(ExpandSDKAllowedReferenceExtensions)"
TargetSDKIdentifier="$(SDKIdentifier)"
TargetSDKVersion="$(SDKVersion)"
TargetPlatformIdentifier="$(TargetPlatformIdentifier)"
TargetPlatformVersion="$(TargetPlatformVersion)"
LogRedistFilesList="$(GetSDKReferenceFilesLogRedistFilesList)"
LogRedistConflictWithinSDKAsWarning ="$(GetSDKReferenceFilesLogRedistConflictsWithinSDKAsWarning)"
LogRedistConflictBetweenSDKsAsWarning ="$(GetSDKReferenceFilesLogRedistConflictsBetweenSDKsAsWarning)"
LogReferencesList="$(GetSDKReferenceFilesLogReferencesList)"
LogReferenceConflictWithinSDKAsWarning ="$(GetSDKReferenceFilesLogReferenceConflictsWithinSDKAsWarning)"
LogReferenceConflictBetweenSDKsAsWarning ="$(GetSDKReferenceFilesLogReferenceConflictsBetweenSDKsAsWarning)"
CacheFileFolderPath ="$(GetSDKReferenceFilesCacheFolder)"
LogCacheFileExceptions="$(GetSDKReferenceFilesLogCacheFileExceptions)"
Condition="'@(ResolvedSDKReference)'!=''">
<Output TaskParameter="References" ItemName="ReferencePath"/>
<Output TaskParameter="References" ItemName="ReferencesFromSDK"/>
<Output TaskParameter="References" ItemName="_ResolveAssemblyReferenceResolvedFiles"/>
<Output TaskParameter="CopyLocalFiles" ItemName="ReferenceCopyLocalPaths"/>
<Output TaskParameter="RedistFiles" ItemName="ResolvedRedistFiles"/>
</GetSDKReferenceFiles>
</Target>
<!--
============================================================
ExportWindowsMDFile
When a project is generating a a winmd file through c# or vb, ect the compiler will create a WinMDModule file. This file needs to be run
through the winmdexp tool in order to generate the resulting WinMD file.
===========================================================
-->
<Target Name="ExportWindowsMDFile"
DependsOnTargets="Compile"
Condition="'$(ExportWinMDFile)' == 'true'"
Inputs="@(IntermediateAssembly);@(DocFileItem);@(_DebugSymbolsIntermediatePath);@(ReferencePathWithRefAssemblies);$(MSBuildAllProjects)"
Outputs="$(_IntermediateWindowsMetadataPath);$(WinMDExpOutputPdb);$(WinMDOutputDocumentationFile)"
>
<PropertyGroup>
<!-- Will be copied by the "copy WinMD artifacts" step instead -->
<CopyBuildOutputToOutputDirectory>false</CopyBuildOutputToOutputDirectory>
<CopyOutputSymbolsToOutputDirectory>false</CopyOutputSymbolsToOutputDirectory>
<CopyDocumentationFileToOutputDirectory>false</CopyDocumentationFileToOutputDirectory>
<WinMdExpToolPath Condition="'$(WinMdExpToolPath)' == ''">$(TargetFrameworkSDKToolsDirectory)</WinMdExpToolPath>
<WinMdExpUTF8Ouput Condition="'$(WinMdExpUTF8Ouput)' == ''">true</WinMdExpUTF8Ouput>
</PropertyGroup>
<WinMDExp WinMDModule="@(IntermediateAssembly)"
References="@(ReferencePathWithRefAssemblies)"
DisabledWarnings="$(WinMdExpNoWarn)"
InputDocumentationFile="@(DocFileItem)"
OutputDocumentationFile="$(WinMDOutputDocumentationFile)"
TreatWarningsAsErrors="$(TreatWarningsAsErrors)"
InputPDBFile="@(_DebugSymbolsIntermediatePath)"
OutputPDBFile="$(WinMDExpOutputPdb)"
OutputWindowsMetadataFile="$(_IntermediateWindowsMetadataPath)"
EnvironmentVariables="$(WinMDExpEnvironment)"
UTF8Output="$(WinMdExpUTF8Ouput)"
SdkToolsPath="$(WinMdExpToolPath)"
AssemblyUnificationPolicy="$(WinMDExpAssemblyUnificationPolicy)">
<Output TaskParameter="OutputWindowsMetadataFile" ItemName="FileWrites"/>
</WinMDExp>
<ItemGroup>
<WinMDExpArtifacts Include="$(_IntermediateWindowsMetadataPath)"/>
<WinMDExpArtifacts Include="$(WinMDOutputDocumentationFile)"/>
<WinMDExpArtifacts Include="$(WinMDExpOutputPdb)"/>
<FileWrites Include="$(WinMDOutputDocumentationFile);$(WinMDExpOutputPdb)"/>
</ItemGroup>
</Target>
<Target
Name="ResolveAssemblyReferencesDesignTime"
Returns="@(_ReferencesFromRAR)"
DependsOnTargets="ResolveProjectReferences;ResolveAssemblyReferences">
<!-- We need to do this here because we only want references which have been passed into rar but are not project to project references. -->
<ItemGroup>
<_ReferencesFromRAR Include="@(ReferencePath->WithMetadataValue('ReferenceSourceTarget', 'ResolveAssemblyReference'))"/>
</ItemGroup>
</Target>
<PropertyGroup>
<ProjectDesignTimeAssemblyResolutionSearchPaths Condition=" '$(ProjectDesignTimeAssemblyResolutionSearchPaths)' == '' ">
{CandidateAssemblyFiles};
$(ReferencePath);
{HintPathFromItem};
{TargetFrameworkDirectory};
{Registry:$(FrameworkRegistryBase),$(TargetFrameworkVersion),$(AssemblyFoldersSuffix)$(AssemblyFoldersExConditions)};
{RawFileName};
$(TargetDir)
</ProjectDesignTimeAssemblyResolutionSearchPaths>
</PropertyGroup>
<!--
==============================================================
DesignTimeResolveAssemblyReferences
Given the list of assemblies, resolve their reference paths.
This target is called by Visual Studio at run time in order to filter references
according to the targeted framework.
[IN]
@(DesignTimeReference) - List of assembly references as simple/fusion names.
[OUT]
@(ReferencePath) - Paths to resolved primary files.
==============================================================
-->
<PropertyGroup>
<DesignTimeResolveAssemblyReferencesDependsOn>
GetFrameworkPaths;
GetReferenceAssemblyPaths;
ResolveReferences
</DesignTimeResolveAssemblyReferencesDependsOn>
</PropertyGroup>
<Target
Name="DesignTimeResolveAssemblyReferences"
Condition="'$(DesignTimeReference)'!=''"
DependsOnTargets="$(DesignTimeResolveAssemblyReferencesDependsOn)">
<ItemGroup>
<_DesignTimeReferenceInstalledAssemblyDirectory Include="$(TargetFrameworkDirectory)" />
</ItemGroup>
<PropertyGroup>
<DesignTimeResolveAssemblyReferencesStateFile Condition="'$(DisableRarCache)'!='true'">$(IntermediateOutputPath)$(MSBuildProjectFile)DesignTimeResolveAssemblyReferences.cache</DesignTimeResolveAssemblyReferencesStateFile>
</PropertyGroup>
<PropertyGroup>
<DesignTimeAssemblySearchPaths Condition=" '$(DesignTimeAssemblySearchPaths)' == '' ">
{CandidateAssemblyFiles};
$(ReferencePath);
{HintPathFromItem};
{TargetFrameworkDirectory};
{Registry:$(FrameworkRegistryBase),$(TargetFrameworkVersion),$(AssemblyFoldersSuffix)$(AssemblyFoldersExConditions)};
{RawFileName};
$(OutDir)
</DesignTimeAssemblySearchPaths>
</PropertyGroup>
<PropertyGroup>
<DesignTimeFindDependencies Condition=" '$(DesignTimeFindDependencies)' == '' ">false</DesignTimeFindDependencies>
<DesignTimeIgnoreVersionForFrameworkReferences Condition=" '$(DesignTimeIgnoreVersionForFrameworkReferences)' == '' ">false</DesignTimeIgnoreVersionForFrameworkReferences>
<DesignTimeFindSatellites Condition=" '$(DesignTimeFindSatellites)' == '' ">false</DesignTimeFindSatellites>
<DesignTimeFindSerializationAssemblies Condition=" '$(DesignTimeFindSerializationAssemblies)' == '' ">false</DesignTimeFindSerializationAssemblies>
<DesignTimeFindRelatedFiles Condition=" '$(DesignTimeFindRelatedFiles)' == '' ">false</DesignTimeFindRelatedFiles>
<DesignTimeSilentResolution Condition=" '$(DesignTimeSilentResolution)' == '' and '$(TraceDesignTime)' != 'true'">true</DesignTimeSilentResolution>
<DesignTimeAutoUnify Condition="'$(DesignTimeAutoUnify)' == ''">false</DesignTimeAutoUnify>
</PropertyGroup>
<ItemGroup>
<_DesignTimeReferenceAssemblies Include ="$(DesignTimeReference)" />
</ItemGroup>
<ItemGroup>
<_RARResolvedReferencePath Include="@(ReferencePath)" />
<ReferencePath Remove="@(ReferencePath)" />
</ItemGroup>
<ResolveAssemblyReference
Assemblies="@(_DesignTimeReferenceAssemblies)"
TargetFrameworkDirectories="@(_DesignTimeReferenceInstalledAssemblyDirectory)"
SearchPaths="$(DesignTimeAssemblySearchPaths)"
AllowedAssemblyExtensions="$(AllowedReferenceAssemblyFileExtensions)"
TargetProcessorArchitecture="$(ProcessorArchitecture)"
CandidateAssemblyFiles="@(Content);@(None);@(_RARResolvedReferencePath)"
FindDependencies="$(DesignTimeFindDependencies)"
AutoUnify="$(DesignTimeAutoUnify)"
IgnoreVersionForFrameworkReferences="$(DesignTimeIgnoreVersionForFrameworkReferences)"
FindSatellites="$(DesignTimeFindSatellites)"
FindSerializationAssemblies="$(DesignTimeFindSerializationAssemblies)"
FindRelatedFiles="$(DesignTimeFindRelatedFiles)"
Silent="$(DesignTimeSilentResolution)"
TargetFrameworkVersion="$(TargetFrameworkVersion)"
TargetFrameworkMoniker="$(TargetFrameworkMoniker)"
TargetFrameworkMonikerDisplayName="$(TargetFrameworkMonikerDisplayName)"
TargetedRuntimeVersion="$(TargetedRuntimeVersion)"
StateFile="$(DesignTimeResolveAssemblyReferencesStateFile)"
InstalledAssemblySubsetTables="@(InstalledAssemblySubsetTables)"
IgnoreDefaultInstalledAssemblySubsetTables="$(IgnoreInstalledAssemblySubsetTables)"
TargetFrameworkSubsets="@(_ReferenceInstalledAssemblySubsets)"
FullTargetFrameworkSubsetNames="$(FullReferenceAssemblyNames)"
FullFrameworkFolders="$(_FullFrameworkReferenceAssemblyPaths)"
FullFrameworkAssemblyTables="@(FullFrameworkAssemblyTables)"
ProfileName="$(TargetFrameworkProfile)"
ResolvedSDKReferences="@(ResolvedSDKReference)"
IgnoreTargetFrameworkAttributeVersionMismatch ="$(DesignTimeIgnoreTargetFrameworkAttributeVersionMismatch)"
>
<Output TaskParameter="ResolvedFiles" ItemName="DesignTimeReferencePath"/>
<Output TaskParameter="FilesWritten" ItemName="FileWrites"/>
</ResolveAssemblyReference>
</Target>
<!--
============================================================
ResolveComReferences
Resolve COM references
[IN]
@(COMReference) - The list of COM references
$(InteropOutputPath) - The output directory in which to generate wrapper assemblies
When $(InteropOutputPath) is not set, then it defaults to $(IntermediateOutputPath).
[OUT]
@(ReferencePath) - Paths to referenced wrappers.
If ResolveComReferences is invoked from the IDE, PrepareForBuild may need to run to create directories.
============================================================
-->
<PropertyGroup>
<ComReferenceExecuteAsTool Condition="'$(ComReferenceExecuteAsTool)'==''">false</ComReferenceExecuteAsTool>
</PropertyGroup>
<Target
Name="ResolveComReferences"
Condition="'@(COMReference)'!='' or '@(COMFileReference)'!=''"
Returns="@(ReferencePath)"
DependsOnTargets="PrepareForBuild;ResolveKeySource;ResolveAssemblyReferences"
>
<PropertyGroup Condition=" '$(InteropOutputPath)' == '' ">
<InteropOutputPath>$(IntermediateOutputPath)</InteropOutputPath>
</PropertyGroup>
<MakeDir Directories="$(InteropOutputPath)"/>
<!--
Note: This task should not be batched, since it relies on having all the COM references fed into it at once.
-->
<PropertyGroup>
<ResolveComReferenceMSBuildArchitecture Condition="'$(ResolveComReferenceMSBuildArchitecture)' == ''">$(PlatformTargetAsMSBuildArchitecture)</ResolveComReferenceMSBuildArchitecture>
<ResolveComReferenceToolPath Condition="'$(ResolveComReferenceToolPath)' == ''">$(TargetFrameworkSDKToolsDirectory)</ResolveComReferenceToolPath>
<ResolveComReferenceSilent Condition="'$(ResolveComReferenceSilent)' == ''">false</ResolveComReferenceSilent>
</PropertyGroup>
<ResolveComReference
TypeLibNames="@(COMReference)"
TypeLibFiles="@(COMFileReference)"
ResolvedAssemblyReferences="@(ReferencePath)"
WrapperOutputDirectory="$(InteropOutputPath)"
IncludeVersionInInteropName="$(IncludeVersionInInteropName)"
KeyContainer="$(KeyContainerName)"
KeyFile="$(KeyOriginatorFile)"
DelaySign="$(DelaySign)"
StateFile="@(_ResolveComReferenceCache)"
TargetFrameworkVersion="$(TargetFrameworkVersion)"
TargetProcessorArchitecture="$(ProcessorArchitecture)"
NoClassMembers="$(ComReferenceNoClassMembers)"
Silent="$(ResolveComReferenceSilent)"
EnvironmentVariables="$(ResolveComReferenceEnvironment)"
SdkToolsPath="$(ResolveComReferenceToolPath)"
ExecuteAsTool="$(ComReferenceExecuteAsTool)"
MSBuildArchitecture="$(ResolveComReferenceMSBuildArchitecture)"
ContinueOnError="$(ContinueOnError)">
<Output TaskParameter="ResolvedFiles" ItemName="ReferencePath"/>
<Output TaskParameter="ResolvedFiles" ItemName="ComReferenceWrappers"/>
<Output TaskParameter="ResolvedFiles" ItemName="FileWrites"/>
<!-- This output list only includes items with Isolated attribute set to True. It's done by the task itself. -->
<Output TaskParameter="ResolvedModules" ItemName="ResolvedIsolatedComModules"/>
</ResolveComReference>
<ItemGroup>
<FileWrites Include="@(_ResolveComReferenceCache)"/>
<ReferenceComWrappersToCopyLocal Include="@(ComReferenceWrappers)" Condition="'%(ComReferenceWrappers.CopyLocal)'!='false'"/>
</ItemGroup>
</Target>
<!--
============================================================
_GetAssembliesMetadata
Resolve Assembly attributes for assemblies
The ResolveComReferences dependency is needed for defining COM-referenced wrappers only,
but this target handles all the assembly references from ResolveAssemblyReferences
This target is needed by the Visual Studio legacy project system during design time build only
[IN]
@(ReferencePath) - Paths to COM-referenced wrappers and other types of assembly references.
[OUT]
@(AssembliesMetadata) - Resolved assemblies attributes.
============================================================
-->
<Target
Name="_GetAssembliesMetadata"
Condition="'@(ReferencePath)'!=''and '$(DesignTimeBuild)' == 'true' "
Returns="@(_AssembliesMetadata)"
DependsOnTargets="ResolveComReferences"
>
<GetAssembliesMetadata
AssemblyPaths="@(ReferencePath)"
ContinueOnError="$(ContinueOnError)">
<Output TaskParameter="AssembliesMetadata" ItemName="_AssembliesMetadata"/>
</GetAssembliesMetadata>
</Target>
<Target
Name="ResolveComReferencesDesignTime"
Returns="@(ComReferenceWrappers)"
DependsOnTargets="ResolveComReferences" />
<!--
============================================================
ResolveFrameworkReferences
Overrridden by Microsoft.NET.Sdk to return
ResolvedFrameworkReference items in order to populate the
Frameworks node of the Solution Explorer in the IDE.
-->
<Target Name="ResolveFrameworkReferences" />
<!--
***********************************************************************************************
***********************************************************************************************
PrepareResources Section
***********************************************************************************************
***********************************************************************************************
-->
<!--
============================================================
PrepareResources
Prepare resources for the Compile step.
============================================================
-->
<PropertyGroup>
<PrepareResourcesDependsOn>
$(PrepareResourcesDependsOn);
PrepareResourceNames;
ResGen;
CompileLicxFiles
</PrepareResourcesDependsOn>
</PropertyGroup>
<Target
Name="PrepareResources"
DependsOnTargets="$(PrepareResourcesDependsOn)"/>
<!--
============================================================
PrepareResourceNames
Prepare the names of resource files.
============================================================
-->
<PropertyGroup>
<PrepareResourceNamesDependsOn>
AssignTargetPaths;
SplitResourcesByCulture;
CreateManifestResourceNames;
CreateCustomManifestResourceNames
</PrepareResourceNamesDependsOn>
</PropertyGroup>
<Target
Name="PrepareResourceNames"
DependsOnTargets="$(PrepareResourceNamesDependsOn)"/>
<!--
============================================================
AssignTargetPaths
This target creates <TargetPath> tags for items. <TargetPath> is a relative folder plus filename
for the destination of this item.
============================================================
-->
<PropertyGroup>
<AssignTargetPathsDependsOn></AssignTargetPathsDependsOn>
</PropertyGroup>
<Target
Name="AssignTargetPaths"
DependsOnTargets="$(AssignTargetPathsDependsOn)">
<ItemGroup>
<_Temporary Remove="@(_Temporary)" />
</ItemGroup>
<!-- AssignTargetPath generates TargetPath metadata that is consumed by CreateManifestResourceNames target for manifest name generation -->
<AssignTargetPath Files="@(EmbeddedResource)" RootFolder="$(MSBuildProjectDirectory)">
<Output TaskParameter="AssignedFiles" ItemName="_Temporary" />
</AssignTargetPath>
<ItemGroup>
<!-- Replace items in EmbeddedResource with the items emitted by the AssignTargetPath task that have the TargetPath metadata -->
<EmbeddedResource Remove="@(_Temporary)" />
<EmbeddedResource Include="@(_Temporary)" />
<_Temporary Remove="@(_Temporary)" />
</ItemGroup>
<AssignTargetPath Files="@(Content)" RootFolder="$(MSBuildProjectDirectory)">
<Output TaskParameter="AssignedFiles" ItemName="ContentWithTargetPath" />
</AssignTargetPath>
<AssignTargetPath Files="@(None)" RootFolder="$(MSBuildProjectDirectory)">
<Output TaskParameter="AssignedFiles" ItemName="_NoneWithTargetPath" />
</AssignTargetPath>
<AssignTargetPath Files="@(BaseApplicationManifest)" RootFolder="$(MSBuildProjectDirectory)">
<Output TaskParameter="AssignedFiles" ItemName="_DeploymentBaseManifestWithTargetPath"/>
</AssignTargetPath>
<AssignTargetPath Files="@(None)" RootFolder="$(MSBuildProjectDirectory)" Condition="'@(_DeploymentBaseManifestWithTargetPath)'=='' and '%(None.Extension)'=='.manifest'">
<Output TaskParameter="AssignedFiles" ItemName="_DeploymentBaseManifestWithTargetPath" />
</AssignTargetPath>
</Target>
<!--
============================================================
GetItemTargetPaths
This target returns all items that have TargetPath metadata assigned by the AssignTargetPaths target.
============================================================
-->
<Target
Name="GetItemTargetPaths"
DependsOnTargets="AssignTargetPaths"
Returns="
@(EmbeddedResource);
@(ContentWithTargetPath);
@(_NoneWithTargetPath);
@(_DeploymentBaseManifestWithTargetPath);
" />
<!--
============================================================
SplitResourcesByCulture
Split EmbeddedResource items into five lists based on whether
they are resx files, licx files or other resources and whether they should be localized. Also adds Type and Culture
metadata. Type indicates whether the resource is "Resx" or "Non-Resx".
[IN]/[OUT]
@(EmbeddedResource) - The raw list of resources.
[OUT]
@(_LicxFile) - The EmbeddedResource items with extension equal to '.licx'.
============================================================
-->
<Target
Name="SplitResourcesByCulture"
DependsOnTargets="AssignTargetPaths">
<Warning Condition="'@(ResxWithNoCulture)'!=''" Code="MSB9000" Text="ResxWithNoCulture item type is deprecated. Use EmbeddedResource items instead."/>
<Warning Condition="'@(ResxWithCulture)'!=''" Code="MSB9001" Text="ResxWithCulture item type is deprecated. Use EmbeddedResource items instead."/>
<Warning Condition="'@(NonResxWithCulture)'!=''" Code="MSB9002" Text="NonResxWithCulture item type is deprecated. Use EmbeddedResource items instead."/>
<Warning Condition="'@(NonResxWithNoCulture)'!=''" Code="MSB9003" Text="NonResxWithNoCulture item type is deprecated. Use EmbeddedResource items instead."/>
<ItemGroup>
<_LicxFile Include="@(EmbeddedResource)" Condition="'%(Extension)'=='.licx'"/>
<!-- CONSUMED FOR COMPATIBILITY REASONS ONLY. EMIT EMBEDDEDRESOURCE INSTEAD -->
<EmbeddedResource Include="@(ResxWithNoCulture);@(ResxWithCulture)">
<Type>Resx</Type>
</EmbeddedResource>
<EmbeddedResource Include="@(NonResxWithCulture);@(NonResxWithNoCulture)">
<Type>Non-Resx</Type>
</EmbeddedResource>
</ItemGroup>
<AssignCulture Files="@(EmbeddedResource)" Condition="'%(Extension)'!='.licx'">
<!-- Create the list of culture resx and embedded resource files -->
<Output TaskParameter="AssignedFilesWithCulture" ItemName="_MixedResourceWithCulture"/>
<!-- Create the list of non-culture resx and embedded resource files -->
<Output TaskParameter="AssignedFilesWithNoCulture" ItemName="_MixedResourceWithNoCulture"/>
</AssignCulture>
<ItemGroup>
<!-- Remove EmbeddedResource items that we have processed already
i.e. either Licx, or resources that don't have culture info -->
<EmbeddedResource Remove="@(_MixedResourceWithCulture)" />
<EmbeddedResource Remove="@(_MixedResourceWithNoCulture)" />
<EmbeddedResource Remove="@(_LicxFile)" />
<!-- Add back everything except Licx, so that we have culture info -->
<EmbeddedResource Include="@(_MixedResourceWithNoCulture);@(_MixedResourceWithCulture)" Condition="'%(Extension)'=='.resx' or '%(Extension)'=='.restext'">
<Type Condition="'%(_MixedResourceWithNoCulture.Type)'=='' and '%(_MixedResourceWithCulture.Type)'==''">Resx</Type>
</EmbeddedResource>
<EmbeddedResource Include="@(_MixedResourceWithNoCulture);@(_MixedResourceWithCulture)" Condition="'%(Extension)'!='.resx' and '%(Extension)'!='.restext'">
<Type Condition="'%(_MixedResourceWithNoCulture.Type)'=='' and '%(_MixedResourceWithCulture.Type)'==''">Non-Resx</Type>
</EmbeddedResource>
<!-- EMITTED FOR COMPATIBILITY REASONS ONLY. CONSUME EMBEDDEDRESOURCE INSTEAD -->
<ResxWithNoCulture Remove="@(ResxWithNoCulture)"/>
<NonResxWithNoCulture Remove="@(NonResxWithNoCulture)"/>
<ResxWithCulture Remove="@(ResxWithCulture)"/>
<NonResxWithCulture Remove="@(NonResxWithCulture)"/>
<ResxWithNoCulture Include="@(_MixedResourceWithNoCulture)" Condition="'%(WithCulture)'=='false' and ('%(Extension)'=='.resx' or '%(Extension)'=='.restext')"/>
<NonResxWithNoCulture Include="@(_MixedResourceWithNoCulture)" Condition="'%(WithCulture)'=='false' and ('%(Extension)'!='.resx' and '%(Extension)'!='.restext')"/>
<ResxWithCulture Include="@(_MixedResourceWithCulture)" Condition="'%(WithCulture)'=='true' and ('%(Extension)'=='.resx' or '%(Extension)'=='.restext')"/>
<NonResxWithCulture Include="@(_MixedResourceWithCulture)" Condition="'%(WithCulture)'=='true' and ('%(Extension)'!='.resx' and '%(Extension)'!='.restext')"/>
<!-- Clean up temporary lists -->
<_MixedResourceWithNoCulture Remove="@(_MixedResourceWithNoCulture)" />
<_MixedResourceWithCulture Remove="@(_MixedResourceWithCulture)" />
</ItemGroup>
</Target>
<!--
=======================================================================
CreateCustomManifestResourceNames
Allows custom manifest resource name generation tasks to plug
into the build process
=======================================================================
-->
<PropertyGroup>
<CreateCustomManifestResourceNamesDependsOn></CreateCustomManifestResourceNamesDependsOn>
</PropertyGroup>
<Target
Name="CreateCustomManifestResourceNames"
DependsOnTargets="$(CreateCustomManifestResourceNamesDependsOn)"/>
<!--
============================================================
ResGen
Run GenerateResource on the given resx files.
============================================================
-->
<PropertyGroup>
<ResGenDependsOn>ResolveAssemblyReferences;SplitResourcesByCulture;BeforeResGen;CoreResGen;AfterResGen</ResGenDependsOn>
<CoreResGenDependsOn>FindReferenceAssembliesForReferences</CoreResGenDependsOn>
<UseSourcePath Condition="'$(UseSourcePath)'==''">true</UseSourcePath>
<ResGenExecuteAsTool Condition="'$(ResGenExecuteAsTool)'==''">false</ResGenExecuteAsTool>
</PropertyGroup>
<Target
Name="ResGen"
DependsOnTargets="$(ResGenDependsOn)"/>
<!--
============================================================
BeforeResGen
Redefine this target in your project in order to run tasks just before Resgen.
============================================================
-->
<Target Name="BeforeResGen"/>
<!--
============================================================
AfterResGen
Redefine this target in your project in order to run tasks just after Resgen.
============================================================
-->
<Target Name="AfterResGen"/>
<!--
============================================================
CoreResGen
============================================================
-->
<Target
Name="CoreResGen"
DependsOnTargets="$(CoreResGenDependsOn)">
<ItemGroup>
<_Temporary Remove="@(_Temporary)" />
</ItemGroup>
<PropertyGroup>
<GenerateResourceMSBuildArchitecture Condition="'$(GenerateResourceMSBuildArchitecture)' == ''">$(PlatformTargetAsMSBuildArchitecture)</GenerateResourceMSBuildArchitecture>
<ResgenToolPath Condition="'$(ResgenToolPath)' == ''">$(TargetFrameworkSDKToolsDirectory)</ResgenToolPath>
</PropertyGroup>
<PropertyGroup Condition="'$(TargetFrameworkAsMSBuildRuntime)' != '' and '$(GenerateResourceMSBuildArchitecture)' != ''">
<!-- In the general case, we want to fail to run the task if the task host it's requesting doesn't exist, because we'd rather let the
user know there's something wrong than just silently generate something that's probably not quite right. However, in a few
circumstances, there are tasks that are already aware of runtime / bitness concerns, in which case even if we go ahead and run
the more recent version of the task, it should be able to generate something correct. GenerateResource is one such task, so
we check for the existence of the targeted task host so that we can use it preferentially, but if it can't be found, we'll fall
back to the current task since it's still mostly correct.
In particular, we need to do this because otherwise people with Dev10 on a machine that they upgrade to Win8 will be broken:
they'll have ResGen from the 7.0A SDK installed, so launching ResGen will still work, but the CLR2 task host is only installed by
the 8.0A SDK, which they won't have installed, and thus without this fallback mechanism, their projects targeting v3.5 will
suddenly start failing to build.-->
<GenerateResourceMSBuildRuntime
Condition="'$(GenerateResourceMSBuildRuntime)' == '' and
$([MSBuild]::DoesTaskHostExist(`$(TargetFrameworkAsMSBuildRuntime)`, `$(GenerateResourceMSBuildArchitecture)`))">$(TargetFrameworkAsMSBuildRuntime)</GenerateResourceMSBuildRuntime>
<!-- If the targeted runtime doesn't exist, fall back to current -->
<GenerateResourceMSBuildRuntime Condition="'$(GenerateResourceMSBuildRuntime)' == ''">CurrentRuntime</GenerateResourceMSBuildRuntime>
</PropertyGroup>
<!-- 4.0 task has some new parameters that we want to make use of if we're targeting 4.0 -->
<GenerateResource
Sources="@(EmbeddedResource)"
UseSourcePath="$(UseSourcePath)"
References="@(ReferencePathWithRefAssemblies)"
UsePreserializedResources="$(GenerateResourceUsePreserializedResources)"
AdditionalInputs="$(MSBuildAllProjects)"
NeverLockTypeAssemblies="$(GenerateResourceNeverLockTypeAssemblies)"
StateFile="$(IntermediateOutputPath)$(MSBuildProjectFile).GenerateResource.cache"
StronglyTypedClassName="%(EmbeddedResource.StronglyTypedClassName)"
StronglyTypedFileName="%(EmbeddedResource.StronglyTypedFileName)"
StronglyTypedLanguage="%(EmbeddedResource.StronglyTypedLanguage)"
StronglyTypedNamespace="%(EmbeddedResource.StronglyTypedNamespace)"
StronglyTypedManifestPrefix="%(EmbeddedResource.StronglyTypedManifestPrefix)"
PublicClass="%(EmbeddedResource.PublicClass)"
OutputResources="@(EmbeddedResource->'$(IntermediateOutputPath)%(ManifestResourceName).resources')"
Condition="'%(EmbeddedResource.Type)' == 'Resx' and '%(EmbeddedResource.GenerateResource)' != 'false' and '$(GenerateResourceMSBuildRuntime)' != 'CLR2'"
SdkToolsPath="$(ResgenToolPath)"
ExecuteAsTool="$(ResGenExecuteAsTool)"
EnvironmentVariables="$(ResGenEnvironment)"
WarnOnBinaryFormatterUse="$(GenerateResourceWarnOnBinaryFormatterUse)"
MSBuildRuntime="$(GenerateResourceMSBuildRuntime)"
MSBuildArchitecture="$(GenerateResourceMSBuildArchitecture)"
>
<Output TaskParameter="FilesWritten" ItemName="FileWrites"/>
<Output TaskParameter="StronglyTypedFileName" ItemName="Compile"/>
<!-- Gather Sources as an output since it will contain OutputResource metadata indicating the final output resource that it was compiled into -->
<Output TaskParameter="Sources" ItemName="_Temporary" />
</GenerateResource>
<!-- But we can't use those parameters if we're targeting 3.5, since we're using the 3.5 task -->
<GenerateResource
Sources="@(EmbeddedResource)"
UseSourcePath="$(UseSourcePath)"
References="@(ReferencePath)"
AdditionalInputs="$(MSBuildAllProjects)"
NeverLockTypeAssemblies="$(GenerateResourceNeverLockTypeAssemblies)"
StateFile="$(IntermediateOutputPath)$(MSBuildProjectFile).GenerateResource.cache"
StronglyTypedClassName="%(EmbeddedResource.StronglyTypedClassName)"
StronglyTypedFileName="%(EmbeddedResource.StronglyTypedFileName)"
StronglyTypedLanguage="%(EmbeddedResource.StronglyTypedLanguage)"
StronglyTypedNamespace="%(EmbeddedResource.StronglyTypedNamespace)"
StronglyTypedManifestPrefix="%(EmbeddedResource.StronglyTypedManifestPrefix)"
PublicClass="%(EmbeddedResource.PublicClass)"
OutputResources="@(EmbeddedResource->'$(IntermediateOutputPath)%(ManifestResourceName).resources')"
MSBuildRuntime="$(GenerateResourceMSBuildRuntime)"
MSBuildArchitecture="$(GenerateResourceMSBuildArchitecture)"
Condition="'%(EmbeddedResource.Type)' == 'Resx' and '%(EmbeddedResource.GenerateResource)' != 'false' and '$(GenerateResourceMSBuildRuntime)' == 'CLR2'">
<Output TaskParameter="FilesWritten" ItemName="FileWrites"/>
<Output TaskParameter="StronglyTypedFileName" ItemName="Compile"/>
<!-- Gather Sources as an output since it will contain OutputResource metadata indicating the final output resource that it was compiled into -->
<Output TaskParameter="Sources" ItemName="_Temporary" />
</GenerateResource>
<ItemGroup>
<EmbeddedResource Remove="@(_Temporary)" />
<!-- Add back the Sources list (with OutputResource metadata) that we output from GenerateResource into EmbeddedResource -->
<EmbeddedResource Include="@(_Temporary)" />
<_Temporary Remove="@(_Temporary)" />
<!-- EMITTED FOR COMPATIBILITY REASONS ONLY. CONSUME EMBEDDEDRESOURCE INSTEAD -->
<ManifestResourceWithNoCulture Include="@(EmbeddedResource->'%(OutputResource)')" Condition="'%(EmbeddedResource.WithCulture)'=='false' and '%(EmbeddedResource.Type)' == 'Resx'">
<EmittedForCompatibilityOnly>true</EmittedForCompatibilityOnly>
</ManifestResourceWithNoCulture>
<ManifestNonResxWithNoCultureOnDisk Include="@(EmbeddedResource)" Condition="'%(EmbeddedResource.WithCulture)'=='false' and '%(EmbeddedResource.Type)' == 'Non-Resx'">
<EmittedForCompatibilityOnly>true</EmittedForCompatibilityOnly>
</ManifestNonResxWithNoCultureOnDisk>
<!-- EMITTED FOR COMPATIBILITY REASONS ONLY. CONSUME EMBEDDEDRESOURCE INSTEAD -->
<ManifestResourceWithCulture Include="@(EmbeddedResource->'%(OutputResource)')" Condition="'%(EmbeddedResource.WithCulture)'=='true' and '%(EmbeddedResource.Type)' == 'Resx'">
<EmittedForCompatibilityOnly>true</EmittedForCompatibilityOnly>
</ManifestResourceWithCulture>
<ManifestNonResxWithCultureOnDisk Include="@(EmbeddedResource)" Condition="'%(EmbeddedResource.WithCulture)'=='true' and '%(EmbeddedResource.Type)' == 'Non-Resx'">
<EmittedForCompatibilityOnly>true</EmittedForCompatibilityOnly>
</ManifestNonResxWithCultureOnDisk>
</ItemGroup>
</Target>
<!--
============================================================
CompileLicxFiles
Compile .licx files (containing information about licensed controls used by the application) into .licenses files.
[IN]
@(_LicxFile) - The list of .licx files in the project (usually there will be just one)
[OUT]
@(CompiledLicenseFile) - The list of compiled .licenses files (there will be just one)
============================================================
-->
<PropertyGroup>
<CompileLicxFilesDependsOn></CompileLicxFilesDependsOn>
</PropertyGroup>
<Target
Name="CompileLicxFiles"
Condition="'@(_LicxFile)'!=''"
DependsOnTargets="$(CompileLicxFilesDependsOn)"
Inputs="$(MSBuildAllProjects);@(_LicxFile);@(ReferencePathWithRefAssemblies);@(ReferenceDependencyPaths)"
Outputs="$(IntermediateOutputPath)$(TargetFileName).licenses">
<PropertyGroup>
<LCMSBuildArchitecture Condition="'$(LCMSBuildArchitecture)' == ''">$(PlatformTargetAsMSBuildArchitecture)</LCMSBuildArchitecture>
</PropertyGroup>
<LC
Sources="@(_LicxFile)"
LicenseTarget="$(TargetFileName)"
OutputDirectory="$(IntermediateOutputPath)"
OutputLicense="$(IntermediateOutputPath)$(TargetFileName).licenses"
ReferencedAssemblies="@(ReferencePathWithRefAssemblies);@(ReferenceDependencyPaths)"
NoLogo="$(NoLogo)"
ToolPath="$(LCToolPath)"
SdkToolsPath="$(TargetFrameworkSDKToolsDirectory)"
EnvironmentVariables="$(LCEnvironment)"
MSBuildArchitecture="$(LCMSBuildArchitecture)"
TargetFrameworkVersion="$(TargetFrameworkVersion)"
>
<Output TaskParameter="OutputLicense" ItemName="CompiledLicenseFile"/>
<Output TaskParameter="OutputLicense" ItemName="FileWrites"/>
</LC>
</Target>
<!--
***********************************************************************************************
***********************************************************************************************
ResolveKeySource Section
***********************************************************************************************
***********************************************************************************************
-->
<!--
============================================================
ResolveKeySource
Resolve the strong name key used to sign the assembly as well as the certificate used to
sign the ClickOnce manifests.
[IN]
$(AssemblyOriginatorKeyFile) - The file used to sign the assembly (.snk or .pfx)
$(ManifestCertificateThumbprint) - The thumbprint used to locate the certificate in the
user's certificate store.
$(ManifestKeyFile) - The key file that contains the certificate in case the
certificate is not in the user's store.
[OUT]
$(ResolvedAssemblyKeyFile) - Key used to sign the assembly
$(_DeploymentResolvedManifestCertificateThumbprint) - Certificate used to sign the manifests
============================================================
-->
<Target
Name="ResolveKeySource"
Condition="$(SignManifests) == 'true' or $(SignAssembly) == 'true'">
<ResolveKeySource
KeyFile="$(AssemblyOriginatorKeyFile)"
CertificateThumbprint="$(ManifestCertificateThumbprint)"
CertificateFile="$(ManifestKeyFile)"
SuppressAutoClosePasswordPrompt="$(BuildingInsideVisualStudio)"
ShowImportDialogDespitePreviousFailures="$(BuildingProject)"
ContinueOnError="!$(BuildingProject)"
>
<Output TaskParameter="ResolvedKeyFile" PropertyName="KeyOriginatorFile" Condition=" '$(SignAssembly)' == 'true' "/>
<Output TaskParameter="ResolvedKeyContainer" PropertyName="KeyContainerName" Condition=" '$(SignAssembly)' == 'true' "/>
<Output TaskParameter="ResolvedThumbprint" PropertyName="_DeploymentResolvedManifestCertificateThumbprint" Condition=" '$(SignManifests)' == 'true' "/>
</ResolveKeySource>
</Target>
<!--
***********************************************************************************************
***********************************************************************************************
Compile Section
***********************************************************************************************
***********************************************************************************************
-->
<!--
============================================================
Compile
============================================================
-->
<PropertyGroup>
<CompileDependsOn>
ResolveReferences;
ResolveKeySource;
SetWin32ManifestProperties;
FindReferenceAssembliesForReferences;
_GenerateCompileInputs;
BeforeCompile;
_TimeStampBeforeCompile;
_GenerateCompileDependencyCache;
CoreCompile;
_TimeStampAfterCompile;
AfterCompile;
</CompileDependsOn>
</PropertyGroup>
<Target
Name="Compile"
DependsOnTargets="$(CompileDependsOn)"/>
<!--
============================================================
_GenerateCompileInputs
Create the _CoreCompileResourceInputs list of inputs to the CoreCompile target.
============================================================
-->
<Target Name="_GenerateCompileInputs">
<Warning Condition="'@(ManifestResourceWithNoCulture)'!='' and '%(ManifestResourceWithNoCulture.EmittedForCompatibilityOnly)'==''" Code="MSB9004" Text="ManifestResourceWithNoCulture item type is deprecated. Emit EmbeddedResource items instead, with metadata WithCulture='false', Type='Resx', and optional LogicalName."/>
<Warning Condition="'@(ManifestNonResxWithNoCultureOnDisk)'!='' and '%(ManifestNonResxWithNoCultureOnDisk.EmittedForCompatibilityOnly)'==''" Code="MSB9005" Text="ManifestNonResxWithNoCultureOnDisk item type is deprecated. Emit EmbeddedResource items instead, with metadata WithCulture='false', Type='Non-Resx', and optional LogicalName."/>
<ItemGroup>
<!-- _CoreCompileResourceInputs is the list of TLDA inputs that should trigger CoreCompile, and are listed as inputs to that target -->
<_CoreCompileResourceInputs Include="@(EmbeddedResource->'%(OutputResource)')" Condition="'%(EmbeddedResource.WithCulture)' == 'false' and '%(EmbeddedResource.Type)' == 'Resx'" />
<_CoreCompileResourceInputs Include="@(EmbeddedResource)" Condition="'%(EmbeddedResource.WithCulture)' == 'false' and '%(EmbeddedResource.Type)' == 'Non-Resx' " />
<!-- CONSUMED FOR COMPATIBILITY REASONS ONLY. EMIT EMBEDDEDRESOURCE INSTEAD -->
<_CoreCompileResourceInputs Include="@(ManifestResourceWithNoCulture)" Condition="'%(ManifestResourceWithNoCulture.EmittedForCompatibilityOnly)'==''">
<Type>Resx</Type>
<WithCulture>false</WithCulture>
</_CoreCompileResourceInputs>
<_CoreCompileResourceInputs Include="@(ManifestNonResxWithNoCultureOnDisk)" Condition="'%(ManifestNonResxWithNoCultureOnDisk.EmittedForCompatibilityOnly)'==''">
<Type>Non-Resx</Type>
<WithCulture>false</WithCulture>
</_CoreCompileResourceInputs>
</ItemGroup>
</Target>
<!--
============================================================
GenerateTargetFrameworkMonikerAttribute
Emit the target framework moniker attribute as a code fragment into a temporary source file for the compiler.
============================================================
-->
<PropertyGroup Condition="'$(TargetFrameworkMoniker)' != ''">
<!-- Do not clean if we are going to default the path to the temp directory -->
<TargetFrameworkMonikerAssemblyAttributesFileClean Condition="'$(TargetFrameworkMonikerAssemblyAttributesFileClean)' == '' and '$(TargetFrameworkMonikerAssemblyAttributesPath)' != ''">true</TargetFrameworkMonikerAssemblyAttributesFileClean>
<TargetFrameworkMonikerAssemblyAttributesPath Condition="'$(TargetFrameworkMonikerAssemblyAttributesPath)' == ''">$([System.IO.Path]::Combine('$(IntermediateOutputPath)','$(TargetFrameworkMoniker).AssemblyAttributes$(DefaultLanguageSourceExtension)'))</TargetFrameworkMonikerAssemblyAttributesPath>
</PropertyGroup>
<PropertyGroup>
<GenerateTargetFrameworkAttribute Condition="'$(GenerateTargetFrameworkAttribute)' == '' and '$(TargetFrameworkMoniker)' != '' and '$(TargetingClr2Framework)' != 'true'">true</GenerateTargetFrameworkAttribute>
</PropertyGroup>
<ItemGroup Condition="'$(TargetFrameworkMonikerAssemblyAttributesFileClean)' == 'true'">
<Clean Include="$(TargetFrameworkMonikerAssemblyAttributesPath)"/>
</ItemGroup>
<Target Name="GenerateTargetFrameworkMonikerAttribute"
BeforeTargets="BeforeCompile"
DependsOnTargets="PrepareForBuild;GetReferenceAssemblyPaths"
Inputs="$(MSBuildToolsPath)\Microsoft.Common.targets"
Outputs="$(TargetFrameworkMonikerAssemblyAttributesPath)"
Condition="'@(Compile)' != '' and '$(GenerateTargetFrameworkAttribute)' == 'true'">
<!-- This is a file shared between projects so we have to take care to handle simultaneous writes (by ContinueOnError)
and a race between clean from one project and build from another (by not adding to FilesWritten so it doesn't clean) -->
<WriteLinesToFile
File="$(TargetFrameworkMonikerAssemblyAttributesPath)"
Lines="$(TargetFrameworkMonikerAssemblyAttributeText)"
Overwrite="true"
ContinueOnError="true"
Condition="'@(Compile)' != '' and '$(TargetFrameworkMonikerAssemblyAttributeText)' != ''"
/>
<ItemGroup Condition="'@(Compile)' != '' and '$(TargetFrameworkMonikerAssemblyAttributeText)' != ''">
<Compile Include="$(TargetFrameworkMonikerAssemblyAttributesPath)"/>
<!-- Do not put in FileWrites: this is a file shared between projects in %temp%, and cleaning it would create a race between projects during rebuild -->
</ItemGroup>
</Target>
<!--
============================================================
GenerateAdditionalSources
Emit any specified code fragments into a temporary source file for the compiler.
============================================================
-->
<PropertyGroup Condition="'$(AssemblyAttributesPath)' != ''">
<GenerateAdditionalSources Condition="'$(GenerateAdditionalSources)' == ''">true</GenerateAdditionalSources>
</PropertyGroup>
<ItemGroup Condition="'$(AssemblyAttributesPath)' != ''">
<Clean Include="$(AssemblyAttributesPath)" Condition="'$(AssemblyAttributesFileClean)' != 'false'" />
</ItemGroup>
<Target Name="GenerateAdditionalSources"
BeforeTargets="BeforeCompile"
DependsOnTargets="PrepareForBuild;GetReferenceAssemblyPaths"
Inputs="$(MSBuildAllProjects)"
Outputs="$(AssemblyAttributesPath)"
Condition="'@(AssemblyAttributes)' != '' and '$(GenerateAdditionalSources)' == 'true'">
<WriteCodeFragment
AssemblyAttributes="@(AssemblyAttributes)"
OutputFile="$(AssemblyAttributesPath)"
Language="$(Language)">
<Output TaskParameter="OutputFile" ItemName="Compile"/>
<Output TaskParameter="OutputFile" ItemName="FileWrites"/>
</WriteCodeFragment>
</Target>
<!--
============================================================
BeforeCompile
Redefine this target in your project in order to run tasks just before Compile.
============================================================
-->
<Target Name="BeforeCompile"/>
<!--
============================================================
AfterCompile
Redefine this target in your project in order to run tasks just after Compile.
============================================================
-->
<Target Name="AfterCompile"/>
<!--
============================================================
_TimeStampBeforeCompile
If post-build events are set to fire "OnOutputUpdated", then take before
and after timestamps so that we can compare them.
============================================================
-->
<Target
Name="_TimeStampBeforeCompile"
Condition="'$(RunPostBuildEvent)'=='OnOutputUpdated' or ('$(RegisterForComInterop)'=='true' and '$(OutputType)'=='library')">
<PropertyGroup>
<_AssemblyTimestampBeforeCompile>%(IntermediateAssembly.ModifiedTime)</_AssemblyTimestampBeforeCompile>
</PropertyGroup>
</Target>
<!--
============================================================
_GenerateSuggestedBindingRedirectsCache
Generate a file used to track whether suggested binding redirects changed between builds.
@(SuggestedBindingRedirects) never contains a file on disk, so create a file
that contains a hash of the items to prevent `GenerateBindingRedirects`
from running every build.
See https://github.com/dotnet/msbuild/issues/5943 for details.
============================================================
-->
<Target Name="_GenerateSuggestedBindingRedirectsCache" Condition="'$(DesignTimeBuild)' != 'true' and '$(BuildingProject)' == 'true'" DependsOnTargets="ResolveAssemblyReferences">
<PropertyGroup>
<SuggestedBindingRedirectsCacheFile>$(IntermediateOutputPath)$(MSBuildProjectFile).SuggestedBindingRedirects.cache</SuggestedBindingRedirectsCacheFile>
</PropertyGroup>
<Hash ItemsToHash="@(SuggestedBindingRedirects)">
<Output TaskParameter="HashResult" PropertyName="SuggestedBindingRedirectsHash"/>
</Hash>
<WriteLinesToFile Lines="$(SuggestedBindingRedirectsHash)" File="$(SuggestedBindingRedirectsCacheFile)" Overwrite="true" WriteOnlyWhenDifferent="true"/>
<ItemGroup>
<FileWrites Include="$(SuggestedBindingRedirectsCacheFile)"/>
</ItemGroup>
</Target>
<!--
============================================================
_GenerateCompileDependencyCache
Generate a file used to track compiler dependencies between incremental build
executions. This handles cases where items are added or removed from a glob (e.g.
<Compile Include="**\*.cs" />) and can't otherwise be detected with timestamp
comparisons. The file contains a hash of compiler inputs that are known to
contribute to incremental build inconsistencies.
============================================================
-->
<Target Name="_GenerateCompileDependencyCache" Condition="'$(DesignTimeBuild)' != 'true' and '$(BuildingProject)' == 'true'" DependsOnTargets="ResolveAssemblyReferences">
<ItemGroup>
<CustomAdditionalCompileInputs Include="$(IntermediateOutputPath)$(MSBuildProjectFile).CoreCompileInputs.cache" />
<CoreCompileCache Include="@(Compile)" />
<CoreCompileCache Include="@(ReferencePath)" />
<CoreCompileCache Include="$(DefineConstants)" />
<CoreCompileCache Include="$(LangVersion)" />
<CoreCompileCache Include="$(Deterministic)" />
<CoreCompileCache Include="$(PathMap)" />
</ItemGroup>
<Hash
ItemsToHash="@(CoreCompileCache)"
IgnoreCase="$([MSBuild]::ValueOrDefault(`$(CoreCompileCacheIgnoreCase)`, `true`))">
<Output TaskParameter="HashResult" PropertyName="CoreCompileDependencyHash" />
</Hash>
<WriteLinesToFile Lines="$(CoreCompileDependencyHash)" File="$(IntermediateOutputPath)$(MSBuildProjectFile).CoreCompileInputs.cache" Overwrite="true" WriteOnlyWhenDifferent="true" />
<ItemGroup>
<FileWrites Include="$(IntermediateOutputPath)$(MSBuildProjectFile).CoreCompileInputs.cache" />
</ItemGroup>
</Target>
<!--
============================================================
_TimeStampAfterCompile
If post-build events are set to fire "OnOutputUpdated", then take before
and after timestamps so that we can compare them.
============================================================
-->
<Target
Name="_TimeStampAfterCompile"
Condition="'$(RunPostBuildEvent)'=='OnOutputUpdated' or ('$(RegisterForComInterop)'=='true' and '$(OutputType)'=='library')">
<PropertyGroup>
<_AssemblyTimestampAfterCompile>%(IntermediateAssembly.ModifiedTime)</_AssemblyTimestampAfterCompile>
</PropertyGroup>
</Target>
<!--
================================================================
_ComputeNonExistentFileProperty
There are certain situations in which we want to always run the CoreCompile target (and
thus the Csc task), even if the timestamps of the outputs appear to be up-to-date on disk.
If we're inside the IDE during design-time, then the Csc/Vbc/Vjc task is simply being used to
initialize the host compiler, so we always want to run it. Also, if we're inside the IDE, and
the host compiler is responsible for doing the compilation during an actual build, we want to let
the host compiler determine whether the output is up-to-date, because there may be source files
in the IDE's in-memory buffers that we don't know about.
So, we always run the CoreCompile target if we're in the IDE, and either we're in design-time or
we're delegating to the host compiler for the actual build.
We compare against BuildOutOfProcess != true because we cannot assume that the build process will
have set BuildOutOfProcess to true or false. Therefore the default behavior should be to do the
legacy behavior seen before BuildingOutOfProcess was introduced if the property is not set.
================================================================
-->
<Target
Name="_ComputeNonExistentFileProperty"
Condition="('$(BuildingInsideVisualStudio)' == 'true') and ('$(BuildingOutOfProcess)' != 'true') and (('$(BuildingProject)' == 'false') or ('$(UseHostCompilerIfAvailable)' == 'true'))">
<PropertyGroup>
<NonExistentFile>__NonExistentSubDir__\__NonExistentFile__</NonExistentFile>
</PropertyGroup>
</Target>
<!--
***********************************************************************************************
***********************************************************************************************
GenerateSerializationAssemblies Section
***********************************************************************************************
***********************************************************************************************
-->
<PropertyGroup>
<_SGenDllName>$(TargetName).XmlSerializers.dll</_SGenDllName>
<_SGenDllCreated>false</_SGenDllCreated>
<_SGenGenerateSerializationAssembliesConfig>$(GenerateSerializationAssemblies)</_SGenGenerateSerializationAssembliesConfig>
<_SGenGenerateSerializationAssembliesConfig Condition="'$(GenerateSerializationAssemblies)' == ''">Auto</_SGenGenerateSerializationAssembliesConfig>
<_SGenGenerateSerializationAssembliesConfig Condition="'$(ConfigurationName)'=='Debug' and '$(_SGenGenerateSerializationAssembliesConfig)' == 'Auto'">Off</_SGenGenerateSerializationAssembliesConfig>
<SGenUseProxyTypes Condition="'$(SGenUseProxyTypes)' == ''">true</SGenUseProxyTypes>
<SGenUseKeep Condition="'$(SGenUseKeep)'==''">false</SGenUseKeep>
<SGenShouldGenerateSerializer Condition="'$(SGenShouldGenerateSerializer)' == ''">true</SGenShouldGenerateSerializer>
</PropertyGroup>
<!--
============================================================
GenerateSerializationAssemblies
Run GenerateSerializationAssemblies on the assembly produced by this build.
[IN]
@(BuildAssemblyName) - The assembly generated by this build.
@(BuildAssemblyPath) - The path where the assembly resides.
@(ReferencePath) - The list of references used by this assembly.
[OUT]
@(SerializationAssembly) - The path to the serialization assembly. Maybe we'll just append to an existing list.
============================================================
-->
<Target
Name="GenerateSerializationAssemblies"
Condition="'$(_SGenGenerateSerializationAssembliesConfig)' == 'On' or ('@(WebReferenceUrl)'!='' and '$(_SGenGenerateSerializationAssembliesConfig)' == 'Auto')"
DependsOnTargets="AssignTargetPaths;Compile;ResolveKeySource"
Inputs="$(MSBuildAllProjects);@(IntermediateAssembly)"
Outputs="$(IntermediateOutputPath)$(_SGenDllName)">
<PropertyGroup>
<SGenMSBuildArchitecture Condition="'$(SGenMSBuildArchitecture)' == ''">$(PlatformTargetAsMSBuildArchitecture)</SGenMSBuildArchitecture>
</PropertyGroup>
<SGen
BuildAssemblyName="$(TargetFileName)"
BuildAssemblyPath="$(IntermediateOutputPath)"
References="@(ReferencePath)"
ShouldGenerateSerializer="$(SGenShouldGenerateSerializer)"
UseProxyTypes="$(SGenUseProxyTypes)"
UseKeep="$(SGenUseKeep)"
KeyContainer="$(KeyContainerName)"
KeyFile="$(KeyOriginatorFile)"
DelaySign="$(DelaySign)"
ToolPath="$(SGenToolPath)"
SdkToolsPath="$(TargetFrameworkSDKToolsDirectory)"
EnvironmentVariables="$(SGenEnvironment)"
MSBuildArchitecture="$(SGenMSBuildArchitecture)"
SerializationAssembly="$(IntermediateOutputPath)$(_SGenDllName)"
Platform="$(SGenPlatformTarget)"
Types="$(SGenSerializationTypes)">
<Output TaskParameter="SerializationAssembly" ItemName="SerializationAssembly"/>
</SGen>
</Target>
<!--
***********************************************************************************************
***********************************************************************************************
CreateSatelliteAssemblies Section
***********************************************************************************************
***********************************************************************************************
-->
<!--
============================================================
CreateSatelliteAssemblies
Create one satellite assembly for every unique culture in the resources.
============================================================
-->
<PropertyGroup>
<CreateSatelliteAssembliesDependsOn>
$(CreateSatelliteAssembliesDependsOn);
_GenerateSatelliteAssemblyInputs;
ComputeIntermediateSatelliteAssemblies;
GenerateSatelliteAssemblies
</CreateSatelliteAssembliesDependsOn>
</PropertyGroup>
<Target
Name="CreateSatelliteAssemblies"
DependsOnTargets="$(CreateSatelliteAssembliesDependsOn)" />
<!--
============================================================
_GenerateSatelliteAssemblyInputs
Create the _SatelliteAssemblyResourceInputs list of inputs to the CreateSatelliteAssemblies target.
============================================================
-->
<Target Name="_GenerateSatelliteAssemblyInputs">
<Warning Condition="'@(ManifestResourceWithCulture)'!='' and '%(ManifestResourceWithCulture.EmittedForCompatibilityOnly)'==''" Code="MSB9006" Text="ManifestResourceWithCulture item type is deprecated. Emit EmbeddedResource items instead, with metadata WithCulture='true', Type='Resx', and optional LogicalName."/>
<Warning Condition="'@(ManifestNonResxWithCultureOnDisk)'!='' and '%(ManifestNonResxWithCultureOnDisk.EmittedForCompatibilityOnly)'==''" Code="MSB9007" Text="ManifestNonResxWithCultureOnDisk item type is deprecated. Emit EmbeddedResource items instead, with metadata WithCulture='true', Type='Non-Resx', and optional LogicalName."/>
<ItemGroup>
<!-- _SatelliteAssemblyResourceInputs is the list of TLDA inputs that should trigger CreateSatelliteAssemblies, so listed as inputs to that target -->
<_SatelliteAssemblyResourceInputs Include="@(EmbeddedResource->'%(OutputResource)')" Condition="'%(EmbeddedResource.WithCulture)' == 'true' and '%(EmbeddedResource.Type)' == 'Resx'" />
<_SatelliteAssemblyResourceInputs Include="@(EmbeddedResource)" Condition="'%(EmbeddedResource.WithCulture)' == 'true' and '%(EmbeddedResource.Type)' == 'Non-Resx'" />
<!-- CONSUMED FOR COMPATIBILITY REASONS ONLY. EMIT EMBEDDEDRESOURCE INSTEAD -->
<_SatelliteAssemblyResourceInputs Include="@(ManifestResourceWithCulture)" Condition="'%(ManifestResourceWithCulture.EmittedForCompatibilityOnly)'==''">
<Type>Resx</Type>
<WithCulture>true</WithCulture>
</_SatelliteAssemblyResourceInputs>
<_SatelliteAssemblyResourceInputs Include="@(ManifestNonResxWithCultureOnDisk)" Condition="'%(ManifestNonResxWithCultureOnDisk.EmittedForCompatibilityOnly)'==''">
<Type>Non-Resx</Type>
<WithCulture>true</WithCulture>
</_SatelliteAssemblyResourceInputs>
</ItemGroup>
</Target>
<!--
============================================================
GenerateSatelliteAssemblies
Actually run al.exe to create the satellite assemblies.
============================================================
-->
<Target Name="GenerateSatelliteAssemblies"
Inputs="$(MSBuildAllProjects);@(_SatelliteAssemblyResourceInputs);$(IntermediateOutputPath)$(TargetName)$(TargetExt)"
Outputs="$(IntermediateOutputPath)%(Culture)\$(TargetName).resources.dll"
Condition="'@(_SatelliteAssemblyResourceInputs)' != '' and '$(GenerateSatelliteAssembliesForCore)' != 'true'">
<PropertyGroup>
<_ALExeToolPath Condition="'$(_ALExeToolPath)' == ''">$(TargetFrameworkSDKToolsDirectory)</_ALExeToolPath>
</PropertyGroup>
<MakeDir
Directories="@(EmbeddedResource->'$(IntermediateOutputPath)%(Culture)')" />
<AL AlgorithmId="$(Satellite_AlgorithmId)"
BaseAddress="$(Satellite_BaseAddress)"
CompanyName="$(Satellite_CompanyName)"
Configuration="$(Satellite_Configuration)"
Copyright="$(Satellite_Copyright)"
Culture="%(Culture)"
DelaySign="$(DelaySign)"
Description="$(Satellite_Description)"
EmbedResources="@(_SatelliteAssemblyResourceInputs)"
EnvironmentVariables="$(AlEnvironment)"
EvidenceFile="$(Satellite_EvidenceFile)"
FileVersion="$(Satellite_FileVersion)"
Flags="$(Satellite_Flags)"
GenerateFullPaths="$(Satellite_GenerateFullPaths)"
KeyContainer="$(KeyContainerName)"
KeyFile="$(KeyOriginatorFile)"
LinkResources="@(Satellite_LinkResource)"
MainEntryPoint="$(Satellite_MainEntryPoint)"
OutputAssembly="$(IntermediateOutputPath)%(Culture)\$(TargetName).resources.dll"
Platform="$(PlatformTarget)"
ProductName="$(Satellite_ProductName)"
ProductVersion="$(Satellite_ProductVersion)"
ResponseFiles="@(AlResponseFile)"
SourceModules="@(Satellite_SourceModule)"
TargetType="$(Satellite_TargetType)"
TemplateFile="$(IntermediateOutputPath)$(TargetName)$(TargetExt)"
Title="$(Satellite_Title)"
ToolPath="$(AlToolPath)"
ToolExe ="$(AlToolExe)"
SdkToolsPath="$(_ALExeToolPath)"
Trademark="$(Satellite_Trademark)"
Version="$(Satellite_Version)"
Win32Icon="$(Satellite_Win32Icon)"
Win32Resource="$(Satellite_Win32Resource)">
<Output TaskParameter="OutputAssembly" ItemName="FileWrites"/>
</AL>
</Target>
<!--
============================================================
ComputeIntermediateSatelliteAssemblies
Compute the paths to the intermediate satellite assemblies,
with culture attributes so we can copy them to the right place.
============================================================
-->
<PropertyGroup>
<ComputeIntermediateSatelliteAssembliesDependsOn>
CreateManifestResourceNames
</ComputeIntermediateSatelliteAssembliesDependsOn>
</PropertyGroup>
<Target
Name="ComputeIntermediateSatelliteAssemblies"
Condition="@(EmbeddedResource->'%(WithCulture)') != ''"
DependsOnTargets="$(ComputeIntermediateSatelliteAssembliesDependsOn)">
<ItemGroup>
<IntermediateSatelliteAssembliesWithTargetPath Include="$(IntermediateOutputPath)%(EmbeddedResource.Culture)\$(TargetName).resources.dll"
Condition="'%(EmbeddedResource.Culture)' != ''">
<Culture>%(EmbeddedResource.Culture)</Culture>
<TargetPath>%(EmbeddedResource.Culture)\$(TargetName).resources.dll</TargetPath>
</IntermediateSatelliteAssembliesWithTargetPath>
</ItemGroup>
</Target>
<!--
***********************************************************************************************
***********************************************************************************************
SetWin32ManifestProperties Section
***********************************************************************************************
***********************************************************************************************
-->
<PropertyGroup>
<EmbeddedWin32Manifest>$(Win32Manifest)</EmbeddedWin32Manifest>
</PropertyGroup>
<!--
============================================================
SetWin32ManifestProperties
Set Win32Manifest and EmbeddedManifest properties to be used later in the build.
============================================================
-->
<Target
Name="SetWin32ManifestProperties"
Condition="'$(Win32Manifest)'==''"
DependsOnTargets="ResolveComReferences;ResolveNativeReferences;_SetExternalWin32ManifestProperties;_SetEmbeddedWin32ManifestProperties" />
<Target
Name="_SetExternalWin32ManifestProperties"
Condition="'$(GenerateClickOnceManifests)'=='true' or '@(NativeReference)'!='' or '@(ResolvedIsolatedComModules)'!=''" >
<PropertyGroup>
<!-- set _DeploymentBaseManifest property to the value of $(ApplicationManifest) if the property is set,
but use _DeploymentBaseManifestWithTargetPath item-group if the property is not set to support backwards
compat with earlier MSBuild versions when manifest files were determined by the item-group. If the newer
property is set though, prefer that one be used to specify the manifest. -->
<_DeploymentBaseManifest>$(ApplicationManifest)</_DeploymentBaseManifest>
<_DeploymentBaseManifest Condition="'$(_DeploymentBaseManifest)'==''">@(_DeploymentBaseManifestWithTargetPath)</_DeploymentBaseManifest>
<!-- when using external manifests, always set the NoWin32Manifest property to
true if there is no value set in the incoming project file so the
compilers that support manifest embedding know not to add
a manifest to their built assemblies -->
<NoWin32Manifest Condition="'$(NoWin32Manifest)'==''">true</NoWin32Manifest>
</PropertyGroup>
</Target>
<Target
Name="_SetEmbeddedWin32ManifestProperties"
Condition="'$(GenerateClickOnceManifests)'!='true' and '@(NativeReference)'=='' and '@(ResolvedIsolatedComModules)'==''" >
<PropertyGroup>
<EmbeddedWin32Manifest>$(ApplicationManifest)</EmbeddedWin32Manifest>
<Win32Manifest>$(ApplicationManifest)</Win32Manifest>
</PropertyGroup>
<GetFrameworkPath Condition="'$(ApplicationManifest)'=='' and '$(NoWin32Manifest)'!='true'">
<Output TaskParameter="FrameworkVersion40Path" PropertyName="_FrameworkVersion40Path" />
</GetFrameworkPath>
<PropertyGroup>
<EmbeddedWin32Manifest Condition="'$(ApplicationManifest)'=='' and '$(NoWin32Manifest)'!='true' and Exists('$(_FrameworkVersion40Path)\default.win32manifest')">$(_FrameworkVersion40Path)\default.win32manifest</EmbeddedWin32Manifest>
</PropertyGroup>
</Target>
<!--
***********************************************************************************************
***********************************************************************************************
GenerateManifests Section
***********************************************************************************************
***********************************************************************************************
-->
<!--
============================================================
GenerateManifests
Generates ClickOnce application and deployment manifests or a native manifest.
============================================================
-->
<PropertyGroup>
<GenerateManifestsDependsOn>
SetWin32ManifestProperties;
GenerateApplicationManifest;
GenerateDeploymentManifest
</GenerateManifestsDependsOn>
</PropertyGroup>
<!--
============================================================
_GenerateResolvedDeploymentManifestEntryPoint
Use the ResolveManifestFiles to generate the GenerateResolvedDeploymentManifestEntryPoint
============================================================
-->
<Target
Name="_GenerateResolvedDeploymentManifestEntryPoint">
<ItemGroup>
<_DeploymentPublishFileOfTypeManifestEntryPoint Include="@(PublishFile)" Condition="'%(FileType)'=='ManifestEntryPoint'"/>
</ItemGroup>
<ResolveManifestFiles
TargetFrameworkVersion="$(TargetFrameworkVersion)"
TargetFrameworkIdentifier="$(TargetFrameworkIdentifier)"
SigningManifests="$(SignManifests)"
DeploymentManifestEntryPoint="@(ApplicationManifest)"
PublishFiles="@(_DeploymentPublishFileOfTypeManifestEntryPoint)">
<Output TaskParameter="OutputDeploymentManifestEntryPoint" ItemName="_DeploymentResolvedDeploymentManifestEntryPoint"/>
</ResolveManifestFiles>
</Target>
<Target
Name="GenerateManifests"
Condition="'$(GenerateClickOnceManifests)'=='true' or '@(NativeReference)'!='' or '@(ResolvedIsolatedComModules)'!='' or '$(GenerateAppxManifest)' == 'true'"
DependsOnTargets="$(GenerateManifestsDependsOn)"/>
<!--
============================================================
GenerateApplicationManifest
Generates a ClickOnce or native application manifest.
An application manifest specifies declarative application identity, dependency and security information.
[IN]
$(_DeploymentBaseManifest) - The base app.manifest from project.
@(ResolvedIsolatedComModules) - The list of COM references to be isolated as reg-free COM dependencies for native assembly loader.
@(_DeploymentManifestFiles) - The list of loose files (content, pdb, xml, etc.) for ClickOnce.
@(_DeploymentManifestDependencies) - The list of application dependencies (typically this is the set of assembly dependencies in bin\) for ClickOnce.
@(AppConfigWithTargetPath) - App config file, if present.
$(_DeploymentManifestType) - Type of manifest to be generated, either "Native" or "ClickOnce".
[OUT]
@(ApplicationManifest) - Generated native or ClickOnce application manifest, i.e. WindowsApplication1.exe.manifest
============================================================
-->
<Target
Name="GenerateApplicationManifest"
DependsOnTargets="
_DeploymentSetClickOnceVersions;
_DeploymentGenerateLauncher;
_DeploymentComputeNativeManifestInfo;
_DeploymentComputeClickOnceManifestInfo;
ResolveComReferences;
ResolveNativeReferences;
_GenerateResolvedDeploymentManifestEntryPoint"
Inputs="
$(MSBuildAllProjects);
@(AppConfigWithTargetPath);
$(_DeploymentBaseManifest);
@(ResolvedIsolatedComModules);
@(_DeploymentManifestDependencies);
@(_DeploymentResolvedManifestEntryPoint);
@(_DeploymentManifestFiles)"
Outputs="@(ApplicationManifest)">
<RequiresFramework35SP1Assembly
ReferencedAssemblies="@(Reference)"
ErrorReportUrl="$(_DeploymentFormattedErrorReportUrl)"
TargetFrameworkVersion="$(TargetFrameworkVersion)"
CreateDesktopShortcut="$(CreateDesktopShortcut)"
SigningManifests="$(SignManifests)"
Assemblies="@(_DeploymentManifestDependencies)"
DeploymentManifestEntryPoint="@(_DeploymentResolvedDeploymentManifestEntryPoint)"
EntryPoint="@(_DeploymentResolvedManifestEntryPoint)"
Files="@(_DeploymentManifestFiles)"
SuiteName="$(SuiteName)" >
<Output TaskParameter="RequiresMinimumFramework35SP1" PropertyName="_DeploymentRequiresMinimumFramework35SP1" />
</RequiresFramework35SP1Assembly>
<GenerateApplicationManifest
AssemblyName="$(_DeploymentApplicationManifestIdentity)"
AssemblyVersion="$(_DeploymentManifestVersion)"
ConfigFile="@(AppConfigWithTargetPath)"
ClrVersion="$(ClrVersion)"
Dependencies="@(_DeploymentManifestDependencies)"
Description="$(Description)"
EntryPoint="@(_DeploymentResolvedManifestEntryPoint)"
ErrorReportUrl="$(_DeploymentFormattedErrorReportUrl)"
FileAssociations="@(FileAssociation)"
Files="@(_DeploymentManifestFiles)"
HostInBrowser="$(HostInBrowser)"
IconFile="@(_DeploymentManifestIconFile)"
InputManifest="$(_DeploymentBaseManifest)"
IsolatedComReferences="@(ResolvedIsolatedComModules)"
LauncherBasedDeployment="$(_DeploymentLauncherBased)"
ManifestType="$(_DeploymentManifestType)"
MaxTargetPath="$(MaxTargetPath)"
OutputManifest="@(ApplicationManifest)"
OSVersion="$(OSVersion)"
Platform="$(_DeploymentPlatformTarget)"
Product="$(ProductName)"
Publisher="$(PublisherName)"
RequiresMinimumFramework35SP1="$(_DeploymentRequiresMinimumFramework35SP1)"
SuiteName="$(SuiteName)"
SupportUrl="$(_DeploymentFormattedSupportUrl)"
TargetCulture="$(TargetCulture)"
TargetFrameworkSubset="$(TargetFrameworkSubset)"
TargetFrameworkProfile="$(TargetFrameworkProfile)"
TargetFrameworkVersion="$(_DeploymentManifestTargetFrameworkVersion)"
TrustInfoFile="@(_DeploymentIntermediateTrustInfoFile)"
UseApplicationTrust="$(UseApplicationTrust)">
<Output TaskParameter="OutputManifest" ItemName="FileWrites"/>
</GenerateApplicationManifest>
<PropertyGroup>
<_DeploymentCopyApplicationManifest>true</_DeploymentCopyApplicationManifest>
</PropertyGroup>
</Target>
<!--
============================================================
_DeploymentSetClickOnceVersions
Sets ClickOnce versions
============================================================
-->
<Target
Name="_DeploymentSetClickOnceVersions"
Condition="'$(GenerateClickOnceManifests)'=='true'">
<PropertyGroup>
<_DeploymentManifestTargetFrameworkMoniker>$(TargetFrameworkMoniker)</_DeploymentManifestTargetFrameworkMoniker>
<_DeploymentManifestTargetFrameworkVersion>$(TargetFrameworkVersion)</_DeploymentManifestTargetFrameworkVersion>
</PropertyGroup>
</Target>
<!--
============================================================
_DeploymentGenerateLauncher
Generates Launcher if needed
============================================================
-->
<Target
Name="_DeploymentGenerateLauncher"
Condition="'$(GenerateClickOnceManifests)'=='true' and '$(_DeploymentLauncherBased)' == 'true'">
<!--
If apphost based built EXE is found, use that as the Launcher.exe's entry point otherwise
use the built DLL as the entry point
-->
<ItemGroup Condition="'$(UseAppHost)' == 'true' and '$(_IsExecutable)' == 'true' and exists('$(AppHostIntermediatePath)')">
<EntryPointForLauncher Include="$(AppHostIntermediatePath)" TargetPath="$(AssemblyName).exe"/>
<ContentWithTargetPath Include="@(EntryPointForLauncher)"/>
</ItemGroup>
<ItemGroup Condition="'$(EntryPointForLauncher)'==''">
<EntryPointForLauncher Include="$(_DeploymentManifestEntryPoint)"/>
</ItemGroup>
<!-- Generates Launcher and obtains its Framework version and moniker -->
<GenerateLauncher
AssemblyName="$(_DeploymentApplicationManifestIdentity)"
EntryPoint="@(EntryPointForLauncher)"
OutputPath="$(IntermediateOutputPath)"
VisualStudioVersion="$(VisualStudioVersion)">
<Output TaskParameter="OutputEntryPoint" ItemName="_DeploymentManifestLauncherEntryPoint"/>
</GenerateLauncher>
<!--
.NET Core ClickOnce deployments use Launcher, which targets .NET FX 4.5 as the minimum
supported ClickOnce runtime version on target user's machine.
TargetFramework Verion and Moniker properties are used in Deployment manifest generation
task to set compatibleFrameworks element, which needs to match Launcher's target version.
Version can be overriden with DeploymentManifestTargetFrameworkVersionOverride property.
-->
<PropertyGroup>
<_DeploymentManifestTargetFrameworkVersion Condition="'$(DeploymentManifestTargetFrameworkVersionOverride)' == ''">v4.5</_DeploymentManifestTargetFrameworkVersion>
<_DeploymentManifestTargetFrameworkVersion Condition="'$(DeploymentManifestTargetFrameworkVersionOverride)' != ''">$(DeploymentManifestTargetFrameworkVersionOverride)</_DeploymentManifestTargetFrameworkVersion>
<_DeploymentManifestTargetFrameworkMoniker>.NETFramework,Version=$(_DeploymentManifestTargetFrameworkVersion)</_DeploymentManifestTargetFrameworkMoniker>
</PropertyGroup>
<!-- Sign Launcher EXE -->
<SignFile
CertificateThumbprint="$(_DeploymentResolvedManifestCertificateThumbprint)"
TimestampUrl="$(ManifestTimestampUrl)"
SigningTarget="@(_DeploymentManifestLauncherEntryPoint)"
TargetFrameworkVersion="$(TargetFrameworkVersion)"
TargetFrameworkIdentifier="$(TargetFrameworkIdentifier)"
Condition="'$(_DeploymentSignClickOnceManifests)'=='true'" />
<!-- Sign the original ClickOnce entrypoint -->
<SignFile
CertificateThumbprint="$(_DeploymentResolvedManifestCertificateThumbprint)"
TimestampUrl="$(ManifestTimestampUrl)"
SigningTarget="@(_DeploymentManifestEntryPoint)"
TargetFrameworkVersion="$(TargetFrameworkVersion)"
TargetFrameworkIdentifier="$(TargetFrameworkIdentifier)"
Condition="'$(_DeploymentSignClickOnceManifests)'=='true'" />
<!-- Sign apphost.exe if it's the entrypoint for the Launcher.exe. This is the case in loose file publish -->
<SignFile
CertificateThumbprint="$(_DeploymentResolvedManifestCertificateThumbprint)"
TimestampUrl="$(ManifestTimestampUrl)"
SigningTarget="$(AppHostIntermediatePath)"
TargetFrameworkVersion="$(TargetFrameworkVersion)"
TargetFrameworkIdentifier="$(TargetFrameworkIdentifier)"
Condition="'$(_DeploymentSignClickOnceManifests)'=='true' and '$(UseAppHost)' == 'true' and '$(PublishSingleFile)' != 'true' and '$(_IsExecutable)' == 'true' and exists('$(AppHostIntermediatePath)')" />
<!--
Replace entry-point with Launcher and move original project's entry-point to content group.
-->
<ItemGroup>
<ContentWithTargetPath Include="@(_DeploymentManifestEntryPoint)"/>
<_DeploymentManifestEntryPoint Remove="@(_DeploymentManifestEntryPoint)"/>
<_DeploymentManifestEntryPoint Include="@(_DeploymentManifestLauncherEntryPoint)"/>
</ItemGroup>
</Target>
<!--
============================================================
_DeploymentComputeNativeManifestInfo
Compute info for native manifest generation
============================================================
-->
<Target
Name="_DeploymentComputeNativeManifestInfo"
Condition="'$(GenerateClickOnceManifests)'!='true'">
<!-- Create list of items for manifest generation -->
<ResolveManifestFiles NativeAssemblies="@(NativeReferenceFile);@(_DeploymentNativePrerequisite)">
<Output TaskParameter="OutputAssemblies" ItemName="_DeploymentManifestDependencies"/>
</ResolveManifestFiles>
<PropertyGroup>
<_DeploymentManifestType>Native</_DeploymentManifestType>
</PropertyGroup>
<!-- Obtain manifest version from the built assembly -->
<GetAssemblyIdentity AssemblyFiles="@(IntermediateAssembly)">
<Output TaskParameter="Assemblies" ItemName="_IntermediateAssemblyIdentity"/>
</GetAssemblyIdentity>
<PropertyGroup>
<_DeploymentManifestVersion>@(_IntermediateAssemblyIdentity->'%(Version)')</_DeploymentManifestVersion>
</PropertyGroup>
</Target>
<!--
============================================================
_DeploymentComputeClickOnceManifestInfo
Compute info for ClickOnce manifest generation
============================================================
-->
<Target
Name="_DeploymentComputeClickOnceManifestInfo"
Condition="'$(GenerateClickOnceManifests)'=='true'"
DependsOnTargets="$(DeploymentComputeClickOnceManifestInfoDependsOn)">
<!-- Grab just the serialization assemblies for a referenced assembly. There may also be a symbols file in ReferenceRelatedPaths -->
<ItemGroup>
<_SGenDllsRelatedToCurrentDll Include="@(_ReferenceSerializationAssemblyPaths->'%(FullPath)')" Condition="'%(Extension)' == '.dll'"/>
<_SGenDllsRelatedToCurrentDll Include="@(SerializationAssembly->'%(FullPath)')" Condition="'%(Extension)' == '.dll'"/>
</ItemGroup>
<ItemGroup Condition="!exists('$(ProjectLockFile)')">
<_CopyLocalFalseRefPaths Include="@(ReferencePath)" Condition="'%(CopyLocal)' == 'false'" />
<_CopyLocalFalseRefPathsWithExclusion Include="@(_CopyLocalFalseRefPaths)"
Exclude="@(ReferenceCopyLocalPaths);@(_NETStandardLibraryNETFrameworkLib)" />
</ItemGroup>
<ItemGroup Condition="'$(PublishSingleFile)' != 'true'">
<_ClickOnceSatelliteAssemblies Include="@(IntermediateSatelliteAssembliesWithTargetPath);@(ReferenceSatellitePaths)" />
</ItemGroup>
<!-- Flag primary dependencies-certain warnings emitted during application manifest generation apply only to them. -->
<ItemGroup>
<_DeploymentReferencePaths Include="@(ReferenceCopyLocalPaths)"
Condition="('%(Extension)' == '.dll' Or '%(Extension)' == '.exe' Or '%(Extension)' == '.md') and ('%(ReferenceCopyLocalPaths.CopyToPublishDirectory)' != 'false')">
<IsPrimary>true</IsPrimary>
</_DeploymentReferencePaths>
<_DeploymentReferencePaths Include="@(_CopyLocalFalseRefPathsWithExclusion)" />
</ItemGroup>
<!-- Include managed references in clickonce manifest only if single file publish is false -->
<ItemGroup Condition="'$(PublishSingleFile)' != 'true'">
<_ManifestManagedReferences Include="@(_DeploymentReferencePaths);@(ReferenceDependencyPaths);@(_SGenDllsRelatedToCurrentDll);@(SerializationAssembly);@(ReferenceCOMWrappersToCopyLocal)"
Exclude="@(_ClickOnceSatelliteAssemblies);@(_ReferenceScatterPaths);@(_ExcludedAssembliesFromManifestGeneration)" />
</ItemGroup>
<!-- Include the following files in clickonce manifest only if single file publish is false -->
<ItemGroup Condition="'$(PublishSingleFile)' != 'true'">
<!--
_ClickOnceRuntimeCopyLocalItems group contains any runtimes folder assets of Nuget packages that are not included in
_DeploymentReferencePaths (e.g. pdbs). They are populated from the RuntimeTargetsCopyLocalItems and NativeCopyLocalItems
group that contain the RID-specific assets that go in runtimes folder on publish. They are output groups of the
ResolvePackageAssets target in dotnet/sdk
-->
<_ClickOnceRuntimeCopyLocalItems Include="@(RuntimeTargetsCopyLocalItems)"
Condition="'%(RuntimeTargetsCopyLocalItems.CopyLocal)' == 'true'" />
<_ClickOnceRuntimeCopyLocalItems Include="@(NativeCopyLocalItems)"
Condition="'%(NativeCopyLocalItems.CopyLocal)' == 'true'" />
<_ClickOnceRuntimeCopyLocalItems Remove="@(_DeploymentReferencePaths)" />
<!--
For .NET>=5, we need to check if we need to publish any content items from transitive project references. For such items to be published, they
either have the .exe/.dll extension or their publish status has been overriden in VS so they will show up in the PublishFiles collection.
The PublishProtocol property is available only in .NET>=5 so we will used that to exclude .NET FX 4.X case.
-->
<_ClickOnceTransitiveContentItemsTemp Include="@(_TransitiveItemsToCopyToOutputDirectory->WithoutMetadataValue('CopyToPublishDirectory', 'Never')->'%(TargetPath)')" Condition="'$(PublishProtocol)' == 'ClickOnce'" >
<SavedIdentity>%(Identity)</SavedIdentity>
</_ClickOnceTransitiveContentItemsTemp>
<_ClickOnceTransitiveContentItems Include="@(_ClickOnceTransitiveContentItemsTemp->'%(SavedIdentity)')" Condition="'%(Identity)'=='@(PublishFile)' Or '%(Extension)'=='.exe' Or '%(Extension)'=='.dll'" />
<!--
ClickOnce content items is union of transitive content items and content items from this project.
We also exclude content items from this project that have set CopyToPublishDirectory to Never.
-->
<_ClickOnceContentItems Include="@(ContentWithTargetPath->WithoutMetadataValue('CopyToPublishDirectory', 'Never'))" />
<_ClickOnceContentItems Include="@(_ClickOnceTransitiveContentItems)" />
<!--
For .NET>=5, we need to check if we need to publish any copylocal items from None group. For such items to be published, they either
have .exe/.dll extension or their publish status has been overriden in VS so they will show up in the PublishFiles collection.
The PublishProtocol property is available only in .NET>=5 so we will used that to exclude .NET FX 4.X case.
-->
<!-- Include items from None group for publishing -->
<_ClickOnceNoneItemsTemp Include="@(_NoneWithTargetPath->WithoutMetadataValue('CopyToPublishDirectory', 'Never')->'%(TargetPath)')" Condition="'$(PublishProtocol)'=='Clickonce' And ('%(_NoneWithTargetPath.CopyToOutputDirectory)'=='Always' or '%(_NoneWithTargetPath.CopyToOutputDirectory)'=='PreserveNewest')">
<SavedIdentity>%(Identity)</SavedIdentity>
</_ClickOnceNoneItemsTemp>
<_ClickOnceNoneItems Include="@(_ClickOnceNoneItemsTemp->'%(SavedIdentity)')" Condition="'%(Identity)'=='@(PublishFile)' Or '%(Extension)'=='.exe' Or '%(Extension)'=='.dll'" />
<_ClickOnceFiles Include="@(_ClickOnceContentItems);@(_DeploymentManifestIconFile);@(AppConfigWithTargetPath);@(NetCoreRuntimeJsonFilesForClickOnce);@(_ClickOnceRuntimeCopyLocalItems);@(_ClickOnceNoneItems)" />
<!-- clear temporary item groups to free memory -->
<_ClickOnceNoneItemsTemp Remove="@(_ClickOnceNoneItemsTemp)"/>
<_ClickOnceNoneItems Remove="@(_ClickOnceNoneItems)"/>
<_ClickOnceTransitiveContentItemsTemp Remove="@(_ClickOnceTransitiveContentItemsTemp)"/>
<_ClickOnceTransitiveContentItems Remove="@(_ClickOnceTransitiveContentItems)"/>
<_ClickOnceContentItems Remove="@(_ClickOnceContentItems)"/>
<_ClickOnceRuntimeCopyLocalItems Remove="@(_ClickOnceRuntimeCopyLocalItems)"/>
</ItemGroup>
<!-- For single file publish, we need to include the SF bundle EXE, application icon file and files excluded from the bundle EXE in the clickonce manifest -->
<ItemGroup Condition="'$(PublishSingleFile)' == 'true'">
<_ClickOnceFiles Include="$(PublishedSingleFilePath);@(_DeploymentManifestIconFile)"/>
<_ClickOnceFiles Include="@(_FilesExcludedFromBundle)"/>
<!-- Include file association icons from Content as loose files -->
<_FileAssociationIcons Include="%(FileAssociation.DefaultIcon)"/>
<_ClickOnceFiles Include="@(ContentWithTargetPath)" Condition="'%(Identity)'=='@(_FileAssociationIcons)'"/>
</ItemGroup>
<!-- For single file publish in .net core app, sign the SF EXE if signing is enabled -->
<SignFile
CertificateThumbprint="$(_DeploymentResolvedManifestCertificateThumbprint)"
TimestampUrl="$(ManifestTimestampUrl)"
SigningTarget="$(PublishedSingleFilePath)"
TargetFrameworkVersion="$(TargetFrameworkVersion)"
TargetFrameworkIdentifier="$(TargetFrameworkIdentifier)"
Condition="'$(_DeploymentSignClickOnceManifests)'=='true' and '$(_DeploymentLauncherBased)' == 'true' and '$(PublishSingleFile)' == 'true'"
/>
<!--
If ReadyToRun is enabled in loose files scenario, we need to remove entries of the IL images that have gone through R2R
compiler and replace them with the entries for their R2R images. The R2R application image also needs to be signed if necessary.
-->
<ItemGroup Condition="'$(PublishReadyToRun)' == 'true' and '$(PublishSingleFile)' != 'true'">
<_ManifestManagedReferences Remove="@(_ReadyToRunCompileList)" />
<_ClickOnceFiles Remove="@(_ReadyToRunCompileList)" />
<_ClickOnceFiles Include="@(_ReadyToRunFilesToPublish)" />
<_ClickOnceTargetFile Include="@(_ReadyToRunFilesToPublish)" Condition="'%(Filename)%(Extension)' == '$(TargetFileName)'" />
</ItemGroup>
<!-- Sign application image created by R2R -->
<SignFile
CertificateThumbprint="$(_DeploymentResolvedManifestCertificateThumbprint)"
TimestampUrl="$(ManifestTimestampUrl)"
SigningTarget="@(_ClickOnceTargetFile)"
TargetFrameworkVersion="$(TargetFrameworkVersion)"
TargetFrameworkIdentifier="$(TargetFrameworkIdentifier)"
Condition="'$(_DeploymentSignClickOnceManifests)' == 'true' and '$(PublishReadyToRun)' == 'true' and '$(PublishSingleFile)' != 'true'" />
<!-- Copy the application executable from Obj folder to app.publish folder.
This is being done to avoid Windows Forms designer memory issues that can arise while operating directly on files located in Obj directory. -->
<Copy
SourceFiles="@(_DeploymentManifestEntryPoint)"
DestinationFolder="$(ClickOncePublishDir)">
<Output TaskParameter="DestinationFiles" ItemName="_DeploymentClickOnceApplicationExecutable" />
</Copy>
<!-- Sign the application executable located in app.publish folder. Signing this file is done to comply with SmartScreen. -->
<SignFile
CertificateThumbprint="$(_DeploymentResolvedManifestCertificateThumbprint)"
TimestampUrl="$(ManifestTimestampUrl)"
SigningTarget="@(_DeploymentClickOnceApplicationExecutable)"
Condition="'$(_DeploymentResolvedManifestCertificateThumbprint)'!='' and '$(_DeploymentSignClickOnceManifests)'=='true' and '$(TargetExt)' == '.exe'"
/>
<!-- Create list of items for manifest generation -->
<ResolveManifestFiles
AssemblyName="$(_DeploymentApplicationManifestIdentity)"
EntryPoint="@(_DeploymentClickOnceApplicationExecutable)"
ExtraFiles="@(_DebugSymbolsIntermediatePath);$(IntermediateOutputPath)$(TargetName).xml;@(_ReferenceRelatedPaths)"
Files="@(_ClickOnceFiles)"
IsSelfContainedPublish="$(SelfContained)"
IsSingleFilePublish="$(PublishSingleFile)"
LauncherBasedDeployment="$(_DeploymentLauncherBased)"
ManagedAssemblies="@(_ManifestManagedReferences)"
NativeAssemblies="@(NativeReferenceFile);@(_DeploymentNativePrerequisite)"
PublishFiles="@(PublishFile)"
RuntimePackAssets="@(RuntimePackAsset)"
SatelliteAssemblies="@(_ClickOnceSatelliteAssemblies)"
SigningManifests="$(SignManifests)"
TargetCulture="$(TargetCulture)"
TargetFrameworkIdentifier="$(TargetFrameworkIdentifier)"
TargetFrameworkVersion="$(TargetFrameworkVersion)">
<Output TaskParameter="OutputAssemblies" ItemName="_DeploymentManifestDependenciesUnfiltered"/>
<Output TaskParameter="OutputFiles" ItemName="_DeploymentManifestFiles"/>
<Output TaskParameter="OutputEntryPoint" ItemName="_DeploymentResolvedManifestEntryPoint"/>
</ResolveManifestFiles>
<!-- We have to filter items out of the dependencies that have neither CopyLocal set to true, -->
<!-- nor the dependency type manually set to 'Install'. -->
<ItemGroup>
<_DeploymentManifestDependencies Include="@(_DeploymentManifestDependenciesUnfiltered)"
Condition="!('%(_DeploymentManifestDependenciesUnfiltered.CopyLocal)' == 'false' And '%(_DeploymentManifestDependenciesUnfiltered.DependencyType)' != 'Install')" />
</ItemGroup>
<PropertyGroup>
<_DeploymentManifestType>ClickOnce</_DeploymentManifestType>
</PropertyGroup>
<!--
Manifest platform should always be MSIL for Launcher-based deployments, as the Launcher is MSIL.
Do not set _DeploymentPlatformTarget property in Launcher case - this is interpreted as MSIL,
by GenerateApplicationManifest and GenerateDeploymentManifest tasks.
Otherwise, set it to PlatformTarget.
-->
<PropertyGroup>
<_DeploymentPlatformTarget Condition="'$(_DeploymentLauncherBased)' != 'true'">$(PlatformTarget)</_DeploymentPlatformTarget>
</PropertyGroup>
<!-- Obtain manifest version from ApplicationVersion and ApplicationRevision properties -->
<FormatVersion Version="$(ApplicationVersion)" Revision="$(ApplicationRevision)">
<Output TaskParameter="OutputVersion" PropertyName="_DeploymentManifestVersion"/>
</FormatVersion>
<FormatUrl InputUrl="$(_DeploymentUrl)">
<Output TaskParameter="OutputUrl" PropertyName="_DeploymentFormattedDeploymentUrl"/>
</FormatUrl>
<FormatUrl InputUrl="$(SupportUrl)">
<Output TaskParameter="OutputUrl" PropertyName="_DeploymentFormattedSupportUrl"/>
</FormatUrl>
<FormatUrl InputUrl="$(ErrorReportUrl)">
<Output TaskParameter="OutputUrl" PropertyName="_DeploymentFormattedErrorReportUrl"/>
</FormatUrl>
</Target>
<!--
============================================================
_DeploymentGenerateTrustInfo
Generates the application permission set for inclusion in the generated ClickOnce application manifest.
============================================================
-->
<Target
Name="_DeploymentGenerateTrustInfo"
Condition="'$(TargetZone)'!=''"
Inputs="
$(MSBuildAllProjects);
$(_DeploymentBaseManifest);
"
Outputs="@(_DeploymentIntermediateTrustInfoFile)">
<GenerateTrustInfo
BaseManifest="$(_DeploymentBaseManifest)"
ApplicationDependencies="@(ReferencePath);@(ReferenceDependencyPaths)"
ExcludedPermissions="$(ExcludedPermissions)"
TargetFrameworkMoniker="$(TargetFrameworkMoniker)"
TargetZone="$(TargetZone)"
TrustInfoFile="@(_DeploymentIntermediateTrustInfoFile)">
<Output TaskParameter="TrustInfoFile" ItemName="FileWrites"/>
</GenerateTrustInfo>
</Target>
<!--
============================================================
GenerateDeploymentManifest
Generates a ClickOnce deployment manifest.
An deployment manifest specifies declarative application identity and application update information.
============================================================
-->
<Target
Name="GenerateDeploymentManifest"
DependsOnTargets="GenerateApplicationManifest"
Inputs="
$(MSBuildAllProjects);
@(ApplicationManifest)
"
Outputs="@(DeployManifest)">
<GenerateDeploymentManifest
AssemblyName="$(_DeploymentDeployManifestIdentity)"
AssemblyVersion="$(_DeploymentManifestVersion)"
CreateDesktopShortcut="$(CreateDesktopShortcut)"
DeploymentUrl="$(_DeploymentFormattedDeploymentUrl)"
Description="$(Description)"
DisallowUrlActivation="$(DisallowUrlActivation)"
EntryPoint="@(_DeploymentResolvedDeploymentManifestEntryPoint)"
ErrorReportUrl="$(_DeploymentFormattedErrorReportUrl)"
Install="$(Install)"
LauncherBasedDeployment="$(_DeploymentLauncherBased)"
MapFileExtensions="$(MapFileExtensions)"
MaxTargetPath="$(MaxTargetPath)"
MinimumRequiredVersion="$(_DeploymentBuiltMinimumRequiredVersion)"
OutputManifest="@(DeployManifest)"
Platform="$(_DeploymentPlatformTarget)"
Product="$(ProductName)"
Publisher="$(PublisherName)"
SuiteName="$(SuiteName)"
SupportUrl="$(_DeploymentFormattedSupportUrl)"
TargetCulture="$(TargetCulture)"
TargetFrameworkVersion="$(_DeploymentManifestTargetFrameworkVersion)"
TargetFrameworkMoniker="$(_DeploymentManifestTargetFrameworkMoniker)"
TrustUrlParameters="$(TrustUrlParameters)"
UpdateEnabled="$(UpdateEnabled)"
UpdateInterval="$(_DeploymentBuiltUpdateInterval)"
UpdateMode="$(UpdateMode)"
UpdateUnit="$(_DeploymentBuiltUpdateIntervalUnits)"
Condition="'$(GenerateClickOnceManifests)'=='true'">
<Output TaskParameter="OutputManifest" ItemName="FileWrites"/>
</GenerateDeploymentManifest>
</Target>
<!--
***********************************************************************************************
***********************************************************************************************
PrepareForRun Section
***********************************************************************************************
***********************************************************************************************
-->
<PropertyGroup>
<SkipCopyUnchangedFiles Condition="'$(SkipCopyUnchangedFiles)' == ''">true</SkipCopyUnchangedFiles>
<UseCommonOutputDirectory Condition="'$(UseCommonOutputDirectory)' == ''">false</UseCommonOutputDirectory>
</PropertyGroup>
<!--
============================================================
PrepareForRun
Copy the build outputs to the final directory if they have changed.
============================================================
-->
<PropertyGroup>
<PrepareForRunDependsOn>
CopyFilesToOutputDirectory
</PrepareForRunDependsOn>
</PropertyGroup>
<Target
Name="PrepareForRun"
DependsOnTargets="$(PrepareForRunDependsOn)"/>
<!--
============================================================
CopyFilesToOutputDirectory
Copy all build outputs, satellites and other necessary files to the final directory.
============================================================
-->
<PropertyGroup>
<!-- By default we're not using Hard or Symbolic Links to copy to the output directory, and never when building in VS -->
<CreateHardLinksForCopyAdditionalFilesIfPossible Condition="'$(BuildingInsideVisualStudio)' == 'true' or '$(CreateHardLinksForCopyAdditionalFilesIfPossible)' == ''">false</CreateHardLinksForCopyAdditionalFilesIfPossible>
<CreateSymbolicLinksForCopyAdditionalFilesIfPossible Condition="'$(BuildingInsideVisualStudio)' == 'true' or '$(CreateSymbolicLinksForCopyAdditionalFilesIfPossible)' == ''">false</CreateSymbolicLinksForCopyAdditionalFilesIfPossible>
</PropertyGroup>
<Target
Name="CopyFilesToOutputDirectory"
DependsOnTargets="
ComputeIntermediateSatelliteAssemblies;
_CopyFilesMarkedCopyLocal;
_CopySourceItemsToOutputDirectory;
_CopyAppConfigFile;
_CopyManifestFiles;
_CheckForCompileOutputs;
_SGenCheckForOutputs">
<PropertyGroup>
<!-- By default we're not using Hard Links to copy to the output directory, and never when building in VS -->
<CreateHardLinksForCopyFilesToOutputDirectoryIfPossible Condition="'$(BuildingInsideVisualStudio)' == 'true' or '$(CreateHardLinksForCopyFilesToOutputDirectoryIfPossible)' == ''">false</CreateHardLinksForCopyFilesToOutputDirectoryIfPossible>
<CreateSymbolicLinksForCopyFilesToOutputDirectoryIfPossible Condition="'$(BuildingInsideVisualStudio)' == 'true' or '$(CreateSymbolicLinksForCopyFilesToOutputDirectoryIfPossible)' == ''">false</CreateSymbolicLinksForCopyFilesToOutputDirectoryIfPossible>
<ErrorIfLinkFailsForCopyFilesToOutputDirectory Condition="'$(BuildingInsideVisualStudio)' == 'true' or '$(ErrorIfLinkFailsForCopyFilesToOutputDirectory)' == ''">false</ErrorIfLinkFailsForCopyFilesToOutputDirectory>
</PropertyGroup>
<PropertyGroup>
<CopyBuildOutputToOutputDirectory Condition="'$(CopyBuildOutputToOutputDirectory)'==''">true</CopyBuildOutputToOutputDirectory>
<CopyOutputSymbolsToOutputDirectory Condition="'$(CopyOutputSymbolsToOutputDirectory)'==''">true</CopyOutputSymbolsToOutputDirectory>
<CopyDocumentationFileToOutputDirectory Condition="'$(CopyDocumentationFileToOutputDirectory)'==''">true</CopyDocumentationFileToOutputDirectory>
</PropertyGroup>
<!-- Copy the build product (.dll or .exe). -->
<Copy
SourceFiles="@(IntermediateAssembly)"
DestinationFolder="$(OutDir)"
SkipUnchangedFiles="$(SkipCopyUnchangedFiles)"
OverwriteReadOnlyFiles="$(OverwriteReadOnlyFiles)"
Retries="$(CopyRetryCount)"
RetryDelayMilliseconds="$(CopyRetryDelayMilliseconds)"
UseHardlinksIfPossible="$(CreateHardLinksForCopyFilesToOutputDirectoryIfPossible)"
UseSymboliclinksIfPossible="$(CreateSymbolicLinksForCopyFilesToOutputDirectoryIfPossible)"
ErrorIfLinkFails="$(ErrorIfLinkFailsForCopyFilesToOutputDirectory)"
Condition="'$(CopyBuildOutputToOutputDirectory)' == 'true' and '$(SkipCopyBuildProduct)' != 'true'"
>
<Output TaskParameter="DestinationFiles" ItemName="MainAssembly"/>
<Output TaskParameter="DestinationFiles" ItemName="FileWrites"/>
</Copy>
<!-- Copy the reference assembly build product (.dll or .exe). -->
<CopyRefAssembly
SourcePath="@(IntermediateRefAssembly)"
DestinationPath="$(TargetRefPath)"
Condition="'$(ProduceReferenceAssembly)' == 'true' and '$(CopyBuildOutputToOutputDirectory)' == 'true' and '$(SkipCopyBuildProduct)' != 'true'"
>
<Output TaskParameter="DestinationPath" ItemName="ReferenceAssembly"/>
<Output TaskParameter="DestinationPath" ItemName="FileWrites"/>
</CopyRefAssembly>
<Message Importance="High" Text="$(MSBuildProjectName) -> @(MainAssembly->'%(FullPath)')" Condition="'$(CopyBuildOutputToOutputDirectory)' == 'true' and '$(SkipCopyBuildProduct)'!='true'" />
<!-- Copy the additional modules. -->
<Copy
SourceFiles="@(AddModules)"
DestinationFolder="$(OutDir)"
SkipUnchangedFiles="$(SkipCopyUnchangedFiles)"
OverwriteReadOnlyFiles="$(OverwriteReadOnlyFiles)"
Retries="$(CopyRetryCount)"
RetryDelayMilliseconds="$(CopyRetryDelayMilliseconds)"
UseHardlinksIfPossible="$(CreateHardLinksForCopyAdditionalFilesIfPossible)"
UseSymboliclinksIfPossible="$(CreateSymbolicLinksForCopyAdditionalFilesIfPossible)"
Condition="'@(AddModules)' != ''"
>
<Output TaskParameter="DestinationFiles" ItemName="FileWrites"/>
</Copy>
<!-- Copy the serialization assembly if it exists. -->
<Copy
SourceFiles="$(IntermediateOutputPath)$(_SGenDllName)"
DestinationFiles="$(OutDir)$(_SGenDllName)"
SkipUnchangedFiles="$(SkipCopyUnchangedFiles)"
OverwriteReadOnlyFiles="$(OverwriteReadOnlyFiles)"
Retries="$(CopyRetryCount)"
RetryDelayMilliseconds="$(CopyRetryDelayMilliseconds)"
UseHardlinksIfPossible="$(CreateHardLinksForCopyFilesToOutputDirectoryIfPossible)"
UseSymboliclinksIfPossible="$(CreateSymbolicLinksForCopyFilesToOutputDirectoryIfPossible)"
ErrorIfLinkFails="$(ErrorIfLinkFailsForCopyFilesToOutputDirectory)"
Condition="'$(_SGenDllCreated)'=='true'">
<Output TaskParameter="DestinationFiles" ItemName="FileWrites"/>
</Copy>
<!-- Copy the debug information file (.pdb), if any -->
<Copy
SourceFiles="@(_DebugSymbolsIntermediatePath)"
DestinationFiles="@(_DebugSymbolsOutputPath)"
SkipUnchangedFiles="$(SkipCopyUnchangedFiles)"
OverwriteReadOnlyFiles="$(OverwriteReadOnlyFiles)"
Retries="$(CopyRetryCount)"
RetryDelayMilliseconds="$(CopyRetryDelayMilliseconds)"
UseHardlinksIfPossible="$(CreateHardLinksForCopyFilesToOutputDirectoryIfPossible)"
UseSymboliclinksIfPossible="$(CreateSymbolicLinksForCopyFilesToOutputDirectoryIfPossible)"
ErrorIfLinkFails="$(ErrorIfLinkFailsForCopyFilesToOutputDirectory)"
Condition="'$(_DebugSymbolsProduced)'=='true' and '$(SkipCopyingSymbolsToOutputDirectory)' != 'true' and '$(CopyOutputSymbolsToOutputDirectory)'=='true'">
<Output TaskParameter="DestinationFiles" ItemName="FileWrites"/>
</Copy>
<!-- Copy the resulting XML documentation file, if any. -->
<Copy
SourceFiles="@(DocFileItem)"
DestinationFiles="@(FinalDocFile)"
SkipUnchangedFiles="$(SkipCopyUnchangedFiles)"
OverwriteReadOnlyFiles="$(OverwriteReadOnlyFiles)"
Retries="$(CopyRetryCount)"
RetryDelayMilliseconds="$(CopyRetryDelayMilliseconds)"
UseHardlinksIfPossible="$(CreateHardLinksForCopyFilesToOutputDirectoryIfPossible)"
UseSymboliclinksIfPossible="$(CreateSymbolicLinksForCopyFilesToOutputDirectoryIfPossible)"
ErrorIfLinkFails="$(ErrorIfLinkFailsForCopyFilesToOutputDirectory)"
Condition="'$(_DocumentationFileProduced)'=='true' and '$(CopyDocumentationFileToOutputDirectory)'=='true'">
<Output TaskParameter="DestinationFiles" ItemName="FileWrites"/>
</Copy>
<!-- Copy satellite assemblies. -->
<Copy
SourceFiles="@(IntermediateSatelliteAssembliesWithTargetPath)"
DestinationFiles="@(IntermediateSatelliteAssembliesWithTargetPath->'$(OutDir)%(Culture)\$(TargetName).resources.dll')"
SkipUnchangedFiles="$(SkipCopyUnchangedFiles)"
OverwriteReadOnlyFiles="$(OverwriteReadOnlyFiles)"
Retries="$(CopyRetryCount)"
RetryDelayMilliseconds="$(CopyRetryDelayMilliseconds)"
UseHardlinksIfPossible="$(CreateHardLinksForCopyFilesToOutputDirectoryIfPossible)"
UseSymboliclinksIfPossible="$(CreateSymbolicLinksForCopyFilesToOutputDirectoryIfPossible)"
ErrorIfLinkFails="$(ErrorIfLinkFailsForCopyFilesToOutputDirectory)"
Condition="'@(IntermediateSatelliteAssembliesWithTargetPath)' != ''"
>
<Output TaskParameter="DestinationFiles" ItemName="FileWrites"/>
</Copy>
<!--
Copy COM reference wrappers, isolated COM references, COM references included by
native (manifest) references, native (manifest) reference files themselves.
-->
<Copy
SourceFiles="@(ReferenceComWrappersToCopyLocal); @(ResolvedIsolatedComModules); @(_DeploymentLooseManifestFile); @(NativeReferenceFile)"
DestinationFolder="$(OutDir)"
SkipUnchangedFiles="$(SkipCopyUnchangedFiles)"
OverwriteReadOnlyFiles="$(OverwriteReadOnlyFiles)"
Retries="$(CopyRetryCount)"
RetryDelayMilliseconds="$(CopyRetryDelayMilliseconds)"
UseHardlinksIfPossible="$(CreateHardLinksForCopyAdditionalFilesIfPossible)"
UseSymboliclinksIfPossible="$(CreateSymbolicLinksForCopyAdditionalFilesIfPossible)"
Condition="'@(ReferenceComWrappersToCopyLocal)' != '' or '@(ResolvedIsolatedComModules)' != '' or '@(_DeploymentLooseManifestFile)' != '' or '@(NativeReferenceFile)' != '' "
>
<Output TaskParameter="DestinationFiles" ItemName="FileWritesShareable"/>
</Copy>
<!-- Copy the build product of WinMDExp. -->
<Copy
SourceFiles="@(WinMDExpArtifacts)"
DestinationFolder="$(OutDir)"
SkipUnchangedFiles="$(SkipCopyUnchangedFiles)"
OverwriteReadOnlyFiles="$(OverwriteReadOnlyFiles)"
Retries="$(CopyRetryCount)"
RetryDelayMilliseconds="$(CopyRetryDelayMilliseconds)"
UseHardlinksIfPossible="$(CreateHardLinksForCopyFilesToOutputDirectoryIfPossible)"
UseSymboliclinksIfPossible="$(CreateSymbolicLinksForCopyFilesToOutputDirectoryIfPossible)"
ErrorIfLinkFails="$(ErrorIfLinkFailsForCopyFilesToOutputDirectory)"
Condition="'$(SkipCopyWinMDArtifact)' != 'true' and '@(WinMDExpArtifacts)' != ''"
>
<Output TaskParameter="DestinationFiles" ItemName="FileWrites"/>
<Output TaskParameter="DestinationFiles" ItemName="FinalWinmdExpArtifacts" />
</Copy>
<Message Importance="High" Text="$(MSBuildProjectName) -> $([System.IO.Path]::GetFullPath('$(_WindowsMetadataOutputPath)'))" Condition="'$(SkipCopyWinMDArtifact)' != 'true' and '$(_WindowsMetadataOutputPath)' != ''" />
</Target>
<!--
============================================================
_CopyFilesMarkedCopyLocal
Copy references that are marked as "CopyLocal" and their dependencies, including .pdbs, .xmls and satellites.
============================================================
-->
<Target
Name="_CopyFilesMarkedCopyLocal"
Condition="'@(ReferenceCopyLocalPaths)' != ''"
>
<PropertyGroup>
<!-- By default we're not using Hard Links to copy to the output directory, and never when building in VS -->
<CreateHardLinksForCopyLocalIfPossible Condition="'$(BuildingInsideVisualStudio)' == 'true' or '$(CreateHardLinksForCopyLocalIfPossible)' == ''">false</CreateHardLinksForCopyLocalIfPossible>
<CreateSymbolicLinksForCopyLocalIfPossible Condition="'$(BuildingInsideVisualStudio)' == 'true' or '$(CreateSymbolicLinksForCopyLocalIfPossible)' == ''">false</CreateSymbolicLinksForCopyLocalIfPossible>
</PropertyGroup>
<Copy
SourceFiles="@(ReferenceCopyLocalPaths)"
DestinationFiles="@(ReferenceCopyLocalPaths->'$(OutDir)%(DestinationSubDirectory)%(Filename)%(Extension)')"
SkipUnchangedFiles="$(SkipCopyUnchangedFiles)"
OverwriteReadOnlyFiles="$(OverwriteReadOnlyFiles)"
Retries="$(CopyRetryCount)"
RetryDelayMilliseconds="$(CopyRetryDelayMilliseconds)"
UseHardlinksIfPossible="$(CreateHardLinksForCopyLocalIfPossible)"
UseSymboliclinksIfPossible="$(CreateSymbolicLinksForCopyLocalIfPossible)"
Condition="'$(UseCommonOutputDirectory)' != 'true'"
>
<Output TaskParameter="DestinationFiles" ItemName="FileWritesShareable"/>
<Output TaskParameter="CopiedFiles" ItemName="ReferencesCopiedInThisBuild"/>
<Output TaskParameter="WroteAtLeastOneFile" PropertyName="WroteAtLeastOneFile"/>
</Copy>
<!-- If this project produces reference assemblies *and* copied (possibly transitive)
references on this build, subsequent builds of projects that depend on it must
not be considered up to date, so touch this marker file that is considered an
input to projects that reference this one. -->
<Touch Files="@(CopyUpToDateMarker)"
AlwaysCreate="true"
Condition="'@(ReferencesCopiedInThisBuild)' != '' and '$(WroteAtLeastOneFile)' == 'true'" />
<ItemGroup>
<FileWrites Include="@(CopyUpToDateMarker)" />
</ItemGroup>
</Target>
<!--
============================================================
_CopySourceItemsToOutputDirectory
============================================================
-->
<Target
Name="_CopySourceItemsToOutputDirectory"
DependsOnTargets="
GetCopyToOutputDirectoryItems;
_CopyOutOfDateSourceItemsToOutputDirectory;
_CopyOutOfDateSourceItemsToOutputDirectoryAlways"/>
<!--
============================================================
GetCopyToOutputDirectoryItems
Get all project items that may need to be transferred to the output directory.
This includes baggage items from transitively referenced projects.
As of 17.0, content items are copied transitively by default.
Set `MSBuildCopyContentTransitively` to false to opt out.
See https://github.com/dotnet/msbuild/pull/6622 for more info.
============================================================
-->
<PropertyGroup>
<_TargetsThatPrepareProjectReferences>_SplitProjectReferencesByFileExistence</_TargetsThatPrepareProjectReferences>
<!--
GetCopyToOutputDirectoryItems depends on an unspecified dependency _SplitProjectReferencesByFileExistence -> AssignProjectConfiguration (https://github.com/dotnet/msbuild/issues/4677).
When the unspecified dependency does not happen by accident, content copying is only 1 level deep instead of transitive.
This target enforces the dependency.
-->
<MSBuildCopyContentTransitively Condition=" '$(MSBuildCopyContentTransitively)' == ''">true</MSBuildCopyContentTransitively>
<_TargetsThatPrepareProjectReferences Condition=" '$(MSBuildCopyContentTransitively)' == 'true' ">
AssignProjectConfiguration;
_SplitProjectReferencesByFileExistence
</_TargetsThatPrepareProjectReferences>
<GetCopyToOutputDirectoryItemsDependsOn>
AssignTargetPaths;
$(_TargetsThatPrepareProjectReferences);
_GetProjectReferenceTargetFrameworkProperties;
_PopulateCommonStateForGetCopyToOutputDirectoryItems
</GetCopyToOutputDirectoryItemsDependsOn>
<!--
Mitigation for https://github.com/dotnet/msbuild/issues/4677
When MSBuildCopyContentTransitively == true, all content copying is transitive.
When MSBuildCopyContentTransitively == false, content copying is 1 level deep.
When MSBuildCopyContentTransitively != {true, false}, the legacy behaviour in https://github.com/dotnet/msbuild/issues/4677 manifests.
-->
<_RecursiveTargetForContentCopying>GetCopyToOutputDirectoryItems</_RecursiveTargetForContentCopying>
<!-- Enforce 1 level deep content copying by replacing the recursive content target with the target that retrieves the content for the current project only. -->
<_RecursiveTargetForContentCopying Condition=" '$(MSBuildCopyContentTransitively)' == 'false' ">_GetCopyToOutputDirectoryItemsFromThisProject</_RecursiveTargetForContentCopying>
</PropertyGroup>
<Target Name="_PopulateCommonStateForGetCopyToOutputDirectoryItems">
<!-- In the general case, clients need very little of the metadata which is generated by invoking this target on this project and its children. For those
cases, we can immediately discard the unwanted metadata, reducing memory usage, particularly in very large and interconnected systems of projects.
However, if some client does require the original functionality, it is sufficient to set MSBuildDisableGetCopyToOutputDirectoryItemsOptimization to
a non-empty value and the original behavior will be restored. -->
<PropertyGroup Condition=" '$(MSBuildDisableGetCopyToOutputDirectoryItemsOptimization)' == '' ">
<_GCTODIKeepDuplicates>false</_GCTODIKeepDuplicates>
<_GCTODIKeepMetadata>CopyToOutputDirectory;TargetPath</_GCTODIKeepMetadata>
</PropertyGroup>
</Target>
<Target
Name="_GetCopyToOutputDirectoryItemsFromTransitiveProjectReferences"
DependsOnTargets="_PopulateCommonStateForGetCopyToOutputDirectoryItems;_AddOutputPathToGlobalPropertiesToRemove"
Returns="@(_CopyToOutputDirectoryTransitiveItems)">
<!-- Get items from child projects first. -->
<MSBuild
Projects="@(_MSBuildProjectReferenceExistent)"
Targets="$(_RecursiveTargetForContentCopying)"
BuildInParallel="$(BuildInParallel)"
Properties="%(_MSBuildProjectReferenceExistent.SetConfiguration); %(_MSBuildProjectReferenceExistent.SetPlatform); %(_MSBuildProjectReferenceExistent.SetTargetFramework)"
Condition="'@(_MSBuildProjectReferenceExistent)' != '' and '$(_GetChildProjectCopyToOutputDirectoryItems)' == 'true' and '%(_MSBuildProjectReferenceExistent.Private)' != 'false' and '$(UseCommonOutputDirectory)' != 'true'"
ContinueOnError="$(ContinueOnError)"
SkipNonexistentTargets="true"
RemoveProperties="%(_MSBuildProjectReferenceExistent.GlobalPropertiesToRemove)$(_GlobalPropertiesToRemoveFromProjectReferences)">
<Output TaskParameter="TargetOutputs" ItemName="_AllChildProjectItemsWithTargetPath"/>
</MSBuild>
<!-- Target outputs must be full paths because they will be consumed by a different project. -->
<ItemGroup>
<_CopyToOutputDirectoryTransitiveItems KeepDuplicates=" '$(_GCTODIKeepDuplicates)' != 'false' " KeepMetadata="$(_GCTODIKeepMetadata)" Include="@(_AllChildProjectItemsWithTargetPath->'%(FullPath)')" Condition="'%(_AllChildProjectItemsWithTargetPath.CopyToOutputDirectory)'=='Always'"/>
<_CopyToOutputDirectoryTransitiveItems KeepDuplicates=" '$(_GCTODIKeepDuplicates)' != 'false' " KeepMetadata="$(_GCTODIKeepMetadata)" Include="@(_AllChildProjectItemsWithTargetPath->'%(FullPath)')" Condition="'%(_AllChildProjectItemsWithTargetPath.CopyToOutputDirectory)'=='PreserveNewest'"/>
</ItemGroup>
<!-- Remove items which we will never again use - they just sit around taking up memory otherwise -->
<ItemGroup>
<_AllChildProjectItemsWithTargetPath Remove="@(_AllChildProjectItemsWithTargetPath)"/>
</ItemGroup>
<!-- Copy paste _GetCopyToOutputDirectoryItemsFromThisProject but keep the items that came from other projects via ProjectReference's OutputItemType metadata -->
<ItemGroup>
<_CopyToOutputDirectoryTransitiveItems KeepMetadata="$(_GCTODIKeepMetadata)" Include="@(ContentWithTargetPath->'%(FullPath)')" Condition="'%(ContentWithTargetPath.CopyToOutputDirectory)'=='Always' AND '%(ContentWithTargetPath.MSBuildSourceProjectFile)'!=''"/>
<_CopyToOutputDirectoryTransitiveItems KeepMetadata="$(_GCTODIKeepMetadata)" Include="@(ContentWithTargetPath->'%(FullPath)')" Condition="'%(ContentWithTargetPath.CopyToOutputDirectory)'=='PreserveNewest' AND '%(ContentWithTargetPath.MSBuildSourceProjectFile)'!=''"/>
</ItemGroup>
<ItemGroup>
<_CopyToOutputDirectoryTransitiveItems KeepMetadata="$(_GCTODIKeepMetadata)" Include="@(EmbeddedResource->'%(FullPath)')" Condition="'%(EmbeddedResource.CopyToOutputDirectory)'=='Always' AND '%(EmbeddedResource.MSBuildSourceProjectFile)'!=''"/>
<_CopyToOutputDirectoryTransitiveItems KeepMetadata="$(_GCTODIKeepMetadata)" Include="@(EmbeddedResource->'%(FullPath)')" Condition="'%(EmbeddedResource.CopyToOutputDirectory)'=='PreserveNewest' AND '%(EmbeddedResource.MSBuildSourceProjectFile)'!=''"/>
</ItemGroup>
<ItemGroup>
<_CompileItemsToCopy Include="@(Compile->'%(FullPath)')" Condition="('%(Compile.CopyToOutputDirectory)'=='Always' or '%(Compile.CopyToOutputDirectory)'=='PreserveNewest') AND '%(Compile.MSBuildSourceProjectFile)'!=''"/>
</ItemGroup>
<AssignTargetPath Files="@(_CompileItemsToCopy)" RootFolder="$(MSBuildProjectDirectory)">
<Output TaskParameter="AssignedFiles" ItemName="_CompileItemsToCopyWithTargetPath" />
</AssignTargetPath>
<ItemGroup>
<_CopyToOutputDirectoryTransitiveItems KeepMetadata="$(_GCTODIKeepMetadata)" Include="@(_CompileItemsToCopyWithTargetPath)" Condition="'%(_CompileItemsToCopyWithTargetPath.CopyToOutputDirectory)'=='Always'"/>
<_CopyToOutputDirectoryTransitiveItems KeepMetadata="$(_GCTODIKeepMetadata)" Include="@(_CompileItemsToCopyWithTargetPath)" Condition="'%(_CompileItemsToCopyWithTargetPath.CopyToOutputDirectory)'=='PreserveNewest'"/>
</ItemGroup>
<ItemGroup>
<_CopyToOutputDirectoryTransitiveItems KeepMetadata="$(_GCTODIKeepMetadata)" Include="@(_NoneWithTargetPath->'%(FullPath)')" Condition="'%(_NoneWithTargetPath.CopyToOutputDirectory)'=='Always' AND '%(_NoneWithTargetPath.MSBuildSourceProjectFile)'!=''"/>
<_CopyToOutputDirectoryTransitiveItems KeepMetadata="$(_GCTODIKeepMetadata)" Include="@(_NoneWithTargetPath->'%(FullPath)')" Condition="'%(_NoneWithTargetPath.CopyToOutputDirectory)'=='PreserveNewest' AND '%(_NoneWithTargetPath.MSBuildSourceProjectFile)'!=''"/>
</ItemGroup>
</Target>
<Target
Name="_GetCopyToOutputDirectoryItemsFromThisProject"
DependsOnTargets="AssignTargetPaths;_PopulateCommonStateForGetCopyToOutputDirectoryItems"
Returns="@(_ThisProjectItemsToCopyToOutputDirectory)">
<ItemGroup>
<_ThisProjectItemsToCopyToOutputDirectory KeepMetadata="$(_GCTODIKeepMetadata)" Include="@(ContentWithTargetPath->'%(FullPath)')" Condition="'%(ContentWithTargetPath.CopyToOutputDirectory)'=='Always' AND '%(ContentWithTargetPath.MSBuildSourceProjectFile)'==''"/>
<_ThisProjectItemsToCopyToOutputDirectory KeepMetadata="$(_GCTODIKeepMetadata)" Include="@(ContentWithTargetPath->'%(FullPath)')" Condition="'%(ContentWithTargetPath.CopyToOutputDirectory)'=='PreserveNewest' AND '%(ContentWithTargetPath.MSBuildSourceProjectFile)'==''"/>
</ItemGroup>
<ItemGroup>
<_ThisProjectItemsToCopyToOutputDirectory KeepMetadata="$(_GCTODIKeepMetadata)" Include="@(EmbeddedResource->'%(FullPath)')" Condition="'%(EmbeddedResource.CopyToOutputDirectory)'=='Always' AND '%(EmbeddedResource.MSBuildSourceProjectFile)'==''"/>
<_ThisProjectItemsToCopyToOutputDirectory KeepMetadata="$(_GCTODIKeepMetadata)" Include="@(EmbeddedResource->'%(FullPath)')" Condition="'%(EmbeddedResource.CopyToOutputDirectory)'=='PreserveNewest' AND '%(EmbeddedResource.MSBuildSourceProjectFile)'==''"/>
</ItemGroup>
<ItemGroup>
<_CompileItemsToCopy Include="@(Compile->'%(FullPath)')" Condition="('%(Compile.CopyToOutputDirectory)'=='Always' or '%(Compile.CopyToOutputDirectory)'=='PreserveNewest') AND '%(Compile.MSBuildSourceProjectFile)'==''"/>
</ItemGroup>
<AssignTargetPath Files="@(_CompileItemsToCopy)" RootFolder="$(MSBuildProjectDirectory)">
<Output TaskParameter="AssignedFiles" ItemName="_CompileItemsToCopyWithTargetPath" />
</AssignTargetPath>
<ItemGroup>
<_ThisProjectItemsToCopyToOutputDirectory KeepMetadata="$(_GCTODIKeepMetadata)" Include="@(_CompileItemsToCopyWithTargetPath)" Condition="'%(_CompileItemsToCopyWithTargetPath.CopyToOutputDirectory)'=='Always'"/>
<_ThisProjectItemsToCopyToOutputDirectory KeepMetadata="$(_GCTODIKeepMetadata)" Include="@(_CompileItemsToCopyWithTargetPath)" Condition="'%(_CompileItemsToCopyWithTargetPath.CopyToOutputDirectory)'=='PreserveNewest'"/>
</ItemGroup>
<ItemGroup>
<_ThisProjectItemsToCopyToOutputDirectory KeepMetadata="$(_GCTODIKeepMetadata)" Include="@(_NoneWithTargetPath->'%(FullPath)')" Condition="'%(_NoneWithTargetPath.CopyToOutputDirectory)'=='Always' AND '%(_NoneWithTargetPath.MSBuildSourceProjectFile)'==''"/>
<_ThisProjectItemsToCopyToOutputDirectory KeepMetadata="$(_GCTODIKeepMetadata)" Include="@(_NoneWithTargetPath->'%(FullPath)')" Condition="'%(_NoneWithTargetPath.CopyToOutputDirectory)'=='PreserveNewest' AND '%(_NoneWithTargetPath.MSBuildSourceProjectFile)'==''"/>
</ItemGroup>
</Target>
<Target
Name="GetCopyToOutputDirectoryItems"
Returns="@(AllItemsFullPathWithTargetPath)"
KeepDuplicateOutputs=" '$(MSBuildDisableGetCopyToOutputDirectoryItemsOptimization)' == '' "
DependsOnTargets="$(GetCopyToOutputDirectoryItemsDependsOn)">
<!-- Compose the content items as the union between transitive content items and content items from this project. -->
<!-- Use CallTarget to avoid breaking targets that hook right before GetCopyToOutputDirectoryItems but expect to run after _GetCopyToOutputDirectoryItemsFromTransitiveProjectReferences and _GetCopyToOutputDirectoryItemsFromThisProject -->
<CallTarget Targets="_GetCopyToOutputDirectoryItemsFromTransitiveProjectReferences">
<Output TaskParameter="TargetOutputs" ItemName="_TransitiveItemsToCopyToOutputDirectory" />
</CallTarget>
<CallTarget Targets="_GetCopyToOutputDirectoryItemsFromThisProject">
<Output TaskParameter="TargetOutputs" ItemName="_ThisProjectItemsToCopyToOutputDirectory" />
</CallTarget>
<ItemGroup Condition="'$(CopyConflictingTransitiveContent)' == 'false'">
<_TransitiveItemsToCopyToOutputDirectory Remove="@(_ThisProjectItemsToCopyToOutputDirectory)" MatchOnMetadata="TargetPath" MatchOnMetadataOptions="PathLike" />
</ItemGroup>
<ItemGroup>
<_TransitiveItemsToCopyToOutputDirectoryAlways KeepDuplicates=" '$(_GCTODIKeepDuplicates)' != 'false' " KeepMetadata="$(_GCTODIKeepMetadata)" Include="@(_TransitiveItemsToCopyToOutputDirectory->'%(FullPath)')" Condition="'%(_TransitiveItemsToCopyToOutputDirectory.CopyToOutputDirectory)'=='Always'"/>
<_TransitiveItemsToCopyToOutputDirectoryPreserveNewest KeepDuplicates=" '$(_GCTODIKeepDuplicates)' != 'false' " KeepMetadata="$(_GCTODIKeepMetadata)" Include="@(_TransitiveItemsToCopyToOutputDirectory->'%(FullPath)')" Condition="'%(_TransitiveItemsToCopyToOutputDirectory.CopyToOutputDirectory)'=='PreserveNewest'"/>
<_ThisProjectItemsToCopyToOutputDirectoryAlways KeepDuplicates=" '$(_GCTODIKeepDuplicates)' != 'false' " KeepMetadata="$(_GCTODIKeepMetadata)" Include="@(_ThisProjectItemsToCopyToOutputDirectory->'%(FullPath)')" Condition="'%(_ThisProjectItemsToCopyToOutputDirectory.CopyToOutputDirectory)'=='Always'"/>
<_ThisProjectItemsToCopyToOutputDirectoryPreserveNewest KeepDuplicates=" '$(_GCTODIKeepDuplicates)' != 'false' " KeepMetadata="$(_GCTODIKeepMetadata)" Include="@(_ThisProjectItemsToCopyToOutputDirectory->'%(FullPath)')" Condition="'%(_ThisProjectItemsToCopyToOutputDirectory.CopyToOutputDirectory)'=='PreserveNewest'"/>
<!-- Append the items from this project last so that they will be copied last. -->
<_SourceItemsToCopyToOutputDirectoryAlways Include="@(_TransitiveItemsToCopyToOutputDirectoryAlways);@(_ThisProjectItemsToCopyToOutputDirectoryAlways)"/>
<_SourceItemsToCopyToOutputDirectory Include="@(_TransitiveItemsToCopyToOutputDirectoryPreserveNewest);@(_ThisProjectItemsToCopyToOutputDirectoryPreserveNewest)"/>
<AllItemsFullPathWithTargetPath Include="@(_SourceItemsToCopyToOutputDirectoryAlways->'%(FullPath)');@(_SourceItemsToCopyToOutputDirectory->'%(FullPath)')"/>
<!-- Empty intermediate items to release memory -->
<_TransitiveItemsToCopyToOutputDirectoryAlways Remove="@(_TransitiveItemsToCopyToOutputDirectoryAlways)"/>
<_TransitiveItemsToCopyToOutputDirectoryPreserveNewest Remove="@(_TransitiveItemsToCopyToOutputDirectoryPreserveNewest)"/>
<_ThisProjectItemsToCopyToOutputDirectoryAlways Remove="@(_ThisProjectItemsToCopyToOutputDirectoryAlways)"/>
<_ThisProjectItemsToCopyToOutputDirectoryPreserveNewest Remove="@(_ThisProjectItemsToCopyToOutputDirectoryPreserveNewest)"/>
<_ThisProjectItemsToCopyToOutputDirectory Remove="@(_ThisProjectItemsToCopyToOutputDirectory)"/>
</ItemGroup>
</Target>
<!--
============================================================
GetCopyToPublishDirectoryItems
Default implementation of GetCopyToPublishDirectoryItems for projects that do not
use Microsoft.NET.Sdk. It simply returns whatever GetCopyToOutputDirectoryItems
does with CopyToPublishDirectory implied by CopyToOutputDirectory, which is the
same as Microsoft.NET.Sdk default when its CopyToPublishDirectory is not used.
Microsoft.NET.Sdk projects will override this to allow the publish output to be
customized independently from the build output.
Having a default implementation here allows the Microsoft.NET.Sdk Publish target
to work when a Microsoft.NET.Sdk-based project references a non-Microsoft.NET.Sdk-based
project.
============================================================
-->
<Target
Name="GetCopyToPublishDirectoryItems"
DependsOnTargets="GetCopyToOutputDirectoryItems"
Returns="@(AllPublishItemsFullPathWithTargetPath)">
<ItemGroup>
<AllPublishItemsFullPathWithTargetPath Include="@(AllItemsFullPathWithTargetPath)">
<CopyToPublishDirectory>%(CopyToOutputDirectory)</CopyToPublishDirectory>
</AllPublishItemsFullPathWithTargetPath>
</ItemGroup>
</Target>
<!--
============================================================
_CopyOutOfDateSourceItemsToOutputDirectory
Copy files that have the CopyToOutputDirectory attribute set to 'PreserveNewest'.
============================================================
-->
<Target
Name="_CopyOutOfDateSourceItemsToOutputDirectory"
Condition=" '@(_SourceItemsToCopyToOutputDirectory)' != '' "
Inputs="@(_SourceItemsToCopyToOutputDirectory)"
Outputs="@(_SourceItemsToCopyToOutputDirectory->'$(OutDir)%(TargetPath)')">
<!--
Not using SkipUnchangedFiles="true" because the application may want to change
one of these files and not have an incremental build replace it.
-->
<Copy
SourceFiles = "@(_SourceItemsToCopyToOutputDirectory)"
DestinationFiles = "@(_SourceItemsToCopyToOutputDirectory->'$(OutDir)%(TargetPath)')"
OverwriteReadOnlyFiles="$(OverwriteReadOnlyFiles)"
Retries="$(CopyRetryCount)"
RetryDelayMilliseconds="$(CopyRetryDelayMilliseconds)"
UseHardlinksIfPossible="$(CreateHardLinksForAdditionalFilesIfPossible)"
UseSymboliclinksIfPossible="$(CreateSymbolicLinksForAdditionalFilesIfPossible)"
>
<Output TaskParameter="DestinationFiles" ItemName="FileWrites"/>
</Copy>
</Target>
<!--
============================================================
_CopyOutOfDateSourceItemsToOutputDirectoryAlways
Copy files that have the CopyToOutputDirectory attribute set to 'Always'.
============================================================
-->
<Target
Name="_CopyOutOfDateSourceItemsToOutputDirectoryAlways"
Condition=" '@(_SourceItemsToCopyToOutputDirectoryAlways)' != '' ">
<!--
Not using SkipUnchangedFiles="true" because the application may want to change
one of these files and not have an incremental build replace it.
-->
<Copy
SourceFiles = "@(_SourceItemsToCopyToOutputDirectoryAlways)"
DestinationFiles = "@(_SourceItemsToCopyToOutputDirectoryAlways->'$(OutDir)%(TargetPath)')"
OverwriteReadOnlyFiles="$(OverwriteReadOnlyFiles)"
Retries="$(CopyRetryCount)"
RetryDelayMilliseconds="$(CopyRetryDelayMilliseconds)"
UseHardlinksIfPossible="$(CreateHardLinksForAdditionalFilesIfPossible)"
UseSymboliclinksIfPossible="$(CreateSymbolicLinksForAdditionalFilesIfPossible)"
>
<Output TaskParameter="DestinationFiles" ItemName="FileWrites"/>
</Copy>
</Target>
<!--
============================================================
_CopyAppConfigFile
Copy the application config file.
============================================================
-->
<Target
Name="_CopyAppConfigFile"
Condition=" '@(AppConfigWithTargetPath)' != '' "
Inputs="@(AppConfigWithTargetPath)"
Outputs="@(AppConfigWithTargetPath->'$(OutDir)%(TargetPath)')">
<!--
Copy the application's .config file, if any.
Not using SkipUnchangedFiles="true" because the application may want to change
the app.config and not have an incremental build replace it.
-->
<Copy
SourceFiles="@(AppConfigWithTargetPath)"
DestinationFiles="@(AppConfigWithTargetPath->'$(OutDir)%(TargetPath)')"
OverwriteReadOnlyFiles="$(OverwriteReadOnlyFiles)"
Retries="$(CopyRetryCount)"
RetryDelayMilliseconds="$(CopyRetryDelayMilliseconds)"
UseHardlinksIfPossible="$(CreateHardLinksForAdditionalFilesIfPossible)"
UseSymboliclinksIfPossible="$(CreateSymbolicLinksForAdditionalFilesIfPossible)"
>
<Output TaskParameter="DestinationFiles" ItemName="FileWrites"/>
</Copy>
</Target>
<!--
================================================================
_CopyManifestFiles
================================================================
Copy the built manifests (.exe.manifest, .application/.xbap) to the final directory.
-->
<Target
Name="_CopyManifestFiles"
Condition=" '$(_DeploymentCopyApplicationManifest)'=='true' or '$(GenerateClickOnceManifests)'=='true' "
DependsOnTargets="PrepareForBuild">
<Copy
SourceFiles="@(ApplicationManifest)"
DestinationFolder="$(OutDir)"
SkipUnchangedFiles="$(SkipCopyUnchangedFiles)"
OverwriteReadOnlyFiles="$(OverwriteReadOnlyFiles)"
Retries="$(CopyRetryCount)"
RetryDelayMilliseconds="$(CopyRetryDelayMilliseconds)"
UseHardlinksIfPossible="$(CreateHardLinksForAdditionalFilesIfPossible)"
UseSymboliclinksIfPossible="$(CreateSymbolicLinksForAdditionalFilesIfPossible)"
Condition="'$(GenerateClickOnceManifests)'=='true' or '$(_DeploymentCopyApplicationManifest)'=='true'">
<Output TaskParameter="DestinationFiles" ItemName="_DeploymentMainApplicationManifest"/>
<Output TaskParameter="DestinationFiles" ItemName="FileWrites"/>
</Copy>
<Message Importance="Normal" Condition="'$(_DeploymentCopyApplicationManifest)'=='true'" Text="$(MSBuildProjectName) -> @(_DeploymentMainApplicationManifest->'%(FullPath)')" />
<Copy
SourceFiles="@(DeployManifest)"
DestinationFolder="$(OutDir)"
SkipUnchangedFiles="$(SkipCopyUnchangedFiles)"
OverwriteReadOnlyFiles="$(OverwriteReadOnlyFiles)"
Retries="$(CopyRetryCount)"
RetryDelayMilliseconds="$(CopyRetryDelayMilliseconds)"
UseHardlinksIfPossible="$(CreateHardLinksForAdditionalFilesIfPossible)"
UseSymboliclinksIfPossible="$(CreateSymbolicLinksForAdditionalFilesIfPossible)"
Condition="'$(GenerateClickOnceManifests)'=='true'">
<Output TaskParameter="DestinationFiles" ItemName="_DeploymentMainDeployManifest"/>
<Output TaskParameter="DestinationFiles" ItemName="FileWrites"/>
</Copy>
<Message Importance="Normal" Condition="'$(GenerateClickOnceManifests)'=='true'" Text="$(MSBuildProjectName) -> @(_DeploymentMainDeployManifest->'%(FullPath)')" />
</Target>
<!--
================================================================
_CheckForCompileOutputs
Checks each file output from the main "Compile" target to make sure they really exist.
If they do, then record them in the clean cache.
============================================================
-->
<Target
Name="_CheckForCompileOutputs">
<!--Record the main compile outputs.-->
<ItemGroup>
<FileWrites Include="@(IntermediateAssembly)" Condition="Exists('@(IntermediateAssembly)')"/>
<FileWrites Include="@(IntermediateRefAssembly)" Condition="'$(ProduceReferenceAssembly)' == 'true' and Exists('@(IntermediateRefAssembly)')"/>
</ItemGroup>
<!-- Record the .xml if one was produced. -->
<PropertyGroup>
<_DocumentationFileProduced Condition="!Exists('@(DocFileItem)')">false</_DocumentationFileProduced>
</PropertyGroup>
<ItemGroup>
<FileWrites Include="@(DocFileItem)" Condition="'$(_DocumentationFileProduced)'=='true'"/>
</ItemGroup>
<!-- Record the .pdb if one was produced. -->
<PropertyGroup>
<_DebugSymbolsProduced Condition="!Exists('@(_DebugSymbolsIntermediatePath)')">false</_DebugSymbolsProduced>
</PropertyGroup>
<ItemGroup>
<FileWrites Include="@(_DebugSymbolsIntermediatePath)" Condition="'$(_DebugSymbolsProduced)'=='true'"/>
</ItemGroup>
</Target>
<!--
============================================================
_SGenCheckForOutputs
Checks each file output from the "GenerateSerializationAssemblies" target to make sure they really exist.
If they do, then record them in the clean cache.
============================================================
-->
<Target
Name="_SGenCheckForOutputs"
Condition="'$(_SGenGenerateSerializationAssembliesConfig)' == 'On' or ('@(WebReferenceUrl)'!='' and '$(_SGenGenerateSerializationAssembliesConfig)' == 'Auto')"
>
<!-- Record the serializer .dll if one was produced.-->
<PropertyGroup>
<_SGenDllCreated Condition="Exists('$(IntermediateOutputPath)$(_SGenDllName)')">true</_SGenDllCreated>
</PropertyGroup>
<ItemGroup>
<FileWrites Include="$(IntermediateOutputPath)$(_SGenDllName)" Condition="Exists('$(IntermediateOutputPath)$(_SGenDllName)')"/>
</ItemGroup>
</Target>
<!--
***********************************************************************************************
***********************************************************************************************
UnmanagedRegistration Section
***********************************************************************************************
***********************************************************************************************
-->
<!--
============================================================
UnmanagedRegistration
Registers the main assembly for COM interop.
============================================================
-->
<PropertyGroup>
<UnmanagedRegistrationDependsOn></UnmanagedRegistrationDependsOn>
</PropertyGroup>
<Target
Name="UnmanagedRegistration"
Condition="'$(RegisterForComInterop)'=='true' and '$(OutputType)'=='library'"
DependsOnTargets="$(UnmanagedRegistrationDependsOn)"
>
<PropertyGroup>
<RegisterAssemblyMSBuildArchitecture Condition="'$(RegisterAssemblyMSBuildArchitecture)' == ''">$(PlatformTargetAsMSBuildArchitecture)</RegisterAssemblyMSBuildArchitecture>
</PropertyGroup>
<PropertyGroup Condition="'$(TargetFrameworkAsMSBuildRuntime)' != '' and '$(RegisterAssemblyMSBuildArchitecture)' != ''">
<!-- Falling back to the current runtime if we are targeting CLR2 and the task host doesn't exist will lead to
incorrect behavior in some cases, but it's the same incorrect behavior as Visual Studio 2010, and thus better
than causing build breaks on upgrade to Win8 the way not doing so would. For more details, see the
corresponding comment in GenerateResource. -->
<RegisterAssemblyMSBuildRuntime
Condition="'$(RegisterAssemblyMSBuildRuntime)' == '' and
$([MSBuild]::DoesTaskHostExist(`$(TargetFrameworkAsMSBuildRuntime)`, `$(RegisterAssemblyMSBuildArchitecture)`))">$(TargetFrameworkAsMSBuildRuntime)</RegisterAssemblyMSBuildRuntime>
<!-- If the targeted runtime doesn't exist, fall back to current -->
<RegisterAssemblyMSBuildRuntime Condition="'$(RegisterAssemblyMSBuildRuntime)' == ''">CurrentRuntime</RegisterAssemblyMSBuildRuntime>
</PropertyGroup>
<RegisterAssembly
Assemblies="@(_OutputPathItem->'%(FullPath)$(TargetFileName)')"
TypeLibFiles="@(_OutputPathItem->'%(FullPath)$(TargetName).tlb')"
AssemblyListFile="@(_UnmanagedRegistrationCache)"
CreateCodeBase="true"
MSBuildRuntime="$(RegisterAssemblyMSBuildRuntime)"
MSBuildArchitecture="$(RegisterAssemblyMSBuildArchitecture)"
Condition="!Exists('@(_UnmanagedRegistrationCache)')"/>
<ItemGroup>
<FileWrites Include="@(_OutputPathItem->'%(FullPath)$(TargetName).tlb')"/>
</ItemGroup>
</Target>
<!--
***********************************************************************************************
***********************************************************************************************
IncrementalClean Section
***********************************************************************************************
***********************************************************************************************
-->
<!--
============================================================
IncrementalClean
Remove files that were produced in a prior build but weren't produced in the current build.
The reason is that if, for example, the name of the .exe has changed we want to delete the
old copy.
Leave the Clean cache file containing only the files produced in the current build.
============================================================
-->
<Target
Name="IncrementalClean"
DependsOnTargets="$(IncrementalCleanDependsOn);_CleanGetCurrentAndPriorFileWrites">
<!-- Subtract list of files produced in prior builds from list of files produced in this build. -->
<ItemGroup>
<_CleanOrphanFileWrites Include="@(_CleanPriorFileWrites)" Exclude="@(_CleanCurrentFileWrites)"/>
</ItemGroup>
<!-- Find all files in the final output directory. -->
<FindUnderPath Path="$(OutDir)" Files="@(_CleanOrphanFileWrites)">
<Output TaskParameter="InPath" ItemName="_CleanOrphanFileWritesInOutput"/>
</FindUnderPath>
<!-- Find all files in the intermediate output directory. -->
<FindUnderPath Path="$(IntermediateOutputPath)" Files="@(_CleanOrphanFileWrites)">
<Output TaskParameter="InPath" ItemName="_CleanOrphanFileWritesInIntermediate"/>
</FindUnderPath>
<!-- Delete the orphaned files. -->
<Delete
Files="@(_CleanOrphanFileWritesInIntermediate);@(_CleanOrphanFileWritesInOutput)"
TreatErrorsAsWarnings="true">
<Output TaskParameter="DeletedFiles" ItemName="_CleanOrphanFilesDeleted"/>
</Delete>
<!-- Create a list of everything that wasn't deleted or was outside
the current final output and intermediate output directories. -->
<ItemGroup>
<_CleanRemainingFileWritesAfterIncrementalClean Include="@(_CleanPriorFileWrites);@(_CleanCurrentFileWrites)" Exclude="@(_CleanOrphanFilesDeleted)"/>
</ItemGroup>
<!-- Remove duplicates. -->
<RemoveDuplicates Inputs="@(_CleanRemainingFileWritesAfterIncrementalClean)">
<Output TaskParameter="Filtered" ItemName="_CleanUniqueRemainingFileWritesAfterIncrementalClean"/>
</RemoveDuplicates>
<!-- Write new list of current files back to disk, replacing the existing list.-->
<WriteLinesToFile
File="$(IntermediateOutputPath)$(CleanFile)"
Lines="@(_CleanUniqueRemainingFileWritesAfterIncrementalClean)"
Condition="'@(_CleanUnfilteredPriorFileWrites)'!='@(_CleanUniqueRemainingFileWritesAfterIncrementalClean)'"
Overwrite="true"/>
</Target>
<!--
============================================================
_CleanGetCurrentAndPriorFileWrites
Get the list of files built in the current build and in prior builds.
============================================================
-->
<Target
Name="_CleanGetCurrentAndPriorFileWrites"
DependsOnTargets="_CheckForCompileOutputs;_SGenCheckForOutputs">
<!-- Read the list of files produced by a prior builds from disk. -->
<ReadLinesFromFile File="$(IntermediateOutputPath)$(CleanFile)">
<Output TaskParameter="Lines" ItemName="_CleanUnfilteredPriorFileWrites"/>
</ReadLinesFromFile>
<!--
Convert the list of references to the absolute paths so we can make valid comparisons
across two lists
-->
<ConvertToAbsolutePath Paths="@(_ResolveAssemblyReferenceResolvedFiles)">
<Output TaskParameter="AbsolutePaths" ItemName="_ResolveAssemblyReferenceResolvedFilesAbsolute"/>
</ConvertToAbsolutePath>
<!--
Subtract any resolved assembly files from *prior* file writes because deleting
these would break subsequent builds because the assemblies would be unresolvable.
-->
<ItemGroup>
<_CleanPriorFileWrites Include="@(_CleanUnfilteredPriorFileWrites)" Exclude="@(_ResolveAssemblyReferenceResolvedFilesAbsolute)"/>
</ItemGroup>
<!--
Of shareable files, keep only those that are in the project's directory.
We never clean shareable files outside of the project directory because
the build may be to a common output directory and other projects may need
them.
Only subtract the outputs from ResolveAssemblyReferences target because that's the
only "Resolve" target that tries to resolve assemblies directly from the output
directory.
-->
<FindUnderPath Path="$(MSBuildProjectDirectory)" Files="@(FileWritesShareable)" UpdateToAbsolutePaths="true">
<Output TaskParameter="InPath" ItemName="FileWrites"/>
</FindUnderPath>
<!-- Find all files in the final output directory. -->
<FindUnderPath Path="$(OutDir)" Files="@(FileWrites)" UpdateToAbsolutePaths="true">
<Output TaskParameter="InPath" ItemName="_CleanCurrentFileWritesInOutput"/>
</FindUnderPath>
<!-- Find all files in the intermediate output directory. -->
<FindUnderPath Path="$(IntermediateOutputPath)" Files="@(FileWrites)" UpdateToAbsolutePaths="true">
<Output TaskParameter="InPath" ItemName="_CleanCurrentFileWritesInIntermediate"/>
</FindUnderPath>
<!--
Subtract any resolved assembly files from *current* file writes because deleting
these would break subsequent builds because the assemblies would be unresolvable.
Only subtract the outputs from ResolveAssemblyReferences target because that's the
only "Resolve" target that tries to resolve assemblies directly from the output
directory.
-->
<ItemGroup>
<_CleanCurrentFileWritesWithNoReferences Include="@(_CleanCurrentFileWritesInOutput);@(_CleanCurrentFileWritesInIntermediate)" Exclude="@(_ResolveAssemblyReferenceResolvedFilesAbsolute)"/>
</ItemGroup>
<!-- Remove duplicates from files produced in this build. -->
<RemoveDuplicates Inputs="@(_CleanCurrentFileWritesWithNoReferences)" >
<Output TaskParameter="Filtered" ItemName="_CleanCurrentFileWrites"/>
</RemoveDuplicates>
</Target>
<!--
***********************************************************************************************
***********************************************************************************************
Clean Section
***********************************************************************************************
***********************************************************************************************
-->
<!--
============================================================
Clean
Delete all intermediate and final build outputs.
============================================================
-->
<PropertyGroup>
<CleanDependsOn>
BeforeClean;
UnmanagedUnregistration;
CoreClean;
CleanReferencedProjects;
CleanPublishFolder;
AfterClean
</CleanDependsOn>
</PropertyGroup>
<Target
Name="Clean"
Condition=" '$(_InvalidConfigurationWarning)' != 'true' "
DependsOnTargets="$(CleanDependsOn)" />
<!--
============================================================
BeforeClean
Redefine this target in your project in order to run tasks just before Clean.
============================================================
-->
<Target Name="BeforeClean"/>
<!--
============================================================
AfterClean
Redefine this target in your project in order to run tasks just after Clean.
============================================================
-->
<Target Name="AfterClean"/>
<!--
============================================================
CleanReferencedProjects
Call Clean target on all Referenced Projects.
============================================================
-->
<Target
Name="CleanReferencedProjects"
DependsOnTargets="PrepareProjectReferences">
<!--
When building the project directly from the command-line, clean those referenced projects
that exist on disk. For IDE builds and command-line .SLN builds, the solution build manager
takes care of this.
-->
<MSBuild
Projects="@(_MSBuildProjectReferenceExistent)"
Targets="Clean"
Properties="%(_MSBuildProjectReferenceExistent.SetConfiguration); %(_MSBuildProjectReferenceExistent.SetPlatform); %(_MSBuildProjectReferenceExistent.SetTargetFramework)"
BuildInParallel="$(BuildInParallel)"
Condition="'$(BuildingInsideVisualStudio)' != 'true' and '$(BuildProjectReferences)' == 'true' and '@(_MSBuildProjectReferenceExistent)' != ''"
ContinueOnError="$(ContinueOnError)"
RemoveProperties="%(_MSBuildProjectReferenceExistent.GlobalPropertiesToRemove)$(_GlobalPropertiesToRemoveFromProjectReferences)"/>
</Target>
<!--
============================================================
CoreClean
============================================================
-->
<PropertyGroup>
<CoreCleanDependsOn></CoreCleanDependsOn>
</PropertyGroup>
<Target
Name="CoreClean"
DependsOnTargets="$(CoreCleanDependsOn)">
<!-- First clean any explicitly specified cleanable files.
Declare items of this type if you want Clean to delete them. -->
<Delete
Files="@(Clean)"
TreatErrorsAsWarnings="true"/>
<!-- Read in list of files that were written to disk in past builds. -->
<ReadLinesFromFile File="$(IntermediateOutputPath)$(CleanFile)">
<Output TaskParameter="Lines" ItemName="_CleanPriorFileWrites"/>
</ReadLinesFromFile>
<!-- Find all files in the final output directory. -->
<FindUnderPath Path="$(OutDir)" Files="@(_CleanPriorFileWrites)">
<Output TaskParameter="InPath" ItemName="_CleanPriorFileWritesInOutput"/>
</FindUnderPath>
<!-- Find all files in the intermediate output directory. -->
<FindUnderPath Path="$(IntermediateOutputPath)" Files="@(_CleanPriorFileWrites)">
<Output TaskParameter="InPath" ItemName="_CleanPriorFileWritesInIntermediate"/>
</FindUnderPath>
<!-- Delete those files. -->
<Delete
Files="@(_CleanPriorFileWritesInOutput);@(_CleanPriorFileWritesInIntermediate)"
TreatErrorsAsWarnings="true">
<Output TaskParameter="DeletedFiles" ItemName="_CleanPriorFileWritesDeleted"/>
</Delete>
<!-- Create a list of everything that wasn't deleted. -->
<ItemGroup>
<_CleanRemainingFileWritesAfterClean Include="@(_CleanPriorFileWrites)" Exclude="@(_CleanPriorFileWritesDeleted)"/>
</ItemGroup>
<!-- Remove duplicates. -->
<RemoveDuplicates Inputs="@(_CleanRemainingFileWritesAfterClean)">
<Output TaskParameter="Filtered" ItemName="_CleanUniqueRemainingFileWrites"/>
</RemoveDuplicates>
<!-- Make sure the directory exists. -->
<MakeDir Directories="$(IntermediateOutputPath)"/>
<!-- Write new list of current files back to disk. -->
<WriteLinesToFile File="$(IntermediateOutputPath)$(CleanFile)" Lines="@(_CleanUniqueRemainingFileWrites)" WriteOnlyWhenDifferent="true" Overwrite="true" />
</Target>
<!--
============================================================
_CleanRecordFileWrites
Save the list of all files written to disk so that it can be used for "Clean" later.
Files written in prior builds are not removed from Clean cache.
============================================================
-->
<Target
Name="_CleanRecordFileWrites"
DependsOnTargets="_CleanGetCurrentAndPriorFileWrites">
<!--
Merge list of files from prior builds with the current build and then
remove duplicates.
-->
<RemoveDuplicates Inputs="@(_CleanPriorFileWrites);@(_CleanCurrentFileWrites)">
<Output TaskParameter="Filtered" ItemName="_CleanUniqueFileWrites"/>
</RemoveDuplicates>
<!-- Make sure the directory exists. -->
<MakeDir Directories="$(IntermediateOutputPath)"/>
<!-- Write merged file list back to disk, replacing existing contents. -->
<WriteLinesToFile
File="$(IntermediateOutputPath)$(CleanFile)"
Lines="@(_CleanUniqueFileWrites)"
Overwrite="true"
WriteOnlyWhenDifferent="true" />
</Target>
<!--
============================================================
CleanPublishFolder
============================================================
-->
<Target
Name="CleanPublishFolder">
<RemoveDir
Directories="$(ClickOncePublishDir)"
Condition="'$(ClickOncePublishDir)'=='$(OutputPath)app.publish\' and Exists('$(ClickOncePublishDir)')"/>
</Target>
<!--
***********************************************************************************************
***********************************************************************************************
PostBuildEvent Section
***********************************************************************************************
***********************************************************************************************
-->
<!--
============================================================
PostBuildEvent
Run the post-build event. This step is driven by two parameters:
(1) The $(RunPostBuildEvent) property is set by the user through the IDE and can be one of four values.
- OnBuildSuccess: In this case, every step of the build must succeed for the post-build step to run.
- <Blank>: This is the same as OnBuildSuccess.
- OnOutputUpdated: In this case, the post-build step will run only if the main output assembly was
actually updated.
- Always: The post-build step is always run.
(2) The $(_AssemblyTimestampBeforeCompile) and $(_AssemblyTimestampAfterCompile) values are
set by the _TimeStampBeforeCompile and _TimeStampAfterCompile targets. If the assembly was actually
rebuilt during this build, then the two values will be different.
============================================================
-->
<PropertyGroup>
<PostBuildEventDependsOn></PostBuildEventDependsOn>
</PropertyGroup>
<Target
Name="PostBuildEvent"
Condition="'$(PostBuildEvent)' != '' and ('$(RunPostBuildEvent)' != 'OnOutputUpdated' or '$(_AssemblyTimestampBeforeCompile)' != '$(_AssemblyTimestampAfterCompile)')"
DependsOnTargets="$(PostBuildEventDependsOn)">
<Exec WorkingDirectory="$(OutDir)" Command="$(PostBuildEvent)" />
</Target>
<!--
***********************************************************************************************
***********************************************************************************************
Publish Section
***********************************************************************************************
***********************************************************************************************
-->
<PropertyGroup>
<DeploymentComputeClickOnceManifestInfoDependsOn>
CleanPublishFolder;
$(_RecursiveTargetForContentCopying);
_DeploymentGenerateTrustInfo
$(DeploymentComputeClickOnceManifestInfoDependsOn)
</DeploymentComputeClickOnceManifestInfoDependsOn>
</PropertyGroup>
<!--
============================================================
Publish
This target is only called when doing ClickOnce publishing outside the IDE, which implicitly builds before publishing.
============================================================
-->
<PropertyGroup>
<PublishDependsOn Condition="'$(PublishableProject)'=='true'">
SetGenerateManifests;
Build;
PublishOnly
</PublishDependsOn>
<PublishDependsOn Condition="'$(PublishableProject)'!='true'">
_DeploymentUnpublishable
</PublishDependsOn>
</PropertyGroup>
<Target
Name="Publish"
DependsOnTargets="$(PublishDependsOn)"/>
<!--
============================================================
_DeploymentUnpublishable
This target is used to block an attempt to ClickOnce publish a non-publishable project, such as a ClassLibrary, when building outside the IDE.
============================================================
-->
<Target
Name="_DeploymentUnpublishable">
<Message Text="Skipping unpublishable project."/>
</Target>
<!--
============================================================
SetGenerateManifests
This target simply assures the GenerateClickOnceManifests property is set whenever the publish target is invoked.
============================================================
-->
<Target
Name="SetGenerateManifests">
<Error Condition="'$(OutputType)'!='winexe' and '$(OutputType)'!='exe' and '$(OutputType)'!='appcontainerexe'" Text="Publish is only valid for 'Windows Application' or 'Console Application' project types."/>
<Error Condition="'$(_DeploymentSignClickOnceManifests)'=='true' and '$(ManifestCertificateThumbprint)'=='' and '$(ManifestKeyFile)'==''" Text="A signing key is required in order to publish this project. Please specify a ManifestKeyFile or ManifestCertificateThumbprint value. Publishing from Visual Studio will automatically configure a signing key for this project."/>
<PropertyGroup>
<GenerateClickOnceManifests>true</GenerateClickOnceManifests>
</PropertyGroup>
</Target>
<!--
============================================================
PublishOnly
The "PublishOnly" target is intended for ClickOnce publishing inside the IDE, where the build has already been done
by the BuildManager.
============================================================
-->
<PropertyGroup>
<PublishOnlyDependsOn>
SetGenerateManifests;
PublishBuild;
BeforePublish;
GenerateManifests;
CopyFilesToOutputDirectory;
_CopyFilesToPublishFolder;
_DeploymentGenerateBootstrapper;
ResolveKeySource;
_DeploymentSignClickOnceDeployment;
AfterPublish
</PublishOnlyDependsOn>
</PropertyGroup>
<Target
Name="PublishOnly"
DependsOnTargets="$(PublishOnlyDependsOn)"/>
<!--
============================================================
BeforePublish
Redefine this target in your project in order to run tasks just before Publish.
============================================================
-->
<Target Name="BeforePublish"/>
<!--
============================================================
AfterPublish
Redefine this target in your project in order to run tasks just after Publish.
============================================================
-->
<Target Name="AfterPublish"/>
<!--
============================================================
PublishBuild
Defines the set of targets that publishing is directly dependent on.
============================================================
-->
<PropertyGroup>
<PublishBuildDependsOn>
BuildOnlySettings;
PrepareForBuild;
ResolveReferences;
PrepareResources;
ResolveKeySource;
GenerateSerializationAssemblies;
CreateSatelliteAssemblies;
</PublishBuildDependsOn>
</PropertyGroup>
<Target
Name="PublishBuild"
DependsOnTargets="$(PublishBuildDependsOn)"/>
<!--
============================================================
_CopyFilesToPublishFolder
============================================================
-->
<Target
Name="_CopyFilesToPublishFolder">
<!-- Compute name of application folder, which includes the assembly name plus formatted application version.
The application version is formatted to use "_" in place of "." chars (i.e. "1_0_0_0" instead of "1.0.0.0").
This is done because some servers misinterpret "." as a file extension. -->
<FormatVersion Version="$(ApplicationVersion)" Revision="$(ApplicationRevision)" FormatType="Path">
<Output TaskParameter="OutputVersion" PropertyName="_DeploymentApplicationVersionFragment"/>
</FormatVersion>
<PropertyGroup>
<_DeploymentApplicationFolderName>Application Files\$(AssemblyName)_$(_DeploymentApplicationVersionFragment)</_DeploymentApplicationFolderName>
<_DeploymentApplicationDir>$(ClickOncePublishDir)$(_DeploymentApplicationFolderName)\</_DeploymentApplicationDir>
</PropertyGroup>
<PropertyGroup>
<!-- By default we're not using Hard or Symbolic Links to copy to the publish directory, and never when building in VS -->
<CreateHardLinksForPublishFilesIfPossible Condition="'$(BuildingInsideVisualStudio)' == 'true' or '$(CreateHardLinksForPublishFilesIfPossible)' == ''">false</CreateHardLinksForPublishFilesIfPossible>
<CreateSymbolicLinksForPublishFilesIfPossible Condition="'$(BuildingInsideVisualStudio)' == 'true' or '$(CreateSymbolicLinksForPublishFilesIfPossible)' == ''">false</CreateSymbolicLinksForPublishFilesIfPossible>
</PropertyGroup>
<!-- Copy files to publish folder -->
<Copy
Condition="'$(PublishSingleFile)' != 'true'"
SourceFiles=
"@(_ApplicationManifestFinal);
@(_DeploymentResolvedManifestEntryPoint);
@(_DeploymentManifestFiles);
@(ReferenceComWrappersToCopyLocal);
@(ResolvedIsolatedComModules);
@(_DeploymentLooseManifestFile)"
DestinationFiles=
"@(_ApplicationManifestFinal->'$(_DeploymentApplicationDir)%(TargetPath)');
@(_DeploymentManifestEntryPoint->'$(_DeploymentApplicationDir)%(TargetPath)$(_DeploymentFileMappingExtension)');
@(_DeploymentManifestFiles->'$(_DeploymentApplicationDir)%(TargetPath)$(_DeploymentFileMappingExtension)');
@(ReferenceComWrappersToCopyLocal->'$(_DeploymentApplicationDir)%(FileName)%(Extension)$(_DeploymentFileMappingExtension)');
@(ResolvedIsolatedComModules->'$(_DeploymentApplicationDir)%(FileName)%(Extension)$(_DeploymentFileMappingExtension)');
@(_DeploymentLooseManifestFile->'$(_DeploymentApplicationDir)%(FileName)%(Extension)$(_DeploymentFileMappingExtension)')"
SkipUnchangedFiles="$(SkipCopyUnchangedFiles)"
OverwriteReadOnlyFiles="$(OverwriteReadOnlyFiles)"
Retries="$(CopyRetryCount)"
UseHardlinksIfPossible="$(CreateHardLinksForPublishFilesIfPossible)"
UseSymboliclinksIfPossible="$(CreateSymbolicLinksForPublishFilesIfPossible)"
RetryDelayMilliseconds="$(CopyRetryDelayMilliseconds)"/>
<Copy
SourceFiles="@(_DeploymentManifestDependencies)"
DestinationFiles="@(_DeploymentManifestDependencies->'$(_DeploymentApplicationDir)%(TargetPath)$(_DeploymentFileMappingExtension)')"
SkipUnchangedFiles="$(SkipCopyUnchangedFiles)"
OverwriteReadOnlyFiles="$(OverwriteReadOnlyFiles)"
Retries="$(CopyRetryCount)"
RetryDelayMilliseconds="$(CopyRetryDelayMilliseconds)"
UseHardlinksIfPossible="$(CreateHardLinksForPublishFilesIfPossible)"
UseSymboliclinksIfPossible="$(CreateSymbolicLinksForPublishFilesIfPossible)"
Condition="'$(PublishSingleFile)' != 'true' and '%(_DeploymentManifestDependencies.DependencyType)'=='Install'"/>
<Copy
Condition="'$(PublishSingleFile)' != 'true'"
SourceFiles="@(_ReferenceScatterPaths)"
DestinationFiles="@(_ReferenceScatterPaths->'$(_DeploymentApplicationDir)%(Filename)%(Extension)$(_DeploymentFileMappingExtension)')"
SkipUnchangedFiles="$(SkipCopyUnchangedFiles)"
OverwriteReadOnlyFiles="$(OverwriteReadOnlyFiles)"
Retries="$(CopyRetryCount)"
RetryDelayMilliseconds="$(CopyRetryDelayMilliseconds)"
UseHardlinksIfPossible="$(CreateHardLinksForPublishFilesIfPossible)"
UseSymboliclinksIfPossible="$(CreateSymbolicLinksForPublishFilesIfPossible)"
/>
<ItemGroup Condition="'$(PublishSingleFile)' == 'true'">
<PublishedSingleFileToBeCopied Include="@(_DeploymentManifestFiles)"/>
</ItemGroup>
<!-- For single-file publish case, we need to only copy the clickonce manifest, manifest entry point (launcher) and the SF EXE -->
<Copy
Condition="'$(PublishSingleFile)' == 'true'"
SourceFiles=
"@(_ApplicationManifestFinal);
@(_DeploymentResolvedManifestEntryPoint);
@(PublishedSingleFileToBeCopied);"
DestinationFiles=
"@(_ApplicationManifestFinal->'$(_DeploymentApplicationDir)%(TargetPath)');
@(_DeploymentManifestEntryPoint->'$(_DeploymentApplicationDir)%(TargetPath)$(_DeploymentFileMappingExtension)');
@(PublishedSingleFileToBeCopied->'$(_DeploymentApplicationDir)%(TargetPath)$(_DeploymentFileMappingExtension)')"
SkipUnchangedFiles="$(SkipCopyUnchangedFiles)"
OverwriteReadOnlyFiles="$(OverwriteReadOnlyFiles)"
Retries="$(CopyRetryCount)"
UseHardlinksIfPossible="$(CreateHardLinksForPublishFilesIfPossible)"
UseSymboliclinksIfPossible="$(CreateSymbolicLinksForPublishFilesIfPossible)"
RetryDelayMilliseconds="$(CopyRetryDelayMilliseconds)"/>
<FormatUrl InputUrl="$(_DeploymentApplicationUrl)">
<Output TaskParameter="OutputUrl" PropertyName="_DeploymentFormattedApplicationUrl"/>
</FormatUrl>
<FormatUrl InputUrl="$(_DeploymentComponentsUrl)">
<Output TaskParameter="OutputUrl" PropertyName="_DeploymentFormattedComponentsUrl"/>
</FormatUrl>
</Target>
<!--
============================================================
_DeploymentGenerateBootstrapper
============================================================
-->
<Target
Name="_DeploymentGenerateBootstrapper">
<!-- Build setup.exe bootstrapper and copy referenced packages -->
<GenerateBootstrapper
ApplicationFile="$(TargetDeployManifestFileName)"
ApplicationName="$(AssemblyName)"
ApplicationUrl="$(_DeploymentFormattedApplicationUrl)"
BootstrapperItems="@(BootstrapperPackage)"
ComponentsLocation="$(BootstrapperComponentsLocation)"
ComponentsUrl="$(_DeploymentFormattedComponentsUrl)"
Culture="$(TargetCulture)"
FallbackCulture="$(FallbackCulture)"
OutputPath="$(ClickOncePublishDir)"
SupportUrl="$(_DeploymentFormattedSupportUrl)"
Path="$(GenerateBootstrapperSdkPath)"
VisualStudioVersion="$(VisualStudioVersion)"
Condition="'$(BootstrapperEnabled)'=='true'"/>
</Target>
<!--
============================================================
_DeploymentSignClickOnceDeployment
============================================================
-->
<Target
Name="_DeploymentSignClickOnceDeployment">
<!-- Sign manifests and the bootstrapper -->
<SignFile
CertificateThumbprint="$(_DeploymentResolvedManifestCertificateThumbprint)"
TimestampUrl="$(ManifestTimestampUrl)"
SigningTarget="$(_DeploymentApplicationDir)$(_DeploymentTargetApplicationManifestFileName)"
TargetFrameworkIdentifier="$(TargetFrameworkIdentifier)"
TargetFrameworkVersion="$(TargetFrameworkVersion)"
DisallowMansignTimestampFallback="$(DisallowMansignTimestampFallback)"
Condition="'$(_DeploymentSignClickOnceManifests)'=='true'" />
<!-- Update entry point path in deploy manifest -->
<UpdateManifest
ApplicationPath="$(_DeploymentApplicationFolderName)\$(_DeploymentTargetApplicationManifestFileName)"
TargetFrameworkVersion="$(_DeploymentManifestTargetFrameworkVersion)"
ApplicationManifest="$(_DeploymentApplicationDir)$(_DeploymentTargetApplicationManifestFileName)"
InputManifest="$(OutDir)$(TargetDeployManifestFileName)"
OutputManifest="$(ClickOncePublishDir)$(TargetDeployManifestFileName)">
<Output TaskParameter="OutputManifest" ItemName="PublishedDeployManifest"/>
</UpdateManifest>
<SignFile
CertificateThumbprint="$(_DeploymentResolvedManifestCertificateThumbprint)"
TimestampUrl="$(ManifestTimestampUrl)"
SigningTarget="$(ClickOncePublishDir)$(TargetDeployManifestFileName)"
TargetFrameworkIdentifier="$(TargetFrameworkIdentifier)"
TargetFrameworkVersion="$(TargetFrameworkVersion)"
DisallowMansignTimestampFallback="$(DisallowMansignTimestampFallback)"
Condition="'$(_DeploymentSignClickOnceManifests)'=='true'" />
<SignFile
CertificateThumbprint="$(_DeploymentResolvedManifestCertificateThumbprint)"
TimestampUrl="$(ManifestTimestampUrl)"
SigningTarget="$(ClickOncePublishDir)setup.exe"
Condition="'$(BootstrapperEnabled)'=='true' and '$(_DeploymentSignClickOnceManifests)'=='true'" />
</Target>
<!--
***********************************************************************************************
***********************************************************************************************
AllProjectOutputGroups Section
***********************************************************************************************
***********************************************************************************************
-->
<!--
============================================================
AllProjectOutputGroups
The targets below drive output groups, which provide generic information about a
project's inputs (e.g., content files, compilation sources, etc.) and built outputs
(e.g., built EXE/DLL, PDB, XML documentation files, etc.)
Each target may produce two kinds of items: outputs and dependencies. Outputs are
items from the current project; dependencies are items that are brought into the
current project as a result of referencing other projects or components.
For both outputs and dependencies, the Include attribute
specifies the location of the output/dependency; it must be a full path. Any number
of additional attributes may be placed on an output/dependency item.
============================================================
-->
<Target
Name="AllProjectOutputGroups"
DependsOnTargets="
BuiltProjectOutputGroup;
DebugSymbolsProjectOutputGroup;
DocumentationProjectOutputGroup;
SatelliteDllsProjectOutputGroup;
SourceFilesProjectOutputGroup;
ContentFilesProjectOutputGroup;
SGenFilesOutputGroup"/>
<!--
This is the key output for the BuiltProjectOutputGroup and is meant to be read directly from the IDE.
Reading an item is faster than invoking a target.
-->
<ItemGroup Condition=" '$(OutputType)' != 'winmdobj' ">
<BuiltProjectOutputGroupKeyOutput Include="@(IntermediateAssembly->'%(FullPath)')">
<IsKeyOutput>true</IsKeyOutput>
<FinalOutputPath>$(TargetPath)</FinalOutputPath>
<TargetPath>$(TargetFileName)</TargetPath>
<COM2REG Condition="'$(RegisterForComInterop)'=='true' and '$(OutputType)'=='library'">true</COM2REG>
</BuiltProjectOutputGroupKeyOutput>
</ItemGroup>
<ItemGroup Condition=" '$(OutputType)' == 'winmdobj' ">
<WinMDExpOutputWindowsMetadataFileItem Include="$(_IntermediateWindowsMetadataPath)" Condition="'$(_IntermediateWindowsMetadataPath)' != ''" />
<BuiltProjectOutputGroupKeyOutput Include="@(WinMDExpOutputWindowsMetadataFileItem->'%(FullPath)')">
<IsKeyOutput>true</IsKeyOutput>
<FinalOutputPath>$(TargetPath)</FinalOutputPath>
<TargetPath>$(TargetFileName)</TargetPath>
</BuiltProjectOutputGroupKeyOutput>
</ItemGroup>
<!--
============================================================
BuiltProjectOutputGroup
============================================================
-->
<PropertyGroup>
<BuiltProjectOutputGroupDependsOn>PrepareForBuild</BuiltProjectOutputGroupDependsOn>
<AddAppConfigToBuildOutputs Condition="('$(AddAppConfigToBuildOutputs)'=='') and ('$(OutputType)'!='library' and '$(OutputType)'!='winmdobj')">true</AddAppConfigToBuildOutputs>
</PropertyGroup>
<Target
Name="BuiltProjectOutputGroup"
Returns="@(BuiltProjectOutputGroupOutput)"
DependsOnTargets="$(BuiltProjectOutputGroupDependsOn)">
<ItemGroup>
<_BuiltProjectOutputGroupOutputIntermediate Include="@(BuiltProjectOutputGroupKeyOutput)"/>
</ItemGroup>
<!-- This item represents the app.config file -->
<ItemGroup>
<_BuiltProjectOutputGroupOutputIntermediate Include="$(AppConfig)" Condition="'$(AddAppConfigToBuildOutputs)'=='true'">
<FinalOutputPath>$(TargetDir)$(TargetFileName).config</FinalOutputPath>
<TargetPath>$(TargetFileName).config</TargetPath>
<!-- For compatibility with 2.0 -->
<OriginalItemSpec>$(AppConfig)</OriginalItemSpec>
</_BuiltProjectOutputGroupOutputIntermediate>
</ItemGroup>
<ItemGroup>
<_IsolatedComReference Include="@(COMReference)" Condition=" '%(COMReference.Isolated)' == 'true' "/>
<_IsolatedComReference Include="@(COMFileReference)" Condition=" '%(COMFileReference.Isolated)' == 'true' "/>
</ItemGroup>
<!-- This item represents the native manifest, example: WindowsApplication1.exe.manifest or Native.ClassLibrary1.manifest -->
<ItemGroup>
<_BuiltProjectOutputGroupOutputIntermediate Include="$(OutDir)$(_DeploymentTargetApplicationManifestFileName)" Condition="('@(NativeReference)'!='' or '@(_IsolatedComReference)'!='') And Exists('$(OutDir)$(_DeploymentTargetApplicationManifestFileName)')">
<TargetPath>$(_DeploymentTargetApplicationManifestFileName)</TargetPath>
<!-- For compatibility with 2.0 -->
<OriginalItemSpec>$(OutDir)$(_DeploymentTargetApplicationManifestFileName)</OriginalItemSpec>
</_BuiltProjectOutputGroupOutputIntermediate>
</ItemGroup>
<!-- Convert intermediate items into final items; this way we can get the full path for each item -->
<ItemGroup>
<BuiltProjectOutputGroupOutput Include="@(_BuiltProjectOutputGroupOutputIntermediate->'%(FullPath)')">
<!-- For compatibility with 2.0 -->
<OriginalItemSpec Condition="'%(_BuiltProjectOutputGroupOutputIntermediate.OriginalItemSpec)' == ''">%(_BuiltProjectOutputGroupOutputIntermediate.FullPath)</OriginalItemSpec>
</BuiltProjectOutputGroupOutput>
</ItemGroup>
</Target>
<!--
============================================================
DebugSymbolsProjectOutputGroup
This target performs population of the Debug Symbols project output group.
============================================================
-->
<PropertyGroup>
<DebugSymbolsProjectOutputGroupDependsOn></DebugSymbolsProjectOutputGroupDependsOn>
</PropertyGroup>
<ItemGroup Condition="'$(_DebugSymbolsProduced)' != 'false' and '$(OutputType)' != 'winmdobj'">
<DebugSymbolsProjectOutputGroupOutput Include="@(_DebugSymbolsIntermediatePath->'%(FullPath)')">
<FinalOutputPath>@(_DebugSymbolsOutputPath->'%(FullPath)')</FinalOutputPath>
<TargetPath>@(_DebugSymbolsIntermediatePath->'%(Filename)%(Extension)')</TargetPath>
</DebugSymbolsProjectOutputGroupOutput>
</ItemGroup>
<ItemGroup Condition="'$(_DebugSymbolsProduced)' != 'false' and '$(OutputType)' == 'winmdobj'">
<WinMDExpOutputPdbItem Include="$(WinMDExpOutputPdb)" Condition="'$(WinMDExpOutputPdb)' != ''" />
<WinMDExpFinalOutputPdbItem Include="$(_WinMDDebugSymbolsOutputPath)" Condition="'$(_WinMDDebugSymbolsOutputPath)' != ''" />
<DebugSymbolsProjectOutputGroupOutput Include="@(WinMDExpOutputPdbItem->'%(FullPath)')">
<FinalOutputPath>@(WinMDExpFinalOutputPdbItem->'%(FullPath)')</FinalOutputPath>
<TargetPath>@(WinMDExpOutputPdbItem->'%(Filename)%(Extension)')</TargetPath>
</DebugSymbolsProjectOutputGroupOutput>
</ItemGroup>
<Target
Name="DebugSymbolsProjectOutputGroup"
Returns="@(DebugSymbolsProjectOutputGroupOutput)"
DependsOnTargets="$(DebugSymbolsProjectOutputGroupDependsOn)"/>
<!--
============================================================
DocumentationProjectOutputGroup
This target performs population of the Documentation project output group.
============================================================
-->
<PropertyGroup>
<DocumentationProjectOutputGroupDependsOn></DocumentationProjectOutputGroupDependsOn>
</PropertyGroup>
<ItemGroup Condition="'$(DocumentationFile)'!='' and '$(OutputType)' != 'winmdobj'">
<DocumentationProjectOutputGroupOutput Include="@(DocFileItem->'%(FullPath)')">
<FinalOutputPath>@(FinalDocFile->'%(FullPath)')</FinalOutputPath>
<IsKeyOutput>true</IsKeyOutput>
<TargetPath>@(DocFileItem->'%(Filename)%(Extension)')</TargetPath>
</DocumentationProjectOutputGroupOutput>
</ItemGroup>
<ItemGroup Condition="'$(DocumentationFile)' != '' and '$(OutputType)' == 'winmdobj'">
<WinMDOutputDocumentationFileItem Include="$(WinMDOutputDocumentationFile)" Condition="'$(WinMDOutputDocumentationFile)' != ''" />
<WinMDExpFinalOutputDocItem Include="$(_WinMDDocFileOutputPath)" Condition="'$(_WinMDDocFileOutputPath)' != ''" />
<DocumentationProjectOutputGroupOutput Include="@(WinMDOutputDocumentationFileItem->'%(FullPath)')">
<FinalOutputPath>@(WinMDExpFinalOutputDocItem->'%(FullPath)')</FinalOutputPath>
<TargetPath>@(WinMDOutputDocumentationFileItem->'%(Filename)%(Extension)')</TargetPath>
</DocumentationProjectOutputGroupOutput>
</ItemGroup>
<Target
Name="DocumentationProjectOutputGroup"
Returns="@(DocumentationProjectOutputGroupOutput)"
DependsOnTargets="$(DocumentationProjectOutputGroupDependsOn)"/>
<!--
============================================================
SatelliteDllsProjectOutputGroup
This target performs population of the Satellite Files project output group.
============================================================
-->
<PropertyGroup>
<SatelliteDllsProjectOutputGroupDependsOn>$(SatelliteDllsProjectOutputGroupDependsOn);PrepareForBuild;PrepareResourceNames</SatelliteDllsProjectOutputGroupDependsOn>
</PropertyGroup>
<Target
Name="SatelliteDllsProjectOutputGroup"
Returns="@(SatelliteDllsProjectOutputGroupOutput)"
DependsOnTargets="$(SatelliteDllsProjectOutputGroupDependsOn)">
<ItemGroup>
<SatelliteDllsProjectOutputGroupOutputIntermediate Include="$(IntermediateOutputPath)%(EmbeddedResource.Culture)\$(TargetName).resources.dll"
Condition="'%(EmbeddedResource.WithCulture)' == 'true'">
<TargetPath>%(EmbeddedResource.Culture)\$(TargetName).resources.dll</TargetPath>
<Culture>%(EmbeddedResource.Culture)</Culture>
</SatelliteDllsProjectOutputGroupOutputIntermediate>
</ItemGroup>
<!-- Convert intermediate items into final items; this way we can get the full path for each item. -->
<ItemGroup>
<SatelliteDllsProjectOutputGroupOutput Include="@(SatelliteDllsProjectOutputGroupOutputIntermediate->'%(FullPath)')">
<FinalOutputPath Condition=" '%(SatelliteDllsProjectOutputGroupOutputIntermediate.FinalOutputPath)' == '' ">$(TargetDir)%(SatelliteDllsProjectOutputGroupOutputIntermediate.TargetPath)</FinalOutputPath>
<!-- For compatibility with 2.0 -->
<OriginalItemSpec>%(SatelliteDllsProjectOutputGroupOutputIntermediate.Identity)</OriginalItemSpec>
</SatelliteDllsProjectOutputGroupOutput>
</ItemGroup>
</Target>
<!--
============================================================
SourceFilesProjectOutputGroup
This target performs population of the Source Files project output group.
Source files are items in the project whose type is "Compile" and "EmbeddedResource".
============================================================
-->
<PropertyGroup>
<SourceFilesProjectOutputGroupDependsOn>PrepareForBuild;AssignTargetPaths</SourceFilesProjectOutputGroupDependsOn>
</PropertyGroup>
<Target
Name="SourceFilesProjectOutputGroup"
Returns="@(SourceFilesProjectOutputGroupOutput)"
DependsOnTargets="$(SourceFilesProjectOutputGroupDependsOn)">
<AssignTargetPath Files="@(Compile)" RootFolder="$(MSBuildProjectDirectory)">
<Output TaskParameter="AssignedFiles" ItemName="_CompileWithTargetPath" />
</AssignTargetPath>
<ItemGroup>
<!-- First we deal with Compile, EmbeddedResource and AppConfig -->
<SourceFilesProjectOutputGroupOutput Include="@(_CompileWithTargetPath->'%(FullPath)');@(EmbeddedResource->'%(FullPath)');@(_LicxFile->'%(FullPath)');@(AppConfigWithTargetPath->'%(FullPath)')"/>
<!-- Include the project file -->
<SourceFilesProjectOutputGroupOutput Include="$(MSBuildProjectFullPath)">
<!-- For compatibility with 2.0 -->
<OriginalItemSpec>$(MSBuildProjectFullPath)</OriginalItemSpec>
<TargetPath>$(ProjectFileName)</TargetPath>
</SourceFilesProjectOutputGroupOutput>
</ItemGroup>
</Target>
<!-- Get just the compile items -->
<Target Name="GetCompile" Returns="@(Compile)"/>
<!--
============================================================
ContentFilesProjectOutputGroup
This target performs population of the Content Files project output group.
Content files are items in the project whose type is "Content".
============================================================
-->
<PropertyGroup>
<ContentFilesProjectOutputGroupDependsOn>PrepareForBuild;AssignTargetPaths</ContentFilesProjectOutputGroupDependsOn>
</PropertyGroup>
<Target
Name="ContentFilesProjectOutputGroup"
Returns="@(ContentFilesProjectOutputGroupOutput)"
DependsOnTargets="$(ContentFilesProjectOutputGroupDependsOn)">
<!-- Convert items into final items; this way we can get the full path for each item. -->
<ItemGroup>
<ContentFilesProjectOutputGroupOutput Include="@(ContentWithTargetPath->'%(FullPath)')"/>
</ItemGroup>
</Target>
<!--
============================================================
SGenFilesOutputGroup
This target performs population of the GenerateSerializationAssemblies Files project output group.
GenerateSerializationAssemblies files are those generated by the GenerateSerializationAssemblies target and task.
============================================================
-->
<PropertyGroup>
<SGenFilesOutputGroupDependsOn></SGenFilesOutputGroupDependsOn>
</PropertyGroup>
<ItemGroup
Condition="'$(_SGenGenerateSerializationAssembliesConfig)' == 'On' or ('@(WebReferenceUrl)'!='' and '$(_SGenGenerateSerializationAssembliesConfig)' == 'Auto')">
<SGenFilesOutputGroupOutput Include="@(_OutputPathItem->'%(FullPath)$(_SGenDllName)')">
<FinalOutputPath>@(_OutputPathItem->'%(FullPath)$(_SGenDllName)')</FinalOutputPath>
<TargetPath>$(_SGenDllName)</TargetPath>
</SGenFilesOutputGroupOutput>
</ItemGroup>
<Target
Name="SGenFilesOutputGroup"
Returns="@(SGenFilesOutputGroupOutput)"
DependsOnTargets="$(SGenFilesOutputGroupDependsOn)"/>
<!--
============================================================
SDKRelated Output groups
These targets are to gather information from the SDKs.
============================================================
-->
<!-- Get the resolved SDK reference items -->
<Target Name="GetResolvedSDKReferences" DependsOnTargets="ResolveSDKReferences" Returns="@(ResolvedSDKReference)"/>
<!-- Target will return no results by default but will be populated by other targets elsewhere.
Needed for certain build environments that import partial sets of targets. -->
<Target Name="CollectReferencedNuGetPackages" Returns="@(ReferencedNuGetPackages)"/>
<!-- Get the TargetFrameworks that are supported for the Visual Studio TargetFramework drop down -->
<Target Name="GenerateSupportedTargetFrameworkAlias" Returns="@(SupportedTargetFrameworkAlias)"/>
<!--
============================================================
PriFilesOutputGroup
This target performs population of the pri files output group
============================================================
-->
<Target
Name="PriFilesOutputGroup"
Condition="'@(_ReferenceRelatedPaths)' != ''"
DependsOnTargets="BuildOnlySettings;PrepareForBuild;AssignTargetPaths;ResolveReferences"
Returns="@(PriFilesOutputGroupOutput)">
<!-- This item represents dependent pri file's -->
<ItemGroup>
<PriFilesOutputGroupOutput Include="@(_ReferenceRelatedPaths->'%(FullPath)')" Condition="'%(Extension)' == '.pri'"/>
</ItemGroup>
</Target>
<PropertyGroup>
<SDKRedistOutputGroupDependsOn>ResolveSDKReferences;ExpandSDKReferences</SDKRedistOutputGroupDependsOn>
</PropertyGroup>
<!--
============================================================
SDKRedistOutputGroup
This target gathers the Redist folders from the SDKs which have been resolved.
============================================================
-->
<Target
Name="SDKRedistOutputGroup"
Returns="@(SDKRedistOutputGroupOutput)"
DependsOnTargets="$(SDKRedistOutputGroupDependsOn)">
<!-- This list starts with the least specific files to the most specific so that later files can overwrite earlier files-->
<ItemGroup>
<SDKRedistOutputGroupOutput Include="@(ResolvedRedistFiles)"/>
</ItemGroup>
</Target>
<!--
***********************************************************************************************
***********************************************************************************************
AllProjectOutputGroupsDependencies Section
***********************************************************************************************
***********************************************************************************************
-->
<!--
============================================================
CommonOutputGroupsDependsOn
Dependencies common to many of the *OutputGroupDependencies targets.
============================================================
-->
<PropertyGroup>
<CommonOutputGroupsDependsOn>
$(CommonOutputGroupsDependsOn);
BuildOnlySettings;
PrepareForBuild;
AssignTargetPaths;
ResolveReferences
</CommonOutputGroupsDependsOn>
</PropertyGroup>
<!--
============================================================
AllProjectOutputGroupsDependencies
============================================================
-->
<Target
Name="AllProjectOutputGroupsDependencies"
DependsOnTargets="
BuiltProjectOutputGroupDependencies;
DebugSymbolsProjectOutputGroupDependencies;
SatelliteDllsProjectOutputGroupDependencies;
DocumentationProjectOutputGroupDependencies;
SGenFilesOutputGroupDependencies"/>
<!--
============================================================
BuiltProjectOutputGroupDependencies
This target performs population of the Built project output group dependencies.
============================================================
-->
<PropertyGroup>
<BuiltProjectOutputGroupDependenciesDependsOn>
$(BuiltProjectOutputGroupDependenciesDependsOn);
$(CommonOutputGroupsDependsOn)
</BuiltProjectOutputGroupDependenciesDependsOn>
</PropertyGroup>
<Target
Name="BuiltProjectOutputGroupDependencies"
DependsOnTargets="$(BuiltProjectOutputGroupDependenciesDependsOn)"
Returns="@(BuiltProjectOutputGroupDependency)">
<ItemGroup>
<BuiltProjectOutputGroupDependency Include="@(ReferencePath->'%(FullPath)');
@(ReferenceDependencyPaths->'%(FullPath)');
@(NativeReferenceFile->'%(FullPath)');
@(_DeploymentLooseManifestFile->'%(FullPath)');
@(ResolvedIsolatedComModules->'%(FullPath)')"/>
</ItemGroup>
</Target>
<!--
============================================================
DebugSymbolsProjectOutputGroupDependencies
This target performs population of the dependencies for the debug symbols project output group.
============================================================
-->
<PropertyGroup>
<DebugSymbolsProjectOutputGroupDependenciesDependsOn>
$(DebugSymbolsProjectOutputGroupDependenciesDependsOn);
$(CommonOutputGroupsDependsOn)
</DebugSymbolsProjectOutputGroupDependenciesDependsOn>
</PropertyGroup>
<Target
Name="DebugSymbolsProjectOutputGroupDependencies"
Condition="'$(DebugSymbols)'!='false'"
DependsOnTargets="$(DebugSymbolsProjectOutputGroupDependenciesDependsOn)"
Returns="@(DebugSymbolsProjectOutputGroupDependency)">
<!-- This item represents dependent PDB's -->
<ItemGroup>
<DebugSymbolsProjectOutputGroupDependency Include="@(_ReferenceRelatedPaths->'%(FullPath)')" Condition="'%(Extension)' == '.pdb'"/>
</ItemGroup>
</Target>
<!--
============================================================
SatelliteDllsProjectOutputGroupDependencies
This target performs population of the dependencies for the satellite files project output group.
============================================================
-->
<PropertyGroup>
<SatelliteDllsProjectOutputGroupDependenciesDependsOn>
$(SatelliteDllsProjectOutputGroupDependenciesDependsOn);
$(CommonOutputGroupsDependsOn)
</SatelliteDllsProjectOutputGroupDependenciesDependsOn>
</PropertyGroup>
<Target
Name="SatelliteDllsProjectOutputGroupDependencies"
DependsOnTargets="$(SatelliteDllsProjectOutputGroupDependenciesDependsOn)"
Returns="@(SatelliteDllsProjectOutputGroupDependency)">
<!-- This item represents dependent satellites -->
<ItemGroup>
<SatelliteDllsProjectOutputGroupDependency Include="@(ReferenceSatellitePaths->'%(FullPath)')"/>
</ItemGroup>
</Target>
<!--
============================================================
DocumentationProjectOutputGroupDependencies
This target performs population of the dependencies for the documentation project output group.
============================================================
-->
<PropertyGroup>
<DocumentationProjectOutputGroupDependenciesDependsOn>
$(DocumentationProjectOutputGroupDependenciesDependsOn);
$(CommonOutputGroupsDependsOn)
</DocumentationProjectOutputGroupDependenciesDependsOn>
</PropertyGroup>
<Target
Name="DocumentationProjectOutputGroupDependencies"
Condition="'$(DocumentationFile)'!=''"
DependsOnTargets="$(DocumentationProjectOutputGroupDependenciesDependsOn)"
Returns="@(DocumentationProjectOutputGroupDependency)">
<!-- This item represents dependent XMLs -->
<ItemGroup>
<DocumentationProjectOutputGroupDependency Include="@(_ReferenceRelatedPaths->'%(FullPath)')" Condition="'%(Extension)' == '.xml'"/>
</ItemGroup>
</Target>
<!--
============================================================
SGenFilesOutputGroupDependencies
This target performs population of the dependencies for the GenerateSerializationAssemblies project output group.
============================================================
-->
<PropertyGroup>
<SGenFilesOutputGroupDependenciesDependsOn>
$(SGenFilesOutputGroupDependenciesDependsOn);
$(CommonOutputGroupsDependsOn)
</SGenFilesOutputGroupDependenciesDependsOn>
</PropertyGroup>
<Target
Name="SGenFilesOutputGroupDependencies"
DependsOnTargets="$(SGenFilesOutputGroupDependenciesDependsOn)"
Returns="@(SGenFilesOutputGroupDependency)">
<!-- This item represents sgen xml serializer dll's -->
<ItemGroup>
<SGenFilesOutputGroupDependency Include="@(_ReferenceSerializationAssemblyPaths->'%(FullPath)')" Condition="'%(Extension)' == '.dll'"/>
</ItemGroup>
</Target>
<!--
============================================================
ReferenceCopyLocalPathsOutputGroup
Exposes the set of items that should be copied locally based on the project's references.
============================================================
-->
<PropertyGroup>
<ReferenceCopyLocalPathsOutputGroupDependsOn>
$(ReferenceCopyLocalPathsOutputGroupDependsOn);
$(CommonOutputGroupsDependsOn)
</ReferenceCopyLocalPathsOutputGroupDependsOn>
</PropertyGroup>
<Target
Name="ReferenceCopyLocalPathsOutputGroup"
DependsOnTargets="$(ReferenceCopyLocalPathsOutputGroupDependsOn)"
Returns="@(ReferenceCopyLocalPathsOutputGroupOutput)">
<ItemGroup>
<ReferenceCopyLocalPathsOutputGroupOutput Include="@(ReferenceCopyLocalPaths)">
<TargetPath>%(ReferenceCopyLocalPaths.DestinationSubDirectory)%(ReferenceCopyLocalPaths.Filename)%(ReferenceCopyLocalPaths.Extension)</TargetPath>
</ReferenceCopyLocalPathsOutputGroupOutput>
</ItemGroup>
</Target>
<!--
============================================================
DesignerRuntimeImplementationProjectOutputGroup
Exposes build items to be used by designer. The default is empty, but
SDKs can override it as appropriate. The empty stub is required so that
the project system can always rely on calling it even if it is not
overridden.
============================================================
-->
<PropertyGroup>
<DesignerRuntimeImplementationProjectOutputGroupDependsOn>
$(DesignerRuntimeImplementationProjectOutputGroupDependsOn);
$(CommonOutputGroupsDependsOn)
</DesignerRuntimeImplementationProjectOutputGroupDependsOn>
</PropertyGroup>
<Target
Name="DesignerRuntimeImplementationProjectOutputGroup"
DependsOnTargets="$(DesignerRuntimeImplementationProjectOutputGroupDependsOn)"
Returns="@(DesignerRuntimeImplementationProjectOutputGroupOutput)">
</Target>
<!--
============================================================
.editorconfig support
============================================================
-->
<!-- Expose the set of potential .editorconfig files so the project system can
retrieve them. -->
<Target Name="GetPotentialEditorConfigFiles" Returns="@(PotentialEditorConfigFiles)" />
<PropertyGroup>
<CodeAnalysisTargets Condition="'$(CodeAnalysisTargets)'==''">$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\CodeAnalysis\Microsoft.CodeAnalysis.targets</CodeAnalysisTargets>
</PropertyGroup>
<Import Project="$(CodeAnalysisTargets)" Condition="Exists('$(CodeAnalysisTargets)')"/>
<Import Project="$(ReportingServicesTargets)" Condition="Exists('$(ReportingServicesTargets)')"/>
<Import Project="$(MSBuildToolsPath)\Microsoft.NETFramework.targets" Condition="('$(TargetFrameworkIdentifier)' == '' or '$(TargetFrameworkIdentifier)' == '.NETFramework') and ('$(TargetRuntime)' == 'Managed')"/>
<PropertyGroup>
<ImportXamlTargets Condition="'$(ImportXamlTargets)'=='' and ('$(TargetFrameworkVersion)' != 'v2.0' and '$(TargetFrameworkVersion)' != 'v3.5') and Exists('$(MSBuildToolsPath)\Microsoft.Xaml.targets')">true</ImportXamlTargets>
</PropertyGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.Xaml.targets" Condition="('$(ImportXamlTargets)' == 'true')" />
<!-- imports Microsoft.WorkflowBuildExtensions.targets only if TargetFrameworkVersion is v4.5 or above or TargetFrameworkfVersion specified does not conform to the format of vX.X[.X.X] -->
<!-- Underlying assumption is that there shouldn't be any other versions between v4.0.* and v4.5 -->
<Import Project="$(MSBuildToolsPath)\Microsoft.WorkflowBuildExtensions.targets"
Condition="('$(TargetFrameworkVersion)' != 'v2.0' and '$(TargetFrameworkVersion)' != 'v3.5' and (!$([System.String]::IsNullOrEmpty('$(TargetFrameworkVersion)')) and !$(TargetFrameworkVersion.StartsWith('v4.0')))) and Exists('$(MSBuildToolsPath)\Microsoft.WorkflowBuildExtensions.targets')"/>
<!-- This import is temporary and will be removed once it is moved into the silverlight targets -->
<Import Project="$(MSBuildToolsPath)\Microsoft.WinFX.targets" Condition="'$(TargetFrameworkIdentifier)' == 'Silverlight' and Exists('$(MSBuildToolsPath)\Microsoft.WinFX.targets')"/>
<PropertyGroup>
<MsTestToolsTargets Condition="'$(MsTestToolsTargets)'==''">$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\TeamTest\Microsoft.TeamTest.targets</MsTestToolsTargets>
</PropertyGroup>
<Import Project="$(MsTestToolsTargets)" Condition="Exists('$(MsTestToolsTargets)')" />
<PropertyGroup>
<UseMSBuildTestInfrastructure Condition="'$(UseMSBuildTestInfrastructure)' == ''">false</UseMSBuildTestInfrastructure>
</PropertyGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.Common.Test.targets" Condition="'$(UseMSBuildTestInfrastructure)' == 'true'"/>
<!-- App packaging support -->
<!--
Following two targets are needed to be present in every project being built
because the app packaging targets recursively scan all projects referenced
from projects that generate app packages for them.
-->
<Target Name="CleanAppxPackage" />
<Target Name="GetPackagingOutputs" />
<PropertyGroup>
<MsAppxPackageTargets Condition="'$(MsAppxPackageTargets)'==''">$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\AppxPackage\Microsoft.AppXPackage.Targets</MsAppxPackageTargets>
</PropertyGroup>
<Import Project="$(MsAppxPackageTargets)" Condition="'$(WindowsAppContainer)' == 'true' and Exists('$(MsAppxPackageTargets)')" />
<!-- This import is temporary and will be removed once it is moved into the silverlight targets -->
<Import Project="$(MSBuildToolsPath)\Microsoft.Data.Entity.targets" Condition="'$(TargetFrameworkIdentifier)' == 'Silverlight' and Exists('$(MSBuildToolsPath)\Microsoft.Data.Entity.targets')"/>
<!-- Import NuGet.targets (required for GetReferenceNearestTargetFrameworkTask and used for Restore functionality) -->
<PropertyGroup>
<MSBuildUseVisualStudioDirectoryLayout Condition="'$(MSBuildUseVisualStudioDirectoryLayout)'==''">$([MSBuild]::IsRunningFromVisualStudio())</MSBuildUseVisualStudioDirectoryLayout>
<NuGetRestoreTargets Condition="'$(NuGetRestoreTargets)'=='' and '$(MSBuildUseVisualStudioDirectoryLayout)'=='true'">$([MSBuild]::GetToolsDirectory32())\..\..\..\Common7\IDE\CommonExtensions\Microsoft\NuGet\NuGet.targets</NuGetRestoreTargets>
<NuGetRestoreTargets Condition="'$(NuGetRestoreTargets)'==''">$(MSBuildToolsPath)\NuGet.targets</NuGetRestoreTargets>
</PropertyGroup>
<Import Condition="'$(IsRestoreTargetsFileLoaded)' != 'true' and Exists('$(NuGetRestoreTargets)')" Project="$(NuGetRestoreTargets)" />
<Import Project="$(CustomAfterMicrosoftCommonTargets)" Condition="'$(CustomAfterMicrosoftCommonTargets)' != '' and Exists('$(CustomAfterMicrosoftCommonTargets)')"/>
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.targets\ImportAfter\*" Condition="'$(ImportByWildcardAfterMicrosoftCommonTargets)' == 'true' and exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.targets\ImportAfter')"/>
<Import Project="$(MSBuildUserExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.targets\ImportAfter\*" Condition="'$(ImportUserLocationsByWildcardAfterMicrosoftCommonTargets)' == 'true' and exists('$(MSBuildUserExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.targets\ImportAfter')"/>
</Project>
|