コード例 #1
0
ファイル: Package.cs プロジェクト: AndreGleichner/getboost
 public static Version CompilerVersion(Config.CompilerInfo info)
 {
     return Config.Version.Switch(
         stable => info.PreRelease == "" ?
             stable as Version :
             new UnstableVersion(
                 stable.Major,
                 stable.Minor,
                 stable.MajorRevision,
                 info.PreRelease),
         unstable => unstable);
 }
コード例 #2
0
ファイル: Main.cs プロジェクト: asceth/synapi
        static void Main(string[] args)
        {
            if (args.GetLength(0) < 1)
            {
                System.Console.WriteLine("Usage: <config file>");
                return;
            }

            Config cfg = new Config();
            if (!cfg.ReadFromFile(args[0]))
            {
                return;
            }

            /* :TODO: Add path validation */

            ABuilder bld = null;

            if (cfg.Platform == BasePlatform.Platform_Linux)
            {
                bld = new LinuxBuilder(cfg);
            }
            else if (cfg.Platform == BasePlatform.Platform_Windows)
            {
                bld = new Win32Builder(cfg);
                /* Do not delete this file anymore.  We don't support rebuilds, and thus the file
                 * is guaranteed to be wiped by buildbot.
                 */
                /*if (cfg.pdb_log_file != null && File.Exists(cfg.pdb_log_file))
                {
                    File.Delete(cfg.pdb_log_file);
                }*/
            }

            try
            {
                bld.BuildPackage(new PkgCore());
            }
            catch (System.Exception e)
            {
                Console.WriteLine("Build failed, exception: " + e.Message);
                Environment.Exit(1);
            }

            Environment.Exit(0);
        }
コード例 #3
0
ファイル: Main.cs プロジェクト: Nephyrin/-furry-octo-nemesis
        static void Main(string[] args)
        {
            if (args.GetLength(0) < 1)
            {
                System.Console.WriteLine("Usage: <config file>");
                return;
            }

            Config cfg = new Config();
            if (!cfg.ReadFromFile(args[0]))
            {
                return;
            }

            /* :TODO: Add path validation */

            ABuilder bld = null;

            if (cfg.Platform == BasePlatform.Platform_Linux)
            {
                bld = new LinuxBuilder(cfg);
            }
            else if (cfg.Platform == BasePlatform.Platform_Windows)
            {
                bld = new Win32Builder(cfg);
                if (cfg.pdb_log_file != null && File.Exists(cfg.pdb_log_file))
                {
                    File.Delete(cfg.pdb_log_file);
                }
            }

            try
            {
                bld.BuildPackage(new PkgCore());
            }
            catch (System.Exception e)
            {
                Console.WriteLine("Build failed, exception: " + e.Message);
                Environment.Exit(1);
            }

            Environment.Exit(0);
        }
コード例 #4
0
ファイル: LinuxBuilder.cs プロジェクト: asceth/synapi
 public LinuxBuilder(Config _cfg)
 {
     cfg = _cfg;
 }
コード例 #5
0
ファイル: Win32Builder.cs プロジェクト: asceth/synapi
 public Win32Builder(Config _cfg)
 {
     cfg = _cfg;
 }