Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
Comment: | Skip copying native files to the test binary directory when not running on the default platform. |
---|---|
Downloads: | Tarball | ZIP archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA1: |
211a88540a979b4890fcc4a365b9d01f |
User & Date: | mistachkin 2014-01-24 07:07:34.600 |
Context
2014-01-24
| ||
17:03 | Minor corrections to the test automation. check-in: acd91e80a9 user: mistachkin tags: trunk | |
07:07 | Skip copying native files to the test binary directory when not running on the default platform. check-in: 211a88540a user: mistachkin tags: trunk | |
01:27 | More work on getting 32-bit on 64-bit testing support working. check-in: b310edde93 user: mistachkin tags: trunk | |
Changes
Changes to Tests/common.eagle.
︙ | ︙ | |||
144 145 146 147 148 149 150 151 152 153 154 155 156 157 | } default { return netFx35; # TODO: Good "fallback" default? } } } } proc getBuildPlatform { native } { if {[info exists ::test_platform] && \ [string length $::test_platform] > 0} then { # # NOTE: Use the specified test platform. If this variable is not set, # the default value will be based on the machine architecture. | > > > > > > > > > > > > > > > > > > > > > > > > > > | 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 | } default { return netFx35; # TODO: Good "fallback" default? } } } } # # NOTE: This procedure should return non-zero if the configured test # platform is most likely the default for this machine. # proc isDefaultBuildPlatform { {verbose false} } { # # NOTE: Running on WoW64 is never the default platform. # if {[info exists ::eagle_platform(wow64)] && \ $::eagle_platform(wow64)} then { if {$verbose} then { tputs $::test_channel \ "---- detected non-default platform (WoW64)\n" } return false } # # NOTE: This has a good chance of being the default platform. # if {$verbose} then { tputs $::test_channel "---- detected default platform\n" } return true } proc getBuildPlatform { native } { if {[info exists ::test_platform] && \ [string length $::test_platform] > 0} then { # # NOTE: Use the specified test platform. If this variable is not set, # the default value will be based on the machine architecture. |
︙ | ︙ | |||
814 815 816 817 818 819 820 | return [uplevel 1 [list subst [appendArgs $prefix { if {[hasRuntimeOption native]} then { object invoke Interpreter.GetActive AddRuntimeOption native } } [getTestOverridesPreamble [list path test_channel]] $suffix]]] } | | > > | | | | | 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 | return [uplevel 1 [list subst [appendArgs $prefix { if {[hasRuntimeOption native]} then { object invoke Interpreter.GetActive AddRuntimeOption native } } [getTestOverridesPreamble [list path test_channel]] $suffix]]] } proc tryCopyExternalFile { fileName {platform ""} {newFileName ""} {verbose false} } { set sourceFileName [getExternalFileName $fileName] if {![file exists $sourceFileName]} then { if {$verbose} then { tputs $::test_channel [appendArgs \ "---- skipped copying external file \"" $sourceFileName \ "\", it does not exist\n"] } return } if {[string length $newFileName] > 0} then { set targetFileName [getBinaryFileName $newFileName $platform] } else { set targetFileName [getBinaryFileName $fileName $platform] |
︙ | ︙ | |||
849 850 851 852 853 854 855 | } else { tputs $::test_channel [appendArgs \ "---- failed to copy external file from \"" $sourceFileName \ "\" to \"" $targetFileName \"\n] } } | | > > | | | | | 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 | } else { tputs $::test_channel [appendArgs \ "---- failed to copy external file from \"" $sourceFileName \ "\" to \"" $targetFileName \"\n] } } proc tryCopyBinaryFile { fileName {platform ""} {newFileName ""} {verbose false} } { set sourceFileName [getBinaryFileName $fileName $platform] if {![file exists $sourceFileName]} then { if {$verbose} then { tputs $::test_channel [appendArgs \ "---- skipped copying binary file \"" $sourceFileName \ "\", it does not exist\n"] } return } if {[string length $newFileName] > 0} then { set targetFileName [getBuildFileName $newFileName $platform] } else { set targetFileName [getBuildFileName $fileName $platform] |
︙ | ︙ | |||
884 885 886 887 888 889 890 | } else { tputs $::test_channel [appendArgs \ "---- failed to copy binary file from \"" $sourceFileName \ "\" to \"" $targetFileName \"\n] } } | | > > | | | | | 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 | } else { tputs $::test_channel [appendArgs \ "---- failed to copy binary file from \"" $sourceFileName \ "\" to \"" $targetFileName \"\n] } } proc tryCopyBuildFile { fileName {platform ""} {newFileName ""} {verbose false} } { set sourceFileName [getBuildFileName $fileName $platform] if {![file exists $sourceFileName]} then { if {$verbose} then { tputs $::test_channel [appendArgs \ "---- skipped copying build file \"" $sourceFileName \ "\", it does not exist\n"] } return } if {[string length $newFileName] > 0} then { set targetFileName [getBinaryFileName $newFileName $platform] } else { set targetFileName [getBinaryFileName $fileName $platform] |
︙ | ︙ | |||
919 920 921 922 923 924 925 | } else { tputs $::test_channel [appendArgs \ "---- failed to copy build file from \"" $sourceFileName \ "\" to \"" $targetFileName \"\n] } } | | > | | | | | > | | | | | > | | | > | | | 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 | } else { tputs $::test_channel [appendArgs \ "---- failed to copy build file from \"" $sourceFileName \ "\" to \"" $targetFileName \"\n] } } proc tryDeleteBinaryFile { fileName {platform ""} {verbose false} } { set fileName [getBinaryFileName $fileName $platform] if {![file exists $fileName]} then { if {$verbose} then { tputs $::test_channel [appendArgs \ "---- skipped deleting binary file \"" $fileName \ "\", it does not exist\n"] } return } if {[catch {file delete $fileName}] == 0} then { tputs $::test_channel [appendArgs \ "---- deleted binary file \"" $fileName \"\n] } else { tputs $::test_channel [appendArgs \ "---- failed to delete binary file \"" $fileName \"\n] } } proc tryDeleteBuildFile { fileName {platform ""} {verbose false} } { set fileName [getBuildFileName $fileName $platform] if {![file exists $fileName]} then { if {$verbose} then { tputs $::test_channel [appendArgs \ "---- skipped deleting build file \"" $fileName \ "\", it does not exist\n"] } return } if {[catch {file delete $fileName}] == 0} then { tputs $::test_channel [appendArgs \ "---- deleted build file \"" $fileName \"\n] } else { tputs $::test_channel [appendArgs \ "---- failed to delete build file \"" $fileName \"\n] } } proc tryCopyAssembly { fileName {platform ""} {pdb true} {verbose false} } { tryCopyBuildFile $fileName $platform "" $verbose if {$pdb} then { tryCopyBuildFile [appendArgs \ [file rootname $fileName] .pdb] $platform "" $verbose } } proc tryDeleteAssembly { fileName {platform ""} {pdb true} {verbose false} } { tryDeleteBinaryFile $fileName $platform $verbose if {$pdb} then { tryDeleteBinaryFile [appendArgs \ [file rootname $fileName] .pdb] $platform $verbose } } proc tryLoadAssembly { fileName {platform ""} } { set fileName [getBinaryFileName $fileName $platform] if {[catch { |
︙ | ︙ | |||
2647 2648 2649 2650 2651 2652 2653 | # foreach fileName $externalFileNames { tryCopyExternalFile $fileName } } if {![info exists ::no(copySqliteNativeFiles)]} then { | > > > > > | > | 2683 2684 2685 2686 2687 2688 2689 2690 2691 2692 2693 2694 2695 2696 2697 2698 2699 2700 2701 2702 2703 | # foreach fileName $externalFileNames { tryCopyExternalFile $fileName } } if {![info exists ::no(copySqliteNativeFiles)]} then { # # NOTE: If the test platform is likely the default for this # machine, also try to copy the native files to the # binary location. # if {![info exists ::no(copySqliteImplicitFiles)] && \ [isDefaultBuildPlatform true]} then { foreach fileName $nativeFileNames { tryCopyAssembly $fileName } } if {![info exists ::no(copySqliteNonImplicitFiles)]} then { if {![info exists ::no(copySqlitePlatformFiles)] && \ |
︙ | ︙ |