raw
udp_genesis             1 ------------------------------------------------------------------------------
udp_genesis 2 ------------------------------------------------------------------------------
udp_genesis 3 -- This file is part of 'UDP Tx Demo', accompanies 'UDP' library. --
udp_genesis 4 -- --
udp_genesis 5 -- (C) 2018 Stanislav Datskovskiy ( www.loper-os.org ) --
udp_genesis 6 -- http://wot.deedbot.org/17215D118B7239507FAFED98B98228A001ABFFC7.html --
udp_genesis 7 -- --
udp_genesis 8 -- You do not have, nor can you ever acquire the right to use, copy or --
udp_genesis 9 -- distribute this software ; Should you use this software for any purpose, --
udp_genesis 10 -- or copy and distribute it to anyone or in any manner, you are breaking --
udp_genesis 11 -- the laws of whatever soi-disant jurisdiction, and you promise to --
udp_genesis 12 -- continue doing so for the indefinite future. In any case, please --
udp_genesis 13 -- always : read and understand any software ; verify any PGP signatures --
udp_genesis 14 -- that you use - for any purpose. --
udp_genesis 15 -- --
udp_genesis 16 -- See also http://trilema.com/2015/a-new-software-licensing-paradigm . --
udp_genesis 17 ------------------------------------------------------------------------------
udp_genesis 18 ------------------------------------------------------------------------------
udp_genesis 19
udp_genesis 20 with "../libudp/udp.gpr";
udp_genesis 21
udp_genesis 22 project UDP_Tx_Demo is
udp_genesis 23
udp_genesis 24 for Object_Dir use "obj";
udp_genesis 25
udp_genesis 26 type Mode_Type is ("debug", "release");
udp_genesis 27 Mode : Mode_Type := external ("mode", "release");
udp_genesis 28
udp_genesis 29 for Languages use ("Ada");
udp_genesis 30 for Source_Dirs use (".");
udp_genesis 31 for Exec_Dir use "bin";
udp_genesis 32 for Main use ("udp_tx_demo.adb");
udp_genesis 33
udp_genesis 34 package Compiler is
udp_genesis 35 case Mode is
udp_genesis 36 when "debug" =>
udp_genesis 37 for Switches ("Ada")
udp_genesis 38 use ("-g");
udp_genesis 39 when "release" =>
udp_genesis 40 for Switches ("Ada")
udp_genesis 41 use ("-O2", "-fdump-scos", "-gnata", "-fstack-check",
udp_genesis 42 "-gnatyd", "-gnatym",
udp_genesis 43 "-fdata-sections", "-ffunction-sections");
udp_genesis 44 end case;
udp_genesis 45 end Compiler;
udp_genesis 46
udp_genesis 47 package Binder is
udp_genesis 48 case Mode is
udp_genesis 49 when "debug" =>
udp_genesis 50 for Switches ("Ada")
udp_genesis 51 use ();
udp_genesis 52 when "release" =>
udp_genesis 53 for Switches ("Ada")
udp_genesis 54 use ("-static");
udp_genesis 55 end case;
udp_genesis 56 end Binder;
udp_genesis 57
udp_genesis 58 package Linker is
udp_genesis 59 case Mode is
udp_genesis 60 when "debug" =>
udp_genesis 61 for Switches ("Ada")
udp_genesis 62 use ();
udp_genesis 63 when "release" =>
udp_genesis 64 for Switches ("Ada")
udp_genesis 65 use ("-Wl,--gc-sections", "-static");
udp_genesis 66 end case;
udp_genesis 67 end Linker;
udp_genesis 68
udp_genesis 69 end UDP_Tx_Demo;