none
RELEASETYPE=LOCAL...wrong destination target path ? RRS feed

  • Question

  • Hello,

    I have a subproject and in the sources file is set RELEASETYPE = LOCAL. I expect that the exe file is generated inside local directory but I find it in the path %_PROJECTROOT%\Oak\Target\%_TGTCPU% that is right if I set RELEASETYPE = OAK. Why ? I'm working on windows ce 6.0 r3.

    Thanks, Paolo.

    Wednesday, March 2, 2011 1:07 PM

Answers

  • Well, not exactly.  RELEASETYPE=OAK sets _RELEASEDIR to $(__PROJROOT)\oak\target\$(__CPUDIR) and builds the files there always.  RELEASETYPE=LOCAL sets _RELEASEDIR to $(_OBJDIR) as Bruce noted, so the files get built in _OBJDIR, but in the case of PB subproject only, the makefile copies the target to $(__PROJROOT)\oak\target\$(__CPUDIR)\ for buildrel to pick up.  It seems a bit odd to me, but it's necessary to achieve the "expected" behavoir of builds of the PB subprojects within the IDE.

    So technically the documenatio nis correct.


    Tom Gensel PTG Systems, LLC
    http://www.ptgsystems.com

    Wednesday, March 2, 2011 3:39 PM

All replies

  • The EXE should end up in _OBJDIR.  Did you a clean build after making the change?  Build won't detect that the sources file changed.
    Bruce Eitman (eMVP)
    Senior Engineer
    Bruce.Eitman AT Eurotech DOT com
    My BLOG http://geekswithblogs.net/bruceeitman

    Eurotech Inc.
    www.Eurotech.com
    Wednesday, March 2, 2011 1:13 PM
    Moderator
  • I only rebuild the subproject. If I delete manually files inside %_PROJECTROOT%\Oak\Target\%_TGTCPU% and the rebuild subproject, I can find the files there again !
    Wednesday, March 2, 2011 1:18 PM
  • Any idea ? I can't solve the problem....the files are always in %_PROJECTROOT%\Oak\Target\%_TGTCPU%.

    Thanks, Paolo.

    Wednesday, March 2, 2011 2:06 PM
  • Have you looked in the build.log for clues?

    What happens if you open a build window and go to the folder with the sources file, then run "build -c"?


    Bruce Eitman (eMVP)
    Senior Engineer
    Bruce.Eitman AT Eurotech DOT com
    My BLOG http://geekswithblogs.net/bruceeitman

    Eurotech Inc.
    www.Eurotech.com
    Wednesday, March 2, 2011 2:54 PM
    Moderator
  • Isn't this just the standard behavior?  The following lines were snipped from makefile.def:

    # If we are building a PBP project (PB subproject) we copy to  $(__PROJROOT)\oak\target so that it is
    # available for copy during buildrel
    !IF "$(RELEASETYPE)" == "LOCAL"
    !  IF [EXIST($(MAKEDIR)\*.pbpxml)]
          -$(__COPYCMD) $(_RELEASEDIR)\$(TARGETNAME).exe $(__PROJROOT)\oak\target\$(__CPUDIR)\$(TARGETNAME).exe
          -$(__COPYCMD) $(_RELEASEDIR)\$(TARGETNAME).map $(__PROJROOT)\oak\target\$(__CPUDIR)\$(TARGETNAME).map
           if exist $(TARGET_PDB_NAME) $(__COPYCMD) $(TARGET_PDB_NAME) $(__PROJROOT)\oak\target\$(__CPUDIR)
          -if exist $(_RELEASEDIR)\$(TARGETNAME).rel $(__COPYCMD) $(_RELEASEDIR)\$(TARGETNAME).rel $(__PROJROOT)\oak\target\$(__CPUDIR)\$(TARGETNAME).rel
    !  ENDIF
    !ENDIF


    Tom Gensel PTG Systems, LLC
    http://www.ptgsystems.com
    Wednesday, March 2, 2011 3:05 PM
  • So the documentation isn't correct....OAK and LOCAL are the same !?
    Wednesday, March 2, 2011 3:15 PM
  • Well, not exactly.  RELEASETYPE=OAK sets _RELEASEDIR to $(__PROJROOT)\oak\target\$(__CPUDIR) and builds the files there always.  RELEASETYPE=LOCAL sets _RELEASEDIR to $(_OBJDIR) as Bruce noted, so the files get built in _OBJDIR, but in the case of PB subproject only, the makefile copies the target to $(__PROJROOT)\oak\target\$(__CPUDIR)\ for buildrel to pick up.  It seems a bit odd to me, but it's necessary to achieve the "expected" behavoir of builds of the PB subprojects within the IDE.

    So technically the documenatio nis correct.


    Tom Gensel PTG Systems, LLC
    http://www.ptgsystems.com

    Wednesday, March 2, 2011 3:39 PM
  • With build -c is the same...I think that the response is in makfile.def as suggest by T.Gensel...but in this way, the documentation is wrong ... OAK and LOCAL seem to be the same.

    Paolo

    Wednesday, March 2, 2011 3:40 PM
  • build -c is the same as long as there is a .PBPXML file in the MAKEDIR, implying to the build system that it's a PB subproject.  Without the .PBPXML file, the result matches the documentation since the target does not get copied.


    Tom Gensel PTG Systems, LLC
    http://www.ptgsystems.com
    Wednesday, March 2, 2011 3:47 PM
  • Ok...so this behaviour is only for subprojects and not, for example, drivers inside PLATFORM\<BSP>\src directory.

    Thank you very much !

    Paolo.

    Wednesday, March 2, 2011 3:48 PM
  • The last question; in makefile.def I can't find the !IF "$(RELEASETYPE)" == "OAK" where _RELEASEDIR to $(__PROJROOT)\oak\target\$(__CPUDIR)  is set. Where is it ?

    Thanks, Paolo.

    Wednesday, March 2, 2011 4:06 PM