face: Refactor Face as LinkService+Transport

LpFace: new Face implementation
LpFaceWrapper: allows new Face system to work with old Face system

Eventually, LpFace will be renamed to Face and LpFaceWrapper will be removed.

refs #3088 #3179

Change-Id: Ia4ad7c84631e65b444d4f24e1d7593392927c8db
diff --git a/.waf-tools/compiler-features.py b/.waf-tools/compiler-features.py
index 1fd529e..8fa6aa7 100644
--- a/.waf-tools/compiler-features.py
+++ b/.waf-tools/compiler-features.py
@@ -23,5 +23,41 @@
                    define_name='HAVE_CXX_OVERRIDE',
                    features='cxx', mandatory=False)
 
+FINAL = '''
+class Base
+{
+  virtual void
+  f(int a);
+};
+
+class Derived : public Base
+{
+  virtual void
+  f(int a) final;
+};
+'''
+
+@conf
+def check_final(self):
+    self.check_cxx(msg='Checking for final specifier on method',
+                   fragment=FINAL,
+                   define_name='HAVE_CXX_FINAL',
+                   features='cxx', mandatory=False)
+
+CLASS_FINAL = '''
+class A final
+{
+};
+'''
+
+@conf
+def check_class_final(self):
+    self.check_cxx(msg='Checking for final specifier on class',
+                   fragment=CLASS_FINAL,
+                   define_name='HAVE_CXX_CLASS_FINAL',
+                   features='cxx', mandatory=False)
+
 def configure(conf):
     conf.check_override()
+    conf.check_final()
+    conf.check_class_final()