You can subscribe to this list here.
2002 |
Jan
|
Feb
|
Mar
|
Apr
(4) |
May
(7) |
Jun
(1) |
Jul
(4) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
---|---|---|---|---|---|---|---|---|---|---|---|---|
2003 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(6) |
Jul
(8) |
Aug
(4) |
Sep
|
Oct
|
Nov
|
Dec
(1) |
2004 |
Jan
(1) |
Feb
|
Mar
|
Apr
(3) |
May
(1) |
Jun
(1) |
Jul
|
Aug
|
Sep
(2) |
Oct
|
Nov
|
Dec
|
2007 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
2015 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
2017 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(2) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Bernhard B. <ma...@ba...> - 2003-06-26 08:15:51
|
Hi Ben, I have it on my todo list, but to be honest: currently it's summer and it's hot and so I have trouble to discipline myself and sit in front of my computer. So please go ahead and implement it - it would take another few weeks for me. I have a third alternative: void setVar(int which_variable, int value); void setVar(String which_variable, String value); int getVar(int which_variable); String getVar(String which_variable); public static final int INHIBIT_COMPLETION = 1; public static final String BASIC_QUOTE_CHARACTERS = "2"; etc. which_variable is always a symbolic constant, so the user won't care if it's an int or a string. If fact, it is your solution (2) with IntVar==int, and StrVar==String. I have no objections using setReadlineVar()... if you prefer more verbose method-names. Bernhard > If you like I'd be happy to implement this, as either: > > or > > (2) > void setReadlineVar(IntVar which_variable, int value); > void setReadlineVar(StrVar which_variable, String value); > int getReadlineVar(IntVar which_variable); > String getReadlineVar(StrVar which_variable); > > public static final IntVar INHIBIT_COMPLETION; > public static final StrVar BASIC_QUOTE_CHARACTERS; > (etc etc) > > This solution allows the single getReadlineVar() / setReadlineVar() > syntax to be used, and the user need not even know about the different > type-specific classes IntVar, StrVar, etc.: > > setReadlineVar(INHIBIT_COMPLETION, true); > > The IntVar and StrVar classes are empty classes that simply allow the > compiler to handle the overloading of getReadlineVar() with different > return types. > > My preferred solution is (2), simply because it's simpler from the user's > point of view. Is this okay with you? > > Ben. |
From: Ben B. <ba...@de...> - 2003-06-26 01:04:18
|
Hi. > > On the other hand, if the variables were public, > > there would be even less java-functions (e.g. > > setReadlineVar(INHIBIT_COMPLETION,INHIBIT_COMPLETION_TRUE)) > > This solution looks nicer to me, but then again that's just me. > Although I'd be tempted to use java native types for the values, e.g., > > setReadlineVar(INHIBIT_COMPLETION, true) > > These should be easy to convert in the .c file in the few cases where > the compiler doesn't do it automatically. I wouldn't mind having this working well before debian 3.1 is released, since I'd then like to update jython to use these patches and so on, with the ultimate aim for jython users to be able to use tabs at the jython command prompt. If you like I'd be happy to implement this, as either: (1) void setReadlineIntVar(int which_variable, int value); int getReadlineIntVar(int which_variable); void setReadlineStrVar(int which_variable, String value); String getReadlineStrVar(int which_variable); public static final int INHIBIT_COMPLETION; public static final int BASIC_QUOTE_CHARACTERS; (etc etc) (The rationale for splitting into int and str routines is because even though you could potentially overload setReadlineVar(), you could not overload getReadlineVar() in this way.) or (2) void setReadlineVar(IntVar which_variable, int value); void setReadlineVar(StrVar which_variable, String value); int getReadlineVar(IntVar which_variable); String getReadlineVar(StrVar which_variable); public static final IntVar INHIBIT_COMPLETION; public static final StrVar BASIC_QUOTE_CHARACTERS; (etc etc) This solution allows the single getReadlineVar() / setReadlineVar() syntax to be used, and the user need not even know about the different type-specific classes IntVar, StrVar, etc.: setReadlineVar(INHIBIT_COMPLETION, true); The IntVar and StrVar classes are empty classes that simply allow the compiler to handle the overloading of getReadlineVar() with different return types. My preferred solution is (2), simply because it's simpler from the user's point of view. Is this okay with you? Ben. |
From: Ben B. <ba...@de...> - 2003-06-08 01:05:26
|
> On the other hand, if the variables were public, > there would be even less java-functions (e.g. > setReadlineVar(INHIBIT_COMPLETION,INHIBIT_COMPLETION_TRUE)) This solution looks nicer to me, but then again that's just me. Although I'd be tempted to use java native types for the values, e.g., setReadlineVar(INHIBIT_COMPLETION, true) These should be easy to convert in the .c file in the few cases where the compiler doesn't do it automatically. Ben. :) |
From: Bernhard B. <ma...@ba...> - 2003-06-07 17:29:02
|
Hi Ben, I have been thinking about the issue of setting global readline variables already. I thought about writing one c-function and adding a number of static final int variables to the Readline-class. These could be private, the public methods (e.g. setInhibitCompletion()) would then all call the same method with the correct constant. On the other hand, if the variables were public, there would be even less java-functions (e.g. setReadlineVar(INHIBIT_COMPLETION,INHIBIT_COMPLETION_TRUE)) There are in fact quite a number of variables which could be exposed this way. What do you think about that? Bernhard > Hi. Attached is a patch for java-readline that adds two extra functions: > > setInhibitCompletion(bool) > getInhibitCompletion() > > These functions correspond to setting and retrieving the global readline > variable rl_inhibit_completion, which switches tab completion on and off. > > Inhibiting tab completion is particularly important for jython, since you > frequently want to insert tab characters directly into the input line. If > you're happy with this patch then I'll submit a patch for jython that where > possible calls setInhibitCompletion(false) upon initialisation of a > ReadlineConsole. > > I've tested these patches under both GNU readline and BSD editline. > |
From: Bernhard B. <ma...@ba...> - 2003-06-07 17:29:00
|
Hi Rune, I will think about this and will comment soon. Bernhard > Hello, > > I have a request for an enhancement to the java-readline library. > > Readline.iLib is a private variable. The only way to set it, is > through Readline.load, which attempts to load the file through > System.loadLibrary(). > > This does not work if the location of the so file is not known prior > to starting of the java program (in my case, it is a jar file), and > java isn't to happy about honoring a > System.setProperty("java.library.path", path). However, there is also > System.load(), which accepts a filename as argument, thus one could, > after determining os, extract the relevant so file to a temp directory > and load it from there. > > It would therefore be great if you could either add a test to > Readline.load() to check if the library is already loaded (I've been > unable to find out how to do this), or simply add a new public method > setIlib(). > > Regards, > Rune Fr=F8ysa |
From: Bernhard B. <ma...@ba...> - 2002-07-26 09:14:11
|
Hi David, I have been working on this issue for quite a while. The first patch is=20 similar to what I have found. But I already have problems linking the sha= red=20 library. You have to make sure that you create .dll instead of .so shared= =20 libraries. According to the cygwin-manual, that's not simple (just using = gcc=20 -shared ... is not enough). My problem is that the linker can't resolve a reference to _errno. But th= at=20 does not seem to be your problem. Maybe things have changed. Could you gi= ve=20 me your exact cygwin-setup? Thanks, Bernhard --=20 Bernhard Bablok ma...@ba... http://www.bablokb.de |
From: David B. <da...@br...> - 2002-07-25 03:49:44
|
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <meta http-equiv="Content-Type" content="text/html;charset=ISO-8859-1"> <title></title> </head> <body> Hi,<br> <br> I seem to have fixed the compilation problem on cygnus by adding the following to src/native/org_gnu_readline_Readline.c<br> <br> <font color="#000099">#if defined (__CYGWIN__)<br> #include <w32api/windows.h><br> #include <w32api/winnt.h><br> #endif <br> </font><br> and I have attached the patchfile in this email. <br> <br> <br> However, make test fails with the following:<br> <br> $ make test<br> cd src ; make JAVAC="javac" JC_FLAGS="" java<br> make[1]: Entering directory `/cygdrive/c/Downloads/libreadline-java-0.7.3/src'<br> javac -d ../build `find . -name "*.java"`<br> make[1]: Leaving directory `/cygdrive/c/Downloads/libreadline-java-0.7.3/src'<br> cd ./build ; jar -cvmf ../etc/manifest.stub ../libreadline-java.jar *<br> added manifest<br> adding: org/(in = 0) (out= 0)(stored 0%)<br> adding: org/gnu/(in = 0) (out= 0)(stored 0%)<br> adding: org/gnu/readline/(in = 0) (out= 0)(stored 0%)<br> adding: org/gnu/readline/Readline.class(in = 4585) (out= 2062)(deflated 55%)<br> adding: org/gnu/readline/ReadlineCompleter.class(in = 194) (out= 138)(deflated 28%)<br> adding: org/gnu/readline/ReadlineLibrary.class(in = 891) (out= 492)(deflated 44%)<br> adding: org/gnu/readline/ReadlineReader.class(in = 2932) (out= 1488)(deflated 49%)<br> adding: test/(in = 0) (out= 0)(stored 0%)<br> adding: test/ReadlineTest.class(in = 2245) (out= 1280)(deflated 42%)<br> adding: test/TestCompleter.class(in = 532) (out= 364)(deflated 31%)<br> cd src; make T_LIBS="JavaReadline " JAVAINCLUDE="c:\j2sdk1.4.1/include" \<br> JAVANATINC="c:\j2sdk1.4.1/include/linux" native<br> make[1]: Entering directory `/cygdrive/c/Downloads/libreadline-java-0.7.3/src'<br> cd native ; make T_LIBS="JavaReadline " JAVAINCLUDE="c:\j2sdk1.4.1/include" \<br> JAVANATINC="c:\j2sdk1.4.1/include/linux" all<br> make[2]: Entering directory `/cygdrive/c/Downloads/libreadline-java-0.7.3/src/native'<br> make TG=JavaReadline lib<br> make[3]: Entering directory `/cygdrive/c/Downloads/libreadline-java-0.7.3/src/native'<br> javah -classpath ../../build -jni org.gnu.readline.Readline<br> touch org_gnu_readline_Readline.h<br> gcc -I c:\j2sdk1.4.1/include -I c:\j2sdk1.4.1/include/linux -fPIC -DJavaReadline \<br> -c org_gnu_readline_Readline.c<br> cc1: warning: -fPIC ignored for target (all code is position independent)<br> gcc -shared org_gnu_readline_Readline.o -L/usr/lib/termcap -lreadline -ltermcap -lhistory -o ../../libJavaReadline.so<br> Info: resolving _rl_readline_name by linking to __imp__rl_readline_name (auto-import)<br> Info: resolving _rl_catch_signals by linking to __imp__rl_catch_signals (auto-import)<br> Info: resolving _history_length by linking to __imp__history_length (auto-import)<br> Info: resolving _rl_completion_entry_function by linking to __imp__rl_completion_entry_function (auto-import)<br> Info: resolving _rl_line_buffer by linking to __imp__rl_line_buffer (auto-import)<br> Info: resolving _rl_completer_word_break_characters by linking to __imp__rl_completer_word_break_characters (auto-import)<br> Info: resolving _rl_basic_word_break_characters by linking to __imp__rl_basic_word_break_characters (auto-import)<br> make[3]: Leaving directory `/cygdrive/c/Downloads/libreadline-java-0.7.3/src/native'<br> make[2]: Leaving directory `/cygdrive/c/Downloads/libreadline-java-0.7.3/src/native'<br> make[1]: Leaving directory `/cygdrive/c/Downloads/libreadline-java-0.7.3/src'<br> <font color="#ff0000"><b>LD_LIBRARY_PATH=. java -jar libreadline-java.jar src/test/tinputrc<br> Exception in thread "main" java.lang.UnsatisfiedLinkError: no JavaReadline in java.library.path<br> at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1403)<br> at java.lang.Runtime.loadLibrary0(Runtime.java:788)<br> at java.lang.System.loadLibrary(System.java:832)<br> at org.gnu.readline.Readline.load(Readline.java:123)<br> at test.ReadlineTest.main(ReadlineTest.java:62)<br> make: *** [test] Error 1</b><br> </font><br> <br> Can anyone help ?<br> <br> Thanks,<br> <br> David<br> </body> </html> |
From: David B. <da...@br...> - 2002-07-25 02:25:56
|
Hi, I have just subscribed to the list and my 1st question is: Has anyone successfully compiled under cygwin ? Thanks, David |
From: David B. <da...@br...> - 2002-07-24 21:48:50
|
Hi, Has anyone compiled java readline using cygwin under win32 ? I am using the 1.4.1 jdk. The 1st problem that I found is that jni_md.h is found under the include/win32 subdirectory. Creating a soft link in the include directory took care of that nicely. But then I get the following: ... ... make TG=JavaReadline lib make[3]: Entering directory `/cygdrive/c/Downloads/libreadline-java-0.7.3/src/native' javah -classpath ../../build -jni org.gnu.readline.Readline touch org_gnu_readline_Readline.h gcc -I c:\j2sdk1.4.1/include -I c:\j2sdk1.4.1/include/linux -fPIC -DJavaReadline \ -c org_gnu_readline_Readline.c cc1.exe: warning: -fPIC ignored for target (all code is position independent) In file included from c:j2sdk1.4.1/include/jni.h:27, from org_gnu_readline_Readline.h:2, from org_gnu_readline_Readline.c:31: c:j2sdk1.4.1/include/jni_md.h:16: parse error before `jlong' c:j2sdk1.4.1/include/jni_md.h:16: warning: data definition has no type or storage class In file included from org_gnu_readline_Readline.h:2, from org_gnu_readline_Readline.c:31: c:j2sdk1.4.1/include/jni.h:108: parse error before `jlong' c:j2sdk1.4.1/include/jni.h:108: warning: no semicolon at end of struct or union c:j2sdk1.4.1/include/jni.h:112: parse error before `}' c:j2sdk1.4.1/include/jni.h:112: warning: data definition has no type or storage class c:j2sdk1.4.1/include/jni.h:255: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:270: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:277: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:284: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:291: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:298: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:305: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:307: warning: no semicolon at end of struct or union c:j2sdk1.4.1/include/jni.h:309: warning: `__stdcall__' attribute directive ignored c:j2sdk1.4.1/include/jni.h:310: `jlong' declared as function returning a function c:j2sdk1.4.1/include/jni.h:310: `jlong' redeclared as different kind of symbol c:j2sdk1.4.1/include/jni_md.h:16: previous declaration of `jlong' c:j2sdk1.4.1/include/jni.h:310: warning: data definition has no type or storage class c:j2sdk1.4.1/include/jni.h:311: warning: `__stdcall__' attribute directive ignored c:j2sdk1.4.1/include/jni.h:312: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:312: `jlong' declared as function returning a function c:j2sdk1.4.1/include/jni.h:312: warning: data definition has no type or storage class c:j2sdk1.4.1/include/jni.h:319: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:326: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:333: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:342: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:351: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:360: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:369: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:378: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:387: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:389: warning: `__stdcall__' attribute directive ignored c:j2sdk1.4.1/include/jni.h:390: `jlong' declared as function returning a function c:j2sdk1.4.1/include/jni.h:390: warning: data definition has no type or storage class c:j2sdk1.4.1/include/jni.h:391: warning: `__stdcall__' attribute directive ignored c:j2sdk1.4.1/include/jni.h:393: `jlong' declared as function returning a function c:j2sdk1.4.1/include/jni.h:393: warning: data definition has no type or storage class c:j2sdk1.4.1/include/jni.h:394: warning: `__stdcall__' attribute directive ignored c:j2sdk1.4.1/include/jni.h:396: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:396: `jlong' declared as function returning a function c:j2sdk1.4.1/include/jni.h:396: warning: data definition has no type or storage class c:j2sdk1.4.1/include/jni.h:405: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:414: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:423: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:440: warning: `__stdcall__' attribute directive ignored c:j2sdk1.4.1/include/jni.h:441: `jlong' declared as function returning a function c:j2sdk1.4.1/include/jni.h:441: warning: data definition has no type or storage class c:j2sdk1.4.1/include/jni.h:460: parse error before `jlong' c:j2sdk1.4.1/include/jni.h:474: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:481: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:488: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:495: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:502: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:509: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:511: warning: `__stdcall__' attribute directive ignored c:j2sdk1.4.1/include/jni.h:512: `jlong' declared as function returning a function c:j2sdk1.4.1/include/jni.h:512: warning: data definition has no type or storage class c:j2sdk1.4.1/include/jni.h:513: warning: `__stdcall__' attribute directive ignored c:j2sdk1.4.1/include/jni.h:514: `jlong' declared as function returning a function c:j2sdk1.4.1/include/jni.h:514: warning: data definition has no type or storage class c:j2sdk1.4.1/include/jni.h:515: warning: `__stdcall__' attribute directive ignored c:j2sdk1.4.1/include/jni.h:516: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:516: `jlong' declared as function returning a function c:j2sdk1.4.1/include/jni.h:516: warning: data definition has no type or storage class c:j2sdk1.4.1/include/jni.h:523: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:530: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:537: parse error before `jvalue' c:j2sdk1.4.1/include/jni.h:553: warning: `__stdcall__' attribute directive ignored c:j2sdk1.4.1/include/jni.h:554: `jlong' declared as function returning a function c:j2sdk1.4.1/include/jni.h:554: warning: data definition has no type or storage class c:j2sdk1.4.1/include/jni.h:573: parse error before `jlong' c:j2sdk1.4.1/include/jni.h:635: parse error before `*' c:j2sdk1.4.1/include/jni.h:636: warning: data definition has no type or storage class c:j2sdk1.4.1/include/jni.h:653: parse error before `jlong' c:j2sdk1.4.1/include/jni.h:670: parse error before `jlong' c:j2sdk1.4.1/include/jni.h:687: parse error before `jlong' c:j2sdk1.4.1/include/jni.h:731: parse error before `jlong' c:j2sdk1.4.1/include/jni.h:734: warning: `__stdcall__' attribute directive ignored c:j2sdk1.4.1/include/jni.h:735: `jlong' declared as function returning a function c:j2sdk1.4.1/include/jni.h:735: warning: data definition has no type or storage class c:j2sdk1.4.1/include/jni.h:736: parse error before `}' org_gnu_readline_Readline.c: In function `Java_org_gnu_readline_Readline_initReadlineImpl': org_gnu_readline_Readline.c:82: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:88: dereferencing pointer to incomplete type org_gnu_readline_Readline.c: In function `Java_org_gnu_readline_Readline_addToHistoryImpl': org_gnu_readline_Readline.c:128: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:132: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:133: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:135: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:140: dereferencing pointer to incomplete type org_gnu_readline_Readline.c: In function `Java_org_gnu_readline_Readline_readlineImpl': org_gnu_readline_Readline.c:159: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:163: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:164: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:166: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:170: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:177: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:179: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:183: dereferencing pointer to incomplete type org_gnu_readline_Readline.c: In function `Java_org_gnu_readline_Readline_getHistoryImpl': org_gnu_readline_Readline.c:199: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:200: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:204: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:205: dereferencing pointer to incomplete type org_gnu_readline_Readline.c: In function `Java_org_gnu_readline_Readline_getHistoryLineImpl': org_gnu_readline_Readline.c:229: dereferencing pointer to incomplete type org_gnu_readline_Readline.c: In function `Java_org_gnu_readline_Readline_readInitFileImpl': org_gnu_readline_Readline.c:255: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:259: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:260: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:262: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:266: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:272: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:274: dereferencing pointer to incomplete type org_gnu_readline_Readline.c: In function `Java_org_gnu_readline_Readline_parseAndBindImpl': org_gnu_readline_Readline.c:292: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:296: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:297: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:299: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:303: dereferencing pointer to incomplete type org_gnu_readline_Readline.c: In function `Java_org_gnu_readline_Readline_readHistoryFileImpl': org_gnu_readline_Readline.c:325: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:329: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:330: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:332: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:336: dereferencing pointer to incomplete type org_gnu_readline_Readline.c: In function `Java_org_gnu_readline_Readline_writeHistoryFileImpl': org_gnu_readline_Readline.c:354: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:358: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:359: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:361: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:365: dereferencing pointer to incomplete type org_gnu_readline_Readline.c: In function `java_completer': org_gnu_readline_Readline.c:383: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:389: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:395: dereferencing pointer to incomplete type org_gnu_readline_Readline.c: In function `Java_org_gnu_readline_Readline_setCompleterImpl': org_gnu_readline_Readline.c:417: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:418: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:419: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:420: dereferencing pointer to incomplete type org_gnu_readline_Readline.c: In function `Java_org_gnu_readline_Readline_getLineBufferImpl': org_gnu_readline_Readline.c:441: dereferencing pointer to incomplete type org_gnu_readline_Readline.c: In function `Java_org_gnu_readline_Readline_getWordBreakCharactersImpl': org_gnu_readline_Readline.c:456: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:460: dereferencing pointer to incomplete type org_gnu_readline_Readline.c: In function `Java_org_gnu_readline_Readline_setWordBreakCharactersImpl': org_gnu_readline_Readline.c:476: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:480: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:481: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:483: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:487: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:494: dereferencing pointer to incomplete type org_gnu_readline_Readline.c:496: dereferencing pointer to incomplete type make[3]: *** [../../libJavaReadline.so] Error 1 make[3]: Leaving directory `/cygdrive/c/Downloads/libreadline-java-0.7.3/src/native' make[2]: *** [JavaReadline] Error 2 make[2]: Leaving directory `/cygdrive/c/Downloads/libreadline-java-0.7.3/src/native' make[1]: *** [native] Error 2 make[1]: Leaving directory `/cygdrive/c/Downloads/libreadline-java-0.7.3/src' make: *** [build-native] Error 2 david@BRUSOWANKIN /cygdrive/c/Downloads/libreadline-java-0.7.3 $ |
From: Bernhard B. <ma...@ba...> - 2002-06-07 15:22:12
|
Hi, the patch seems reasonable and useful. I will integrate the patch in the = next=20 version. Regarding the native libs: Readline has no problems, but I don't= =20 know about Editline, since it does not work on my machines. Bernhard > Hi, > > here is a small patch to Readline.java that makes > it possible to use an alternative encoding when > using the "PureJava" readline library (passing an > encoding to the InputStreamReader). It might be an > idea to extend it to cover the native libraries > too. I didn't look at it too much. > > 93a94,95 > > > private static String encoding =3D > > System.getProperty("file.encoding", "iso-8859-1"); > > 143a146,149 > > > public static void setEncoding(String _encoding) { > > encoding =3D _encoding; > > } > > 194c200 > < iReader =3D new BufferedReader(new > InputStreamReader(System.in)); > --- > > > iReader =3D new BufferedReader(new > > InputStreamReader(System.in, encoding)); > > . -- Rasmus |
From: Henner Z. <he...@fr...> - 2002-05-13 06:46:16
|
Hi Bernhard, > I changed the implementation of the two critical functions to use a dynamic > allocated buffer instead of a fixed-sized buffer. Please have a look at the > code and test it with HenPlus. ah, cool. I'll test it. ciao, -hen |
From: Bernhard B. <ma...@ba...> - 2002-05-11 11:19:25
|
Hi Hen, I changed the implementation of the two critical functions to use a dynam= ic=20 allocated buffer instead of a fixed-sized buffer. Please have a look at t= he=20 code and test it with HenPlus. I also moved the ChangeLog file to NEWS. Since ChangeLog can be created f= rom=20 the repository, there is no need to check it in. It should be created jus= t=20 before creating a new distribution package. Bernhard |
From: Henner Z. <he...@fr...> - 2002-05-09 16:24:30
|
Hi, I modified the RPM make target in a way that allows to build the RPM within an own subdirectory; thus it is not necessary anymore to become root to build the RPM; and it is not necessary to know what is the base-target directory of the System-RPM which varies to be /usr/src/packages, /usr/src/RPM, /usr/src/redhat .. depending on the distribution. $ make rpm builds the rpm in the build/RPMS/... subdirectory. ciao, -hen |
From: Henner Z. <he...@fr...> - 2002-05-09 16:01:26
|
Hi, > Yes, there is a constant called BUF_LENGTH in > src/native/org_gnu_readline_Readline.c. A typical quick and dirty > implementation :-( of the functions utf2ucs and ucs2utf. yeah, just seen it. > Solution: these functions should allocate a buffer of correct size (a maximum > of 2*strlen(line) is needed, since utf8 codes ISO-8859-x in at most 2 bytes). > The calling function should free the memory afterwards. .. this would be best. > I could do this next weekend (provided the weatherforecast is correct). Let me > know if you want to tackle this. I am not at home this weekend, so just go ahead ;-) ciao, -hen |
From: Bernhard B. <ma...@ba...> - 2002-05-08 19:39:47
|
> Hi, > I noticed, that if we store multiple lines in the history at once (as i= t > is possible with the current CVS version), the history line is garbeled= if > the text becomes very long. > > In my little SQL-shell, I sometimes have very long selects, that go ove= r > multiple lines. If I enter such a line, add it to the history and then = go > up with the cursor (to refetch the last line in the history), that text= is > garbeled. Interestingly, the first couple of lines are readable, but > then only random characters are shown. > Could it be, that there is some limitation > of the number of bytes (like 1024) that can be stored per line in the > history .. in the c-implementation of java-readline ? And if so, is the= re > a way to modify this limit somehow ? Yes, there is a constant called BUF_LENGTH in=20 src/native/org_gnu_readline_Readline.c. A typical quick and dirty=20 implementation :-( of the functions utf2ucs and ucs2utf. Solution: these functions should allocate a buffer of correct size (a max= imum=20 of 2*strlen(line) is needed, since utf8 codes ISO-8859-x in at most 2 byt= es).=20 The calling function should free the memory afterwards. I could do this next weekend (provided the weatherforecast is correct). L= et me=20 know if you want to tackle this. Bernhard |
From: Henner Z. <he...@fr...> - 2002-05-08 11:26:09
|
Hi, I noticed, that if we store multiple lines in the history at once (as it is possible with the current CVS version), the history line is garbeled if the text becomes very long. In my little SQL-shell, I sometimes have very long selects, that go over multiple lines. If I enter such a line, add it to the history and then go up with the cursor (to refetch the last line in the history), that text is garbeled. Interestingly, the first couple of lines are readable, but then only random characters are shown. Could it be, that there is some limitation of the number of bytes (like 1024) that can be stored per line in the history .. in the c-implementation of java-readline ? And if so, is there a way to modify this limit somehow ? ciao, -hen |
From: Bernhard B. <ma...@ba...> - 2002-05-02 08:20:17
|
> I was unable to push data onto readline from Java (sort of like pushing > onto STDIN). When a user wishes to use a file from disk, i read the > file, but would like it to become part of history. Any way of > manipulating the history file ? There is a method readHistoryFile. In the current developer-version, a ne= w=20 method addToHistory() is introduced. This should solve your needs. To get= it,=20 you need CVS access. The current version is on the new Java-Readline site= on=20 Sourceforge (http://sourceforge.net/projects/java-readline/). Bernhard |
From: Bernhard B. <ma...@ba...> - 2002-04-30 09:08:21
|
> Dear Bernhard > > First of all - thanks for the great java readline program which i have > used in a java/jdbc based command-line sql client (opensource and free)= =2E > > I wish to know how i can link certain keys to Java methods. e.g. I woul= d > like to specify a key to complete file names, and a key to get only > column names or only table names. With native readline programming, it is possible to bind a key to a speci= al=20 function. Therefore it should be possible to use different keys for=20 completion of column names or table names. The difficult point is, that w= ith=20 standard-readline behaviour, only the TAB-key triggers the completion=20 functions. So you would have to reproduce the complete default behaviour = in=20 your own special function. In the current version of Java-Readline, there is no support for mapping = keys=20 to Java-methods. The best solution would probably be a context-sensitive completer which w= ould=20 offer only filenames, column names or table names when appropriate. But m= y=20 only basic knowledge of SQL already shows me, that this is not possible (= e.g=20 "select from table.column ...." or "select from column ..."). > BTW, I had put up a small GUI based SQLCLient on sourceforge.net (sqlmi= nus) > and hope to put this up there as well. You should also check for HenPlus on sourceforge.net, a JDBC-shell using=20 Java-Readline. > In case you know of any site/book/source of advanced info on writing > command-line/non-GUI programs, would be grateful. I know of nothing special, but I recommend following some standard Unix=20 guidelines: - use getopt for parameter parsing (also available in Java) - use standard options, e.g. -h, -? (help), --version, -v (verbose) etc. - support pipes - exit-code 0 is success >0 is failure Greetings from Munich, Germany Bernhard |
From: Bernhard B. <ma...@ba...> - 2002-04-30 07:25:01
|
> > In fact, I had to use the mingw-stuff, due to __int64 not being defin= ed > > in > > Cygwin > > Ah, so that's why. I ran into that, too. I'll try again when I have a > chance. But I get a _ton_ of symbol resolution errors. Could they all b= e > due to __int64? > Yes, because it's a define and that causes some problematic C-code. Bernhard |
From: Bernhard B. <ma...@ba...> - 2002-04-27 14:41:20
|
> > Well, I am trying right now but you failed to package > > org_gnu_readline_Readline.h with the sources > > Never mind. Now I remember you have to generate it using javah. > It's been a long time since I used JNI and your makefiles don't > work as-is under Cygwin... > > -- O.L. I'm currently working on it. I managed to compile with only two changes i= n the=20 toplevel and native makefiles, but linking is still a problem (something=20 related to errno). In fact, I had to use the mingw-stuff, due to __int64 = not=20 being defined in Cygwin. If you succeed, please send me your diffs. Bernhard |
From: Henner Z. <he...@fr...> - 2002-04-24 07:56:58
|
Hi, The default behaviour for the readline method just taking one parameter is _not_ to add the line to the internal history - which is the opposite the documentation says and as well what the default behaviour was before the change. It calls return readline(prompt, false); instead of 'true'. This is a typo, I presume, or was there a reason for this ? ciao, -hen -- Henner Zeller Dipl.-Inf. Med. freiheit.com technologies gmbh Theodorstr. 42-90 / 22761 Hamburg, Germany fon +49 (0)40 / 890584-0 fax +49 (0)40 / 890584-20 |