Transitive dependency not resolved

I would like to simulate the behaviour of maven for this pom.xml:

<?xml version="1.0" encoding="UTF-8"?>
    <project xmlns="" xmlns:xsi=""

mvn dependency:tree gives me:

[INFO] — maven-dependency-plugin:2.1:tree (default-cli) @ example —


[INFO] - org.apache.shiro:shiro-spring:jar:1.2.2:compile


± org.apache.shiro:shiro-core:jar:1.2.2:compile


| ± org.slf4j:slf4j-api:jar:1.6.4:compile


| - commons-beanutils:commons-beanutils:jar:1.8.3:compile


- org.apache.shiro:shiro-web:jar:1.2.2:compile

Now my gradle build file looks like this:

apply plugin: 'java'
      repositories {
      dependencies {

and the output of gradle dependencies looks like this (without the other configs that have the same result):

compile - Compile classpath for source set ‘main’.

— org.apache.shiro:shiro-spring:1.2.2

— org.apache.shiro:shiro-web:1.2.2

So, where is the dependency to shiro-core? Why is it missing and what do I have to change to get the same results as with maven?

Not sure what’s going on here. Maybe Gradle is getting confused by the “bundle” packaging type. Raised as Gradle-2885. In the meantime you can declare an explicit dependency on ‘shiro-core’.

Yeah, thanks, the workaround works. I was just wondering, because the shiro pom looks pretty usual, nothing fancy in it. And the rest of my project resolves perfectly.