Re: [Rpm-maint] [rpm-software-management/rpm] '#' symbol to ignore a macro statement does not valid. (#121)
FWIW, in rpm >= 4.15 there's now a "real" commenting directive in the form of M4-inspired %dnl, see https://github.com/rpm-software-management/rpm/issues/158, https://github.com/rpm-software-management/rpm/commit/44180fc7400ea8e67a13c5581459ad13f1d14103 and https://lists.fedoraproject.org/archives/list/de...@lists.fedoraproject.org/message/7Q3BZ6GTAKFDJMNOLNJJENMWCPQTTET7/ for more info. -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/issues/121#issuecomment-506275411___ Rpm-maint mailing list Rpm-maint@lists.rpm.org http://lists.rpm.org/mailman/listinfo/rpm-maint
Re: [Rpm-maint] [rpm-software-management/rpm] '#' symbol to ignore a macro statement does not valid. (#121)
@Conan-Kudo If I had just a few packages with a few developers, I would do that. When you have more than a thousand packages with more developers, you can't afford that. Even if you correct hundreds of packages, you will get new incoming commits with yet another violations. You need something automatic: either give a build error (so that the developer can't ignore it) or do not expand the macros (so that the developer may ignore it). -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/issues/121#issuecomment-272172594___ Rpm-maint mailing list Rpm-maint@lists.rpm.org http://lists.rpm.org/mailman/listinfo/rpm-maint
Re: [Rpm-maint] [rpm-software-management/rpm] '#' symbol to ignore a macro statement does not valid. (#121)
> Adding % to % is just a workaround and not too intuitive for developers > causing many build fails. Right. Actually, many developers have repetitively been making a incorrect statment in their ./*.spec files. -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/issues/121#issuecomment-272134161___ Rpm-maint mailing list Rpm-maint@lists.rpm.org http://lists.rpm.org/mailman/listinfo/rpm-maint
Re: [Rpm-maint] [rpm-software-management/rpm] '#' symbol to ignore a macro statement does not valid. (#121)
Yes, we do have a workaround (adding % for every % in a comment). But as long as correcting it at rpm itself is not too complex, why don't we fix it with rpm itself? Adding % to % is just a workaround and not too intuitive for developers causing many build fails. -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/issues/121#issuecomment-272122130___ Rpm-maint mailing list Rpm-maint@lists.rpm.org http://lists.rpm.org/mailman/listinfo/rpm-maint
Re: [Rpm-maint] [rpm-software-management/rpm] '#' symbol to ignore a macro statement does not valid. (#121)
I dont see what more there is to explain. Macros are expanded everywhere including what appear to be comments in spec. If you need to escape it to avoid expansion then double percent (%%) is the way to do it. -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/issues/121#issuecomment-271810454___ Rpm-maint mailing list Rpm-maint@lists.rpm.org http://lists.rpm.org/mailman/listinfo/rpm-maint
Re: [Rpm-maint] [rpm-software-management/rpm] '#' symbol to ignore a macro statement does not valid. (#121)
Closed #121. -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/issues/121#event-918754747___ Rpm-maint mailing list Rpm-maint@lists.rpm.org http://lists.rpm.org/mailman/listinfo/rpm-maint
Re: [Rpm-maint] [rpm-software-management/rpm] '#' symbol to ignore a macro statement does not valid. (#121)
\CC: @pmatilai, @ffesti, @ignatenkobrain, @myungjoo , @hk57kim , @jyoungyun -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/issues/121#issuecomment-271807885___ Rpm-maint mailing list Rpm-maint@lists.rpm.org http://lists.rpm.org/mailman/listinfo/rpm-maint
[Rpm-maint] [rpm-software-management/rpm] '#' symbol to ignore a macro statement does not valid. (#121)
We sometime use "#" symbol to append some contents in ./spec file. This issue describes incorrect operation of "#" symbol in case that we try to ignore a macro line (e.g. %define . . . ) in ./spec file. For example, the '#' (hash character) symbol to invalidate a macro statement does not valid as following: * It's not okay. # symbole is not available even though we try to use "#" symbol. ``` # %define __debug_install_post%{nil} # %define debug_package %{nil} ``` * It's okay if I remove specified lines: ``` -%define __debug_install_post%{nil} -%define debug_package %{nil} ``` * It's okay if I remove "%" symbol behine "#" symbol: ``` -# define __debug_install_post%{nil} -# define debug_package %{nil} ``` * Reference: http://rpm5.org/docs/api/macros.html Recenlty, I have found an instruction to solve this issue from the Fedora documentation webpage as following: https://docs.fedoraproject.org/en-US/Fedora_Draft_Documentation/0.1/html/Packagers_Guide/chap-Packagers_Guide-Spec_File_Reference-Comments.html **Instruction**: Because macros are expanded first, do not insert any multiline macros in a comment. If you want to comment out a line with a macro, double the percent signs (%%) as in the following example: `# %%configure` Does we always have to use double percent sign? My question is why we cannot use a single percent sign? Anyone that has a similar experiecne like me? -- You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub: https://github.com/rpm-software-management/rpm/issues/121___ Rpm-maint mailing list Rpm-maint@lists.rpm.org http://lists.rpm.org/mailman/listinfo/rpm-maint