Allow writing MAC address to networkd config file to be blocked

The systemd.networkd configuration file can store the MAC
address. This allows the MAC address to be changed on demand. This
feature may not desirable to some vendors. Server suppliers may prefer
to have an immutable MAC address.

The change here adds a compile time switch that enables/disables
writing the MAC address to the configuration file.

Tested:
Confirmed the default configuration permitted the MAC address to be written to
the configuration file.
Added a OEMESON override to the phosphor-network.bbappend file and
confirmed the MAC address no longer gets written.

Change-Id: Ic1eb69980cea6864a30dac93dd472ba9e0e2c1a9
Signed-off-by: Johnathan Mantey <johnathanx.mantey@intel.com>
diff --git a/src/ethernet_interface.cpp b/src/ethernet_interface.cpp
index 42ad198..3da9a57 100644
--- a/src/ethernet_interface.cpp
+++ b/src/ethernet_interface.cpp
@@ -1029,10 +1029,12 @@
     // Write the link section
     stream << "[Link]\n";
     auto mac = MacAddressIntf::macAddress();
+#ifdef PERSIST_MAC
     if (!mac.empty())
     {
         stream << "MACAddress=" << mac << "\n";
     }
+#endif
 
     if (!EthernetInterfaceIntf::nicEnabled())
     {