You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Mark Derricutt <ma...@talios.com> on 2009/04/24 04:20:10 UTC

Strange profiles problem

Hi all,

I'm having a strange problem with profiles which seems to have just
manifest itself (sadly timed with upgrading to Team City 4.5, but I
can reproduce it locally now too).

Anyway, I'm trying to build an aggregated project with a profile
turned on via the command line.

My project layout is:

- pom.xml
- profiles.xml
+- integration/pom.xml
     +- launchpad/pom.xml
     +- launchpad-tests/pom.xml
     ....

Each project is parented by its file system parent, when I look at
active-profiles, only the integration/pom.xml seems to have the
"trunk" profile enabled, but not the ones that actually need it.  The
"trunk" profile is defined in the top level profiles.xml file.  Why
would maven not enable the trunk profile down the chain?

This is using maven 2.1.0.

~/IdeaProjects/securemx/smx3/integration (no branch)(☠) $ mvn -Ptrunk
help:active-profiles
[INFO] Scanning for projects...
[INFO] Reactor build order:
[INFO]   SMX3 Platform
[INFO]   SMX3 Database Initialization
[INFO]   SMX3 - Platform Application
[INFO]   selenium-control-server
[INFO]   selenium-control-client
[INFO]   SMX3 System Integration Tests
[INFO]   Rules Engine Application
[INFO] Searching repository for plugin with prefix: 'help'.
[INFO] ------------------------------------------------------------------------
[INFO] Building SMX3 Platform
[INFO]    task-segment: [help:active-profiles] (aggregator-style)
[INFO] ------------------------------------------------------------------------
[INFO] [help:active-profiles]
[INFO]
Active Profiles for Project 'smx3:integration:pom:3.0.7-SNAPSHOT':

The following profiles are active:

 - trunk (source: profiles.xml)
 - trunk (source: profiles.xml)
 - smx-settings (source: settings.xml)
 - smx-settings (source: settings.xml)



Active Profiles for Project 'smx3:database-creation:jar:3.0.7-SNAPSHOT':

The following profiles are active:

 - smx-settings (source: settings.xml)
 - smx-settings (source: settings.xml)



Active Profiles for Project 'smx3:launchpad:jar:3.0.7-SNAPSHOT':

The following profiles are active:

 - local (source: pom)
 - smx-settings (source: settings.xml)
 - smx-settings (source: settings.xml)





...and then Buffy staked Edward.  The End.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Strange profiles problem

Posted by Mark Derricutt <ma...@talios.com>.
No responses :(  But it turns out this is regression in 2.1.0 -
http://jira.codehaus.org/browse/MNG-3732

On Fri, Apr 24, 2009 at 2:29 PM, Mark Derricutt <ma...@talios.com> wrote:

> And getting stranger...
>
> The trunk profile only gives properties:
>
> <profilesXml>
>    <profiles>
>        <profile>
>            <id>trunk</id>
>            <activation>
>                <activeByDefault>true</activeByDefault>
>            </activation>
>            <properties>
>                <org.osgi.core>1.2.0</org.osgi.core>
>                <org.osgi.compendium>1.2.0</org.osgi.compendium>
>
> When I change to my launchpad-tests module, and run mvn
> help:effective-pom, I see these properties being defined, but
> help:active-profiles never shows "trunk" as being active and the build
> works fine.
>
> If I copy the profiles.xml file into the launchpad-tests folder, I see
> it the profile now listed as being active.  Am I missing some
> fundamental understanding of how profiles.xml should work?
>
> ...and then Buffy staked Edward.  The End.
>
> On Fri, Apr 24, 2009 at 2:20 PM, Mark Derricutt <ma...@talios.com> wrote:
> > Hi all,
>

Re: Strange profiles problem

Posted by Mark Derricutt <ma...@talios.com>.
And getting stranger...

The trunk profile only gives properties:

<profilesXml>
    <profiles>
        <profile>
            <id>trunk</id>
            <activation>
                <activeByDefault>true</activeByDefault>
            </activation>
            <properties>
                <org.osgi.core>1.2.0</org.osgi.core>
                <org.osgi.compendium>1.2.0</org.osgi.compendium>

When I change to my launchpad-tests module, and run mvn
help:effective-pom, I see these properties being defined, but
help:active-profiles never shows "trunk" as being active and the build
works fine.

If I copy the profiles.xml file into the launchpad-tests folder, I see
it the profile now listed as being active.  Am I missing some
fundamental understanding of how profiles.xml should work?

...and then Buffy staked Edward.  The End.

On Fri, Apr 24, 2009 at 2:20 PM, Mark Derricutt <ma...@talios.com> wrote:
> Hi all,

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org