grep - Patches: patch #7017, dlopen PCRE
You are not allowed to post comments on this tracker with your current authentication level.
patch #7017: dlopen PCRE
Submitter: | Reuben Thomas <rrt> | ||
Submitted: | Sat 05 Dec 2009 03:10:12 PM UTC | ||
Category: | None | Priority: | 5 - Normal |
Status: | In Progress | Privacy: | Public |
Assigned to: | None | Open/Closed: | Open |
Jump to the original submission
Wed 22 Aug 2012 05:39:35 PM UTC, comment #19: |
Reuben Thomas <rrt> |
Fri 12 Mar 2010 11:39:45 AM UTC, comment #18: Patch updated with soname detection. |
Reuben Thomas <rrt> |
Thu 11 Mar 2010 03:08:41 PM UTC, comment #17: Hmm, yeah, it would've worked if pcre.h hadn't used extern. Go ahead with your ppp then! |
Paolo Bonzini <bonzini> |
Thu 11 Mar 2010 03:01:52 PM UTC, comment #16: This does not work either:
|
Reuben Thomas <rrt> |
Thu 11 Mar 2010 01:06:52 PM UTC, comment #15: I think you need a tweak:
|
Paolo Bonzini <bonzini> |
Thu 11 Mar 2010 11:33:13 AM UTC, comment #14: I'm aware that typeof is non-ISO (but it is supported by at least Metrowerks as well as GCC), hence my test in configure.ac. I propose to be happy to fail on those systems that support dlopen but don't have a compiler with typeof.
|
Reuben Thomas <rrt> |
Thu 11 Mar 2010 08:49:13 AM UTC, comment #13: Looks nice, but typeof is a GCC extension. Can you check if it works to do something like
|
Paolo Bonzini <bonzini> |
Thu 11 Mar 2010 12:02:49 AM UTC, comment #12: Thanks for the outline, I'll attempt to fill in the blanks. |
Reuben Thomas <rrt> |
Wed 10 Mar 2010 11:50:45 PM UTC, comment #11: I have updated the patch to the one I meant to post, sorry about that. |
Reuben Thomas <rrt> |
Wed 10 Mar 2010 11:46:03 PM UTC, comment #10: yes, that configure.ac check looks correct, but that is certainly not in any of the posted patches so far.
|
Mike Frysinger <vapier> |
Wed 10 Mar 2010 11:37:52 PM UTC, comment #9: So, I seem to be able to find the soname at least on an ELF system as follows:
|
Reuben Thomas <rrt> |
Wed 10 Mar 2010 11:33:22 PM UTC, comment #8: I believe the configure.ac test is correct. Here is the code:
|
Reuben Thomas <rrt> |
Wed 10 Mar 2010 11:24:35 PM UTC, comment #7: did you post the wrong file ? the latest patch still doesnt check the result of AC_CHECK_LIB(), and it's dlopening libpcre.so.
|
Mike Frysinger <vapier> |
Wed 10 Mar 2010 09:51:07 PM UTC, comment #6: I have fixed configure.ac to check the actual result of the test.
|
Reuben Thomas <rrt> |
Wed 10 Mar 2010 03:30:28 PM UTC, comment #5: a configure test wouldnt be useful either. people building packages will have libpcre.so on their system so the configure test would pass. but the systems where that package gets deployed will fail most of the time because people arent installing the libpcre development files. plus, libpcre.so could be a linker script and not an actual ELF.
|
Mike Frysinger <vapier> |
Wed 10 Mar 2010 03:24:01 PM UTC, comment #4: Attached, an updated version of the patch that uses dlopen if available and desired, and cleans up the code somewhat, in
|
Reuben Thomas <rrt> |
Mon 08 Mar 2010 05:20:40 PM UTC, comment #3: This would be acceptable together with a configure test that dlopen("libpcre.so"). I don't think we want something as complicated as libltdl for grep. |
Paolo Bonzini <bonzini> |
Sat 05 Dec 2009 10:15:33 PM UTC, comment #2: As I said above, I need to know which dynamic loading mechanism to use first. |
Reuben Thomas <rrt> |
Sat 05 Dec 2009 10:12:48 PM UTC, comment #1: you cant dlopen(libpcre.so). you need to figure out the SONAME you're currently linking against and load that. |
Mike Frysinger <vapier> |
Sat 05 Dec 2009 03:10:12 PM UTC, original submission:
This patch dlopens libpcre, allowing PCRE support on systems with grep in /bin and libpcre in /usr/lib. Patch is against current git head.
|
Reuben Thomas <rrt> |
Depends on the following items: None found
Items that depend on this one: None found
There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.
Follow 6 latest changes.
Date | Changed by | Updated Field | Previous Value | => | Replaced by |
---|---|---|---|---|---|
2010-03-12 | rrt | Attached File | - | ![]() |
Added 0001-Optionally-dlopen-PCRE.patch, #19919 |
2010-03-10 | rrt | Attached File | - | ![]() |
Added 0001-Optionally-dlopen-PCRE.patch, #19906 |
2010-03-10 | rrt | Attached File | - | ![]() |
Added 0001-Optionally-dlopen-PCRE.patch, #19905 |
2010-03-10 | rrt | Attached File | - | ![]() |
Added 0001-Optionally-dlopen-PCRE.patch, #19900 |
2010-03-08 | bonzini | Status | None | ![]() |
In Progress |
2009-12-05 | rrt | Attached File | - | ![]() |
Added grep-dlopen-pcre.diff, #19205 |
It seems there is no interest in this patch. Debian & Ubuntu, which I use, have had a similar but simpler (because GNU-specific) patch installed for some years (which I also wrote!), so I have little incentive to keep updating the patch.
As far as I can see, the latest version of the patch is pretty much fine modulo minor tweaks, except that the C code patch must now be applied to pcresearch.c, not search.c.
If anyone would like to knock the patch into shape for current grep and install it, be my guest; it would also reduce the number of patches that Debian needs by one.