commit-classpath
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[commit-cp] [bugs #12016] what version of sed is needed by check_jni_met


From: anonymous
Subject: [commit-cp] [bugs #12016] what version of sed is needed by check_jni_methods?
Date: Fri, 18 Feb 2005 02:09:20 +0000
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.5) Gecko/20041107 Firefox/1.0

URL:
  <http://savannah.gnu.org/bugs/?func=detailitem&item_id=12016>

                 Summary: what version of sed is needed by check_jni_methods?
                 Project: classpath
            Submitted by: None
            Submitted on: Fri 02/18/2005 at 02:09
                Category: classpath
                Severity: 5 - Average
                  Status: None
                 Privacy: Public
             Assigned to: None
             Open/Closed: Open
        Platform Version: MacOS X

    _______________________________________________________

Details:

What version of sed is needed by check_jni_methods?



Understandably, it does not work with BSD sed which is installed by default
on MacOS X.



However, it also doesn't work with GNU sed 4.0.5 which can be installed via
"fink install sed".  The reason is that it uses \w, which "info sed" says
should match letters, digits, and underscore.  However, it doesn't seem to
match digits.  With the following patch, the script runs to completion
without complaining:



--- check_jni_methods.sh.virgin Thu Feb 17 20:20:43 2005

+++ check_jni_methods.sh        Thu Feb 17 20:27:11 2005

@@ -7,13 +7,13 @@

 # Find all methods defined in the header files generated

 # from the java source files.

 grep -h '^JNIEXPORT .* Java_' include/*.h | \

-       sed -e 's,^JNIEXPORT .* JNICALL \(Java_\w*\) (.*$,\1,' | \

+       sed -e 's,^JNIEXPORT .* JNICALL \(Java_[A-Za-z0-9_]*\) (.*$,\1,' | \

        sort > $TMPFILE

 

 # Find all methods in the JNI C source files.

 find native/jni -name \*.c | \

        xargs grep -h '^Java_' | \

-       sed -e 's,^\(Java_\w*\) *(.*$,\1,' \

+       sed -e 's,^\(Java_[A-Za-z0-9_]*\) *(.*$,\1,' \

        | sort > $TMPFILE2

 

 # Write temporary ignore file.










    _______________________________________________________

This item URL is:

  <http://savannah.gnu.org/bugs/?func=detailitem&item_id=12016>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/





reply via email to

[Prev in Thread] Current Thread [Next in Thread]