This project is read-only.

SheepAspect + ILMerge

May 8, 2013 at 2:19 AM
Is it possible to use ILMerge and SheepAspect together? I want to have one assembly for my aspect oriented library (AOP.dll). Here is my current post-build on my project:

"$(SolutionDir)packages\ilmerge.2.13.0307\ilmerge.exe" /target:library /out:"$(TargetDir)AOP.dll" "$(TargetDir)AOPTemp.dll" "$(TargetDir)Antlr3.Runtime.dll" "$(TargetDir)Mono.Cecil.dll" "$(TargetDir)Mono.Cecil.mdb.dll" "$(TargetDir)Mono.Cecil.pdb.dll" "$(TargetDir)" "$(TargetDir)SheepAspect.dll"

The command completes successfully and the merged dll is created; however, when I run my sample application, the SampleAspect does not produce any output. Any suggestions?
May 9, 2013 at 2:36 PM
I personally have not tried ILMerging any SheepAspect project, but in theory I can't see any reason why it would be different. Just to check, does the SampleAspect produce any output without ILMerge?
May 11, 2013 at 8:53 PM
I tried ILMerging SheepAspect, SheepAspect.Tasks, Antlr.. and dependencies together into one combined assembly and found that the PostCompileWeave Task did not weave in the aspects. I did not look too deeply into why this was the case. Incidentally in my case I was trying to do this to avoid a clash between Sheep's dependency on Antlr 3.3.... and another project having a dependency on Antlr 3.2..... I did a quick test with ILMerge and gave up when the aspects were not woven to look at other workarounds.

Hope this helps.