Coder Social home page Coder Social logo

Comments (4)

aostruszka avatar aostruszka commented on May 20, 2024

I like that!

I'm going to "pull" that from you. With minor changes: I'm going to keep the clean target intact. This target is meant to clean all "objects" only. In case of using separate build directories for different build modes your rule will only delete one such subdirectory (e.g. obj/debug while keeping obj/release and obj/profile). Deletion of separate objdirs is meant as a job for dist_clean target.

Thank you! I never liked the .fake_file solution and I know that I've read about order-only prerequisites but it seems that when I read about that my .fake_file dislike was buried somewhere else in my brain and it never clicked with "aha" moment.

Best regards
Andrzej

from nonrec-make.

aostruszka avatar aostruszka commented on May 20, 2024

Uploaded now f3f07d8.
Please take a look at that (it is on eval_hdr branch for now - this will be merged to master once I hear some feedback about that proposal :)).
I'm closing this one.

Regards
Andrzej

from nonrec-make.

torpesco avatar torpesco commented on May 20, 2024

Hi Andrzej,

Personally, I like the proposal. =P Realized seeing it that I forgot to go back to update ?R and ^R in mine.

It took me a bit to understand the .SECONDARY target for $(OBJPATH). In the other project we have with output directories, we don't use .SECONDARY, and it's fine. The one difference I see is that instead of "| $(OBJPATH)" on the %.o : %.c lines, we have a separate $(OBJS): | $(OBJPATH) line -- more like the make manual.

Any idea why in one method $(OBJPATH) is treated as intermediate, and in the other it's not?

Thanks,
James.

from nonrec-make.

aostruszka avatar aostruszka commented on May 20, 2024

James

Initially I removed the .SECONDARY for OBJPATH but then I ran that on my examples and it turned out that make considers those directories as intermediate products (as you've mentioned) and then tries to remove them at the end giving a bunch of error messages.

I have not yet understood why they are considered intermediate targets, so for now I'm going to keep it like it is.
If you'll have some insight then don't hesitate and share it with me :)

Regards
Andrzej

from nonrec-make.

Related Issues (19)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.