Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Have a look at our Games Focus blog post series which will show what Unity is doing for all game developers – now, next year, and in the future.
    Dismiss Notice

AssemblyInfo.cs solutions ?

Discussion in 'Scripting' started by Ubiant, May 2, 2018.

  1. Ubiant

    Ubiant

    Joined:
    Oct 17, 2017
    Posts:
    6
    Hellos guys,
    is there any solution to create or simulate the "AssemblyInfo.cs" in Unity compiler process ?
    I tried to take a look at Assembly & AssemblyBuilder classes and methods but I didn't find something to manage this.
    I'm currently using an external library that needs this otherwise I have a lot of compiling issue in Unity due to same methods logic between some namespace.

    In the native .NET project there is no issue but as soon as I import them in Unity it's blowing up everywhere :/
    I tried to manage it with asmdef file but it seems to be not enough.
     
  2. unity_dYJ9cMlnzonB1w

    unity_dYJ9cMlnzonB1w

    Joined:
    May 19, 2019
    Posts:
    1
    I have exactly the same problem... an answer will be welcome :)
     
  3. jacques_f

    jacques_f

    Joined:
    Jan 17, 2018
    Posts:
    3
    I may not be understanding the problem correctly, but if I add an 'AssemblyInfo.cs' file in the same directory as an asmdef file it seems to compile the managed assembly utilising the AssemblyInfo.cs file (so far I've just done a basic test setting AssemblyVersion, which causes the generated .dll file to have the specified version). This is using Unity 2019.1.11.
     
    RGV likes this.