Fix artifact upload for compiler

check-artifact.sh was broken by the update to Gradle 2.10. We think the
update to Gradle 2.8 caused the POM to start being generated, but this
now fixes it to have the correct contents.

Using addFilter _disables_ the normal POM, so we use setFilter instead.

Fixes #1360
diff --git a/compiler/build.gradle b/compiler/build.gradle
index b65e058..a487992 100644
--- a/compiler/build.gradle
+++ b/compiler/build.gradle
@@ -194,7 +194,7 @@
 [
   install.repositories.mavenInstaller,
   uploadArchives.repositories.mavenDeployer,
-]*.addFilter('all') {artifact, file ->
+]*.setFilter {artifact, file ->
   ! (file.getName().endsWith('jar') || file.getName().endsWith('jar.asc'))
 }
 
@@ -210,6 +210,19 @@
   }
 }
 
+[
+  install.repositories.mavenInstaller,
+  uploadArchives.repositories.mavenDeployer,
+]*.pom*.whenConfigured { pom ->
+  pom.project {
+    // This isn't any sort of Java archive artifact, and OSSRH doesn't enforce
+    // javadoc for 'pom' packages. 'exe' would be a more appropriate packaging
+    // value, but it isn't clear how that will be interpreted. In addition,
+    // 'pom' is typically the value used when building an exe with Maven.
+    packaging = "pom"
+  }
+}
+
 test.dependsOn('testGolden', 'testNanoGolden')
 
 def configureTestTask(Task task, String suffix, String extraPackage) {