Generating so library with c++ under Android Studio using Gradle

When we put the jni folder under projects and compile it using command line tool ndk-build, we will get libs & obj folders like this: |–jni |–libs |—-armeabi-v7a |–obj But under Android Studio develop environment, android studio can’t find the so files under libs folder. We can do it by using following folder structure under Android Studio: |—app |——jni |——libs |——obj |——src |———androidTest |———main We can use this folder structure to compile JNI.

Config Go Develop Environment in Emacs

If you are under Windows, you may need to config golang develop environment manually. Get Emacs go-mode from misc/emacs/, there are two files: go-mode-load.el and go-mode.el. Put them into your Emacs load-path, then add following code to .emacs: ;; golang mode (add-to-list ’load-path “~/emacs/site-lisp/go-mode”) (require ‘go-mode-load) (require ‘go-mode) Then you can open go source file with syntax highlight now. If you are under Ubuntu/Debian, the easiest way to install golang-mode is by:

Right Alt Key Broken When Using Emacs in Putty under Windows?

If you have a keyboard with two Alt keys (e.g. a US Keyboard), you will find that PuTTY doesn’t recognize the one on the right side. It is a fatal problem if you are using Emacs in putty on Windows to editing files on a remote computer. After doing some reasearching on it, I think there are two soluctions for this problem. Easily fixed the problem with a simple registry edit

Could Not Read Symbols while linking ZeroMQ

While I make my cpp source files linking ZeroMQ under Ubuntu, I got following error: /usr/bin/ld: test_server.o: undefined reference to symbol ‘zmq_strerror’ /usr/bin/ld: note: ‘zmq_strerror’ is defined in DSO /usr/local/lib/libzmq.so.3 so try adding it to the linker command line /usr/local/lib/libzmq.so.3: could not read symbols: Invalid operation The ZeroMQ library has already installed. By checking the man: Libraries have been installed in: /usr/local/lib If you ever happen to want to link against installed libraries in a given directory, LIBDIR, you must either use libtool, and specify the full pathname of the library, or use the `-LLIBDIR’ flag during linking and do at least one of the following:

Two Key Points in Using Django-Chartit

Django-Chartit looks like a good tool for drawing some data charts under Python Django framework. But it is a little hard to get it ready for work. Here I remind of two key steps while using Chartit: add chartit to your INSTALLED_APPS. install simplejason if you get ‘use_decimal’ error. The error message is something like: TypeError at /charts/ __init__() got an unexpected keyword argument ‘use_decimal’ I don’t think Chartit is the best choice current now, and I prefer Chart.