Start refactoring of app BUCK files
- Brian added maven coordinates to the maven JAR short path
- refactored segment routing and ganglia metrics apps

Change-Id: I7b8110e07a474d256d4821c1a9d083c9c8c11e2e
diff --git a/apps/segmentrouting/BUCK b/apps/segmentrouting/BUCK
index 0aeaa89..b659b86 100644
--- a/apps/segmentrouting/BUCK
+++ b/apps/segmentrouting/BUCK
@@ -1,9 +1,3 @@
-SRC = 'src/main/java/org/onosproject/**/'
-TEST = 'src/test/java/org/onosproject/**/'
-
-CURRENT_NAME = 'onos-app-segmentrouting'
-CURRENT_TARGET = ':' + CURRENT_NAME
-
 COMPILE_DEPS = [
     '//lib:CORE_DEPS',
     '//lib:org.apache.karaf.shell.console',
@@ -18,22 +12,14 @@
     '//lib:TEST_ADAPTERS',
 ]
 
-java_library(
-    name = CURRENT_NAME,
-    srcs = glob([SRC + '/*.java']),
+osgi_jar_with_tests (
     deps = COMPILE_DEPS,
-    visibility = ['PUBLIC'],
-    resources_root = 'src/main/resources',
-    resources = glob(['src/main/resources/**']),
+    test_deps = TEST_DEPS,
 )
 
-java_test(
-    name = 'tests',
-    srcs = glob([TEST + '/*.java']),
-    deps = COMPILE_DEPS +
-           TEST_DEPS +
-           [CURRENT_TARGET],
-    source_under_test = [CURRENT_TARGET],
-    resources_root = 'src/test/resources',
-    resources = glob(['src/test/resources/**']),
+onos_app (
+    title = 'Proxy ARP/NDP App',
+    category = 'Traffic Steering',
+    url = 'http://onosproject.org',
+    description = 'Proxy ARP/NDP application.',
 )