|
|
||
Changshin Lee's BlogJ2SE ArchivesTrying JNI with NetBeans C/C++ Pack on LinuxPosted by iasandcb on December 17, 2006 at 01:04 AM | Permalink | Comments (6)I started to read http://www.netbeans.org/kb/55/beginning-jni-part1.html and soon realized that the article was for Windows while my main development machine is Ubuntu. OK, so it means that I don't need to install cygwin and the rest of the instructions in the article should work fine, right? (Un)fortunately, you need more than the difference in case you're a unixer (including Mac OS X). Here are what I've found during driving the course: 1. First of all, yes! you don't need to install cygwin :-) 2. "Press Ctrl - F11 to clean and build the project" doesn't work for my Linux. Shift - F11 does. 3. 4. No options for compilation. Simply don't apply -mno-cygwin -Wl,--add-stdcall-alias -shared -m32. FYI, -shared is automatically added as the project is designed for dynamic library. 5. Make sure that your output file ends with not ".dll" but ".so". These are all except adding -fPIC option for #4 when you work on a 64-bit machine because without the option the compiler complains "/usr/bin/ld: build/Debug/GNU-Linux-x86/HelloWorldNative.o: relocation R_X86_64_32 against `a local symbol' can not be used when making a shared object; recompile with -fPIC" To be honest, this is my first time to create a JNI project. (No wonder I "was" a Java purist ;-) As I began working on Ruby (on Rails) and Python (on Django), I came to get some interest in using other languages than Java. I think that NetBeans C/C++ Pack opens a nice possibility to develop extensions for Java beyond the language itself.
Java WidgetsPosted by iasandcb on March 09, 2006 at 11:52 PM | Permalink | Comments (7)As I'm going to deliver some presentation on widgets such as Yahoo! Widgets (formely known as Konfabulator) and Google Desktop Sidebar, One idea hit me: Why not Java for widgets? Most of widgets take advantage of JavaScript to program widgets, and most of widget engines provide a considerable amount of APIs to allow programmers to work on OS, Network, and so on, which Java already has done. Obviously we need a framework and API for Java Widgets and also think about how those widgets are displayed and manipulated. It can be just another breed of Java application models like Applet and Java web start. However, more and more computer users enjoy mini applications, and Java could be a very good solution to write and run widgets across platforms with powerful existing APIs. | ||
|
|