Riverside-Software / pct

Build automation for OpenEdge ABL
Apache License 2.0
96 stars 62 forks source link

pct:compile - relativePaths="true" stops newer files being compiled #79

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. compile with relativePaths='true'
2. change a source 
3. restart build (without cleaning first)

What is the expected output? What do you see instead?

The r-code for the source that was changed should be recompiled, instead it is 
not.

I enabled debugPCT and turned clientlogging on with

         <option name="-clientlog" value="c:/temp/pct.log" />
         <option name="-logentrytypes" value="4GLTrace" />   

And the results are:

[Run adecomm/_osfext.p "version.p" [Main Block - pct/v11/pctCompile.p @ 424]
[4GL 4GLTRACE       Func getTimeStampDF "C:\tfs\ef71\1\work\build\ui version.r" 
[Main Block - pct/v11/pctCompile.p @ 426]
[Func getTimeStampF "C:\tfs\ef71\1\work\build\ui/version.r" [getTimeStampDF - 
pct/v11/pctCompile.p @ 1056]
[Func getTimeStampDF " version.p" [Main Block - pct/v11/pctCompile.p @ 436]
[Func getTimeStampF "/version.p" [getTimeStampDF - pct/v11/pctCompile.p @ 1056]

pct_filesets#.txt starts with "FILESET=" followed by the files on the next 
lines - ie the base directory for the fileset is not provided.

If I turn off relativePaths, then recompile when a source has changed works 
fine.

I /think/ the leading slash is breaking it. file-info:file-name = "version.p" 
finds the file if it is in the propath, file-info:file-name = "/version.p" does 
not.

So, adjust function getTimeStampDF in pctCompile.p to:

FUNCTION getTimeStampDF RETURNS DATETIME(INPUT d AS CHARACTER, INPUT f AS 
CHARACTER):
    RETURN getTimeStampF(SUBSTITUTE( IF d > "" THEN "&1/&2":u ELSE "&2":u, d, f).
END FUNCTION.

What version of the product are you using? On what operating system?

- Windows Vista x64
- PDSOE 11.4x64 (Eclipse 4.3.2)
- Ant 1.8.4 (default Eclipse 4.3.2)
- PCT-192
- JRE 1.7.0_45-b18 (note JRE and not JDK)

Please provide any additional information below.

Original issue reported on code.google.com by stefan.d...@gmail.com on 24 Nov 2014 at 2:14

GoogleCodeExporter commented 9 years ago
Will setup testcase and fix if reproduced.
Thanks for reporting !

Original comment by g.quer...@gmail.com on 24 Nov 2014 at 8:31

GoogleCodeExporter commented 9 years ago
Promoted testcase in PCTCompile/test47
However, I don't reproduce the issue (using the latest version, but I don't 
think I fixed anything yet). If you still have the issue, can you update the 
test case ?

Original comment by g.quer...@gmail.com on 1 Feb 2015 at 11:07

GoogleCodeExporter commented 9 years ago
Hi Gilles, 

The issue still occurs - note that my sources are directly below the project 
(and not in a src folder). 

Test case:

1. create general project pct
2. create build.xml (attached)
3. create test.p - message 1.
4. build -> console shows 1 file(s) compiled
5. update test.p - message 2.
6. build -> console shows 0 file(s) compiled
7. change relativePaths to false
8. build -> console shows 1 file(s) compiled
9. change test.p - message 3.
10 build -> console shows 1 file(s) compiled

Best regards,

Stefan

Original comment by stefan.d...@gmail.com on 12 Feb 2015 at 11:49

Attachments:

GoogleCodeExporter commented 9 years ago
Reproduced - As you said, related to the source code lying in the root directory

Original comment by g.quer...@gmail.com on 15 Feb 2015 at 8:05

GoogleCodeExporter commented 9 years ago
Fixed in dev

Original comment by g.quer...@gmail.com on 18 Feb 2015 at 8:14