Message ID | 20180510111748.26293-1-fontaine.fabrice@gmail.com |
---|---|
State | Accepted |
Headers | show |
Series | [1/1] snort: fix build on sparc v8 | expand |
Fabrice, All, On 2018-05-10 13:17 +0200, Fabrice Fontaine spake thusly: > Add patch to remove -mcpu=v9 before checking sparc architecture > > Fixes: > - http://autobuild.buildroot.net/results/59625daa154e3136171dcb89bdc3b8b31dc85021 > > Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com> Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr> > --- > package/snort/0005-fix-sparc.patch | 28 ++++++++++++++++++++++++++++ > 1 file changed, 28 insertions(+) > create mode 100644 package/snort/0005-fix-sparc.patch > > diff --git a/package/snort/0005-fix-sparc.patch b/package/snort/0005-fix-sparc.patch > new file mode 100644 > index 0000000000..14792d2c59 > --- /dev/null > +++ b/package/snort/0005-fix-sparc.patch > @@ -0,0 +1,28 @@ > +When checking if the architecture supports the %time register > +instruction, do not force -mcpu to v9 while doing so. Otherwise it's > +like "let's see if this v9 instruction exists when I force the compiler > +to think I'm using v9", which is non-sensical. > + > +Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com> > + > +diff -Naurp ./snort-2.9.11.1-orig/configure.in snort-2.9.11.1/configure.in > +--- ./snort-2.9.11.1-orig/configure.in 2018-05-10 12:20:19.253510678 +0200 > ++++ snort-2.9.11.1/configure.in 2018-05-10 12:40:18.547584998 +0200 I was goign to request a git-formatted patch, but snort-2 is not maintained in the open... Only snort-3 is on github... Regards, Yann E. MORIN. > +@@ -942,8 +942,6 @@ fi > + > + # check for sparc %time register > + if eval "echo $host_cpu|grep -i sparc >/dev/null"; then > +- OLD_CFLAGS="$CFLAGS" > +- CFLAGS="$CFLAGS -mcpu=v9 " > + AC_MSG_CHECKING([for sparc %time register]) > + AC_RUN_IFELSE( > + [AC_LANG_PROGRAM( > +@@ -957,8 +955,6 @@ if eval "echo $host_cpu|grep -i sparc >/ > + AC_MSG_RESULT($sparcv9) > + if test "x$sparcv9" = "xyes"; then > + AC_DEFINE([SPARCV9],[1],[For sparc v9 with %time register]) > +- else > +- CFLAGS="$OLD_CFLAGS" > + fi > + fi > + > -- > 2.14.1 > > _______________________________________________ > buildroot mailing list > buildroot@busybox.net > http://lists.busybox.net/mailman/listinfo/buildroot
Hello, +Sergio in Cc. On Thu, 10 May 2018 13:17:48 +0200, Fabrice Fontaine wrote: > Add patch to remove -mcpu=v9 before checking sparc architecture > > Fixes: > - http://autobuild.buildroot.net/results/59625daa154e3136171dcb89bdc3b8b31dc85021 > > Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com> > --- > package/snort/0005-fix-sparc.patch | 28 ++++++++++++++++++++++++++++ > 1 file changed, 28 insertions(+) > create mode 100644 package/snort/0005-fix-sparc.patch I would have preferred a Git-formatted patch, because the 4 existing patches on the snort package are Git-formatted. However, I haven't been able to find an upstream Git repository for Snort, so I'm wondering how the existing Git-formatted patches have been generated. Perhaps from a repository created locally using git init+git add ? Sergio, since you added the snort package, how did you generate the patches ? Best regards, Thomas
Hello, > However, I haven't been able to find an upstream Git repository for > Snort, so I'm wondering how the existing Git-formatted patches have > been generated. Perhaps from a repository created locally using git > init+git add ? > > Sergio, since you added the snort package, how did you generate the > patches ? Yes, I manually created the git repository to generate the patches. I have also sent the patches upstream and ping one time after a month, but got no responses so far. Best regards, Sergio Prado <div dir="ltr">Hello,<br><br>> However, I haven't been able to find an upstream Git repository for<br>> Snort, so I'm wondering how the existing Git-formatted patches have<br>> been generated. Perhaps from a repository created locally using git<br>> init+git add ?<br>><br>> Sergio, since you added the snort package, how did you generate the<br>> patches ?<br><br><div>Yes, I manually created the git repository to generate the patches. I have also sent the patches upstream and ping one time after a month, but got no responses so far.</div><div><br></div><div>Best regards,</div><div><br></div><div>Sergio Prado<br></div></div>
Hello, On Mon, 14 May 2018 13:56:29 -0300, Sergio Prado wrote: > > However, I haven't been able to find an upstream Git repository for > > Snort, so I'm wondering how the existing Git-formatted patches have > > been generated. Perhaps from a repository created locally using git > > init+git add ? > > > > Sergio, since you added the snort package, how did you generate the > > patches ? > > Yes, I manually created the git repository to generate the patches. OK, that explains the Git-formatted patches, without any obvious upstream Git repository available online. > I have also sent the patches upstream and ping one time after a > month, but got no responses so far. OK, too bad. Is snort unmaintained ? Is upstream focused on this snort3 project ? Best regards, Thomas
Hello, > > I have also sent the patches upstream and ping one time after a > > month, but got no responses so far. > > OK, too bad. Is snort unmaintained ? Is upstream focused on this snort3 > project ? As far as I know, it is still maintained. The last release is from 2017-12-06. But I think brand new features are being implemented in 3.X. I could bump to 3.X, but since there are some compatibility issues between 2.X and 3.X, that would impact 2.X users. We could also have both versions in Buildroot. What do you think? Best regards, Sergio Prado <div dir="ltr">Hello,<br><br>> > I have also sent the patches upstream and ping one time after a<br>> > month, but got no responses so far.<br>><br>> OK, too bad. Is snort unmaintained ? Is upstream focused on this snort3<br>> project ?<br><br><div>As far as I know, it is still maintained. The last release is from 2017-12-06. But I think brand new features are being implemented in 3.X.</div><div><br></div><div>I could bump to 3.X, but since there are some compatibility issues between 2.X and 3.X, that would impact 2.X users. We could also have both versions in Buildroot. </div><div><br></div><div>What do you think?</div><div><br></div><div>Best regards,</div><div><br></div><div>Sergio Prado<br></div></div>
Dear Thomas, 2018-05-15 14:41 GMT+02:00 Thomas Petazzoni <thomas.petazzoni@bootlin.com>: > Hello, > > On Mon, 14 May 2018 13:56:29 -0300, Sergio Prado wrote: > > > > However, I haven't been able to find an upstream Git repository for > > > Snort, so I'm wondering how the existing Git-formatted patches have > > > been generated. Perhaps from a repository created locally using git > > > init+git add ? > > > > > > Sergio, since you added the snort package, how did you generate the > > > patches ? > > > > Yes, I manually created the git repository to generate the patches. > > OK, that explains the Git-formatted patches, without any obvious > upstream Git repository available online. > So, do you want to reformat my patch? What is the best practice, should we always send git formatted patch even if there is no official Git repository? > > > I have also sent the patches upstream and ping one time after a > > month, but got no responses so far. > > OK, too bad. Is snort unmaintained ? Is upstream focused on this snort3 > project ? > Actually snort is most widely used than snort3. snort3 is still in alpha. I have a patch for snort3 package but snort and snort3 don't use the same version of daq library :-/ > > Best regards, > > Thomas > -- > Thomas Petazzoni, CTO, Bootlin (formerly Free Electrons) > Embedded Linux and Kernel engineering > https://bootlin.com > Best Regards, Fabrice <div dir="ltr">Dear Thomas,<br><div class="gmail_extra"><br><div class="gmail_quote">2018-05-15 14:41 GMT+02:00 Thomas Petazzoni <span dir="ltr"><<a href="mailto:thomas.petazzoni@bootlin.com" target="_blank">thomas.petazzoni@bootlin.com</a>></span><wbr>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hello,<br> <span><br> On Mon, 14 May 2018 13:56:29 -0300, Sergio Prado wrote:<br> <br> > > However, I haven't been able to find an upstream Git repository for<br> > > Snort, so I'm wondering how the existing Git-formatted patches have<br> > > been generated. Perhaps from a repository created locally using git<br> > > init+git add ?<br> > ><br> > > Sergio, since you added the snort package, how did you generate the<br> > > patches ? <br> > <br> > Yes, I manually created the git repository to generate the patches.<br> <br> </span>OK, that explains the Git-formatted patches, without any obvious<br> upstream Git repository available online.<br></blockquote><div>So, do you want to reformat my patch? What is the best practice, should we always send git formatted patch even if there is no official Git repository? </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"> <span><br> > I have also sent the patches upstream and ping one time after a<br> > month, but got no responses so far.<br> <br> </span>OK, too bad. Is snort unmaintained ? Is upstream focused on this snort3<br> project ?<br></blockquote><div>Actually snort is most widely used than snort3. snort3 is still in alpha. I have a patch for snort3 package but snort and snort3 don't use the same version of daq library :-/</div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"> <div class="m_-7517214424679486057HOEnZb"><div class="m_-7517214424679486057h5"><br> Best regards,<br> <br> Thomas<br> -- <br> Thomas Petazzoni, CTO, Bootlin (formerly Free Electrons)<br> Embedded Linux and Kernel engineering<br> <a href="https://bootlin.com" rel="noreferrer" target="_blank">https://bootlin.com</a><br> </div></div></blockquote></div>Best Regards,</div><div class="gmail_extra"><br></div><div class="gmail_extra">Fabrice</div></div>
Hello, On Tue, 15 May 2018 16:59:41 +0200, Fabrice Fontaine wrote: > > OK, that explains the Git-formatted patches, without any obvious > > upstream Git repository available online. > > So, do you want to reformat my patch? What is the best practice, should we > always send git formatted patch even if there is no official Git > repository? The only clear policy that I'm trying to enforce is "if the project uses Git as its version control system, then we want Git-formatted patches". If on the other hand the projects is not using Git, then we don't have a clear policy, and so far we have been accepting patches that are not Git-formatted in such a case. The snort situation caught my eye because your patch was not Git-formatted, but the existing patches were. > > OK, too bad. Is snort unmaintained ? Is upstream focused on this snort3 > > project ? > > > Actually snort is most widely used than snort3. snort3 is still in alpha. I > have a patch for snort3 package but snort and snort3 don't use the same > version of daq library :-/ We could have a separate snort3 package, and a separate package for the daq library as well. If the daq libraries are API incompatible, it makes sense to have two separate packages for them. Best regards, Thomas
diff --git a/package/snort/0005-fix-sparc.patch b/package/snort/0005-fix-sparc.patch new file mode 100644 index 0000000000..14792d2c59 --- /dev/null +++ b/package/snort/0005-fix-sparc.patch @@ -0,0 +1,28 @@ +When checking if the architecture supports the %time register +instruction, do not force -mcpu to v9 while doing so. Otherwise it's +like "let's see if this v9 instruction exists when I force the compiler +to think I'm using v9", which is non-sensical. + +Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com> + +diff -Naurp ./snort-2.9.11.1-orig/configure.in snort-2.9.11.1/configure.in +--- ./snort-2.9.11.1-orig/configure.in 2018-05-10 12:20:19.253510678 +0200 ++++ snort-2.9.11.1/configure.in 2018-05-10 12:40:18.547584998 +0200 +@@ -942,8 +942,6 @@ fi + + # check for sparc %time register + if eval "echo $host_cpu|grep -i sparc >/dev/null"; then +- OLD_CFLAGS="$CFLAGS" +- CFLAGS="$CFLAGS -mcpu=v9 " + AC_MSG_CHECKING([for sparc %time register]) + AC_RUN_IFELSE( + [AC_LANG_PROGRAM( +@@ -957,8 +955,6 @@ if eval "echo $host_cpu|grep -i sparc >/ + AC_MSG_RESULT($sparcv9) + if test "x$sparcv9" = "xyes"; then + AC_DEFINE([SPARCV9],[1],[For sparc v9 with %time register]) +- else +- CFLAGS="$OLD_CFLAGS" + fi + fi +
Add patch to remove -mcpu=v9 before checking sparc architecture Fixes: - http://autobuild.buildroot.net/results/59625daa154e3136171dcb89bdc3b8b31dc85021 Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com> --- package/snort/0005-fix-sparc.patch | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 package/snort/0005-fix-sparc.patch