{"id":2565,"date":"2018-07-19T01:48:37","date_gmt":"2018-07-18T16:48:37","guid":{"rendered":"https:\/\/www.chihayafuru.jp\/tech\/?p=2565"},"modified":"2018-07-19T01:49:58","modified_gmt":"2018-07-18T16:49:58","slug":"win-exe%e3%81%a8%e8%a4%87%e6%95%b0%e3%81%aedll%e3%82%92%e3%83%9e%e3%83%bc%e3%82%b8%e3%81%97%e3%81%a6%ef%bc%91%e3%83%95%e3%82%a1%e3%82%a4%e3%83%ab%e5%8c%96","status":"publish","type":"post","link":"https:\/\/www.chihayafuru.jp\/tech\/index.php\/archives\/2565","title":{"rendered":"[win] EXE\u3068\u8907\u6570\u306eDLL\u3092\u30de\u30fc\u30b8\u3057\u3066\uff11\u30d5\u30a1\u30a4\u30eb\u5316"},"content":{"rendered":"<p>Microsoft\u516c\u5f0f\u30b3\u30de\u30f3\u30c9\u30e9\u30a4\u30f3\u30c4\u30fc\u30eb ILMerge<\/p>\n<p><a href=\"https:\/\/www.microsoft.com\/en-us\/download\/details.aspx?id=17630\">https:\/\/www.microsoft.com\/en-us\/download\/details.aspx?id=17630<\/a><!--more--><\/p>\n<p>&nbsp;<\/p>\n<h3>1. .NET Framework\u306b\u4f9d\u5b58\u3057\u306a\u3044 exe, dll\u30d5\u30a1\u30a4\u30eb\u306e\uff11\u30d5\u30a1\u30a4\u30eb\u5316\u306e\u4f8b<\/h3>\n<pre class=\"lang:default highlight:0 decode:true \" >&gt; \"\\Program Files (x86)\\Microsoft\\ILMerge\\ILMerge.exe\" ^\r\n  \/out:MergedMyApp.exe  MyApp.exe  MyLib0.dll<\/pre>\n<p>&nbsp;<\/p>\n<h4>1.1. .NET Framework\u306b\u4f9d\u5b58\u3057\u3066\u3044\u308b\u305f\u3081\u30a8\u30e9\u30fc\u304c\u767a\u751f\u3057\u305f\u4f8b<\/h4>\n<pre class=\"lang:default highlight:0 decode:true \" >An exception occurred during merging:\r\nUnresolved assembly reference not allowed: System.Core.\r\n   \u5834\u6240 System.Compiler.Ir2md.GetAssemblyRefIndex(AssemblyNode assembly)\r\n   \u5834\u6240 System.Compiler.Ir2md.GetTypeRefIndex(TypeNode type)\r\n   \u5834\u6240 System.Compiler.Ir2md.VisitReferencedType(TypeNode type)\r\n   \u5834\u6240 System.Compiler.Ir2md.GetMemberRefIndex(Member m)\r\n   \u5834\u6240 System.Compiler.Ir2md.GetMethodToken(Method m)\r\n   \u5834\u6240 System.Compiler.Ir2md.VisitMethodCall(MethodCall call)\r\n   \u5834\u6240 System.Compiler.Ir2md.VisitBranch(Branch branch)\r\n   \u5834\u6240 System.Compiler.Ir2md.VisitBlock(Block block)\r\n   \u5834\u6240 System.Compiler.Ir2md.VisitBlock(Block block)\r\n   \u5834\u6240 System.Compiler.Ir2md.VisitMethodBody(Method method)\r\n   \u5834\u6240 System.Compiler.Ir2md.VisitMethod(Method method)\r\n   \u5834\u6240 System.Compiler.Ir2md.VisitClass(Class Class)\r\n   \u5834\u6240 System.Compiler.Ir2md.VisitModule(Module module)\r\n   \u5834\u6240 System.Compiler.Ir2md.SetupMetadataWriter(String debugSymbolsLocation)\r\n   \u5834\u6240 System.Compiler.Ir2md.WritePE(Module module, String debugSymbolsLocation, BinaryWriter writer)\r\n   \u5834\u6240 System.Compiler.Writer.WritePE(String location, Boolean writeDebugSymbols, Module module, Boolean delaySign, String keyFileName, String keyName)\r\n   \u5834\u6240 System.Compiler.Writer.WritePE(CompilerParameters compilerParameters, Module module)\r\n   \u5834\u6240 ILMerging.ILMerge.Merge()\r\n   \u5834\u6240 ILMerging.ILMerge.Main(String[] args)<\/pre>\n<p>&nbsp;<\/p>\n<h3>2. .NET Framework\u306b\u4f9d\u5b58\u3057\u305f exe, dll\u30d5\u30a1\u30a4\u30eb\u306e\uff11\u30d5\u30a1\u30a4\u30eb\u5316\u306e\u4f8b<\/h3>\n<p>.NET Framework\u306e\u30d1\u30b9\u6307\u5b9a\u3092\u8ffd\u52a0\u3059\u308b<\/p>\n<h4>2.1. .NET Framework 4.6.1 \u306e\u5834\u5408<\/h4>\n<blockquote><p>C:\\Program Files (x86)\\Reference Assemblies\\Microsoft\\Framework\\.NETFramework\\v4.6.1 <\/p><\/blockquote>\n<pre class=\"lang:default highlight:0 decode:true \" >&gt; \"\\Program Files (x86)\\Microsoft\\ILMerge\\ILMerge.exe\" ^\r\n  \/targetplatform:\"v4,C:\\Program Files (x86)\\Reference Assemblies\\Microsoft\\Framework\\.NETFramework\\v4.6.1\" ^\r\n  \/out:MergedMyApp.exe  MyApp.exe  MyLib0.dll<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Microsoft\u516c\u5f0f\u30b3\u30de\u30f3\u30c9\u30e9\u30a4\u30f3\u30c4\u30fc\u30eb ILMerge https:\/\/www.microsoft.com\/en-us\/download\/details.aspx?id=17630<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[80,38],"class_list":["post-2565","post","type-post","status-publish","format-standard","hentry","category-memo","tag-c","tag-windows"],"_links":{"self":[{"href":"https:\/\/www.chihayafuru.jp\/tech\/index.php\/wp-json\/wp\/v2\/posts\/2565","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.chihayafuru.jp\/tech\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.chihayafuru.jp\/tech\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.chihayafuru.jp\/tech\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.chihayafuru.jp\/tech\/index.php\/wp-json\/wp\/v2\/comments?post=2565"}],"version-history":[{"count":11,"href":"https:\/\/www.chihayafuru.jp\/tech\/index.php\/wp-json\/wp\/v2\/posts\/2565\/revisions"}],"predecessor-version":[{"id":2596,"href":"https:\/\/www.chihayafuru.jp\/tech\/index.php\/wp-json\/wp\/v2\/posts\/2565\/revisions\/2596"}],"wp:attachment":[{"href":"https:\/\/www.chihayafuru.jp\/tech\/index.php\/wp-json\/wp\/v2\/media?parent=2565"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.chihayafuru.jp\/tech\/index.php\/wp-json\/wp\/v2\/categories?post=2565"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.chihayafuru.jp\/tech\/index.php\/wp-json\/wp\/v2\/tags?post=2565"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}