escape # in Makefile - Aix

This is a discussion on escape # in Makefile - Aix ; Problem: Any occurence of # in Makefile cannot be escaped. e.g. /my/special/file\#001.txt This is okay for make on other platforms like sun4v/sol86/lnx but the # is taken as comment start using make on AIX(5.3.0), in spite of the escape using ...

+ Reply to Thread
Results 1 to 6 of 6

Thread: escape # in Makefile

  1. escape # in Makefile

    Problem:

    Any occurence of # in Makefile cannot be escaped. e.g.
    /my/special/file\#001.txt

    This is okay for make on other platforms like sun4v/sol86/lnx but the
    # is taken as comment start using make on AIX(5.3.0), in spite of the
    escape using a '\'.

    gmake/clearmake work correctly without issues even on AIX.

    I searched this group for an answer to this problem, there was one
    similar question posted in 1996 which indicated that there is no known
    resolution to this issue other than to use gmake.

    -Tanvir

  2. Re: escape # in Makefile

    I thoughts makefiles used $ to escape.

    --
    Message posted using http://www.talkaboutcomputing.com/group/comp.unix.aix/
    More information at http://www.talkaboutcomputing.com/faq.html


  3. Re: escape # in Makefile

    porter2 wrote:
    > I thoughts makefiles used $ to escape.
    >
    > --
    > Message posted using http://www.talkaboutcomputing.com/group/comp.unix.aix/
    > More information at http://www.talkaboutcomputing.com/faq.html
    >

    I thought $ was for macro.

  4. Re: escape # in Makefile

    I've got various makefiles where I need to use $ in a command, so I use $$,
    just wondered if it could be used with $#.

    --
    Message posted using http://www.talkaboutcomputing.com/group/comp.unix.aix/
    More information at http://www.talkaboutcomputing.com/faq.html


  5. Re: escape # in Makefile

    porter2 wrote:
    > I've got various makefiles where I need to use $ in a command, so I use $$,
    > just wondered if it could be used with $#.


    It's not an escape, it's a macro. $$ is a preset macro whose value is $.

  6. Re: escape # in Makefile


    I found an alternate make in our corporate infrastructure (other than
    the problematic /usr/bin/make) which resolves the problem. I am not
    sure about where that version of make comes from, but as long as it
    fixes my problem, i'm happy.

    -Tanvir

+ Reply to Thread