see
http://dev-answers.blogspot.de/2009/06/eclipse-build-errors-javalangobject.html
If you are a newbie like me, but interested in Android, let's learn together!
Friday, June 13, 2014
Tuesday, June 11, 2013
multi-tab cygwin
Check out "Console" at
http://sourceforge.net/projects/console/?source=dlp
Go to Edit -> Settings, set Shell to C:\cygwin\Cygwin.bat (or wherever your Cygwin path is)
Enjoy!
----------------------------
emacs: terminal type cygwin is not defined
I encounter such problem when using Console to ssh to a remote machine and emacs
Solution:
export TERM=ansi
----------------------------
Reference:
http://superuser.com/questions/30733/multi-tab-command-prompt-in-windows
http://sourceforge.net/projects/console/?source=dlp
Go to Edit -> Settings, set Shell to C:\cygwin\Cygwin.bat (or wherever your Cygwin path is)
Enjoy!
----------------------------
emacs: terminal type cygwin is not defined
I encounter such problem when using Console to ssh to a remote machine and emacs
Solution:
export TERM=ansi
----------------------------
Reference:
http://superuser.com/questions/30733/multi-tab-command-prompt-in-windows
Friday, June 7, 2013
Install emacs on Solari (SunOS) without root
Finally... done installing emacs on Solari without root -- really a painful process, so I decide to write this down and hopefully it can be helpful for people in same needs.
Normally, on a Unbuntu machine, install emacs without root would be easy. Suppose we want to install it in /home/xxx/emacs folder
1. Download the emacs source from http://www.gnu.org/software/emacs/ and untar the source to a folder
2. Go to the emacs source folder, run
./configure --prefix=/home/xxx/emacs
make all
make install
in which --prefix=/home/xxx/emacs in configure command tells emacs to install everything to that folder.
3. Finally, add /home/xxx/emacs/bin to your PATH, done.
Simple and easy, right?
However, on Solari, everything got complicated (at least for me, a guy who first time use Solari), let me list the problems I encountered during the each step numbered above
1. First problem I find is that, "tar xzvf" is not working on Solari...
Solution: use "gtar xzvf" instead
2. In the second step, first small problem is ./configure fails and says please add "--with-gif=no" option, that's easy, just do it.
The true problem comes when I find that typing gcc or make in terminal would result in "command not found"
Solution: gcc is in /usr/sfw/bin or /usr/local/bin, make is in /usr/ccs/bin, add those three directory to PATH.
Or, you can go to /usr and run
find . -name gcc
find . -name make
to figure out where are those binaries then add it to PATH
With PATH set properly, I try to make and install emacs 24.3, everything goes well. But after installing, when I try to run emacs, it won't boot and pop out an error message:
Fatal error 6
It turns out that the newest emacs 24 has some problem when running on older system (I don't remember the exact reason, something like emacs 24 does not support old version lisp)
Solution: download emacs 23 instead, for me I used emacs 23.4
Then repeat the same process. This time during make install, an error occurs:
chmod -R a+r /home/ding34/emacs/share/emacs/23.4/leim
for installuser in ${LOGNAME} ${USERNAME} ${USER} \
`id -un 2> /dev/null`; do \
[ -n "${installuser}" ] && break ; \
done ; \
find /home/ding34/emacs/share/emacs/23.4/leim -exec chown ${installuser} '{}' ';'
*** Error code 2
make: Fatal error: Command failed for target `install'
Current working directory /l/mobilityhome/ding34/emacs/tar/emacs-23.4/leim
*** Error code 1
It turned out that the error is from the line
for installuser in ${LOGNAME} ${USERNAME} ${USER} \
`id -un 2> /dev/null`; do \
in leim/Makefile.
The reason is the "id" command has different syntax on Solari compared to on Unbuntu, run "id -un 2" and it will tell you "id: illegal option -- u". Since the id command fails, the make will consider it as an error, report it, and exit.
Solution: delete `id -un 2> /dev/null` part in the leim/Makefile, and re-run make install
With one afternoon and one morning's effort, finally I got our lovely emacs working.
Oh, one more thing, don't forget to put the emacs binary directory (which is /home/xxx/emacs/bin) into PATH!
-----------------------
Set up PATH:
Edit ~/.bash_profile file (create it if it does not exist), and put all the export statement in it. It will take effect when you launch terminal next time. (So for the current terminal, you may still need to manually run export to set up PATH)
Normally, on a Unbuntu machine, install emacs without root would be easy. Suppose we want to install it in /home/xxx/emacs folder
1. Download the emacs source from http://www.gnu.org/software/emacs/ and untar the source to a folder
2. Go to the emacs source folder, run
./configure --prefix=/home/xxx/emacs
make all
make install
in which --prefix=/home/xxx/emacs in configure command tells emacs to install everything to that folder.
3. Finally, add /home/xxx/emacs/bin to your PATH, done.
Simple and easy, right?
However, on Solari, everything got complicated (at least for me, a guy who first time use Solari), let me list the problems I encountered during the each step numbered above
1. First problem I find is that, "tar xzvf" is not working on Solari...
Solution: use "gtar xzvf" instead
2. In the second step, first small problem is ./configure fails and says please add "--with-gif=no" option, that's easy, just do it.
The true problem comes when I find that typing gcc or make in terminal would result in "command not found"
Solution: gcc is in /usr/sfw/bin or /usr/local/bin, make is in /usr/ccs/bin, add those three directory to PATH.
Or, you can go to /usr and run
find . -name gcc
find . -name make
to figure out where are those binaries then add it to PATH
With PATH set properly, I try to make and install emacs 24.3, everything goes well. But after installing, when I try to run emacs, it won't boot and pop out an error message:
Fatal error 6
It turns out that the newest emacs 24 has some problem when running on older system (I don't remember the exact reason, something like emacs 24 does not support old version lisp)
Solution: download emacs 23 instead, for me I used emacs 23.4
Then repeat the same process. This time during make install, an error occurs:
chmod -R a+r /home/ding34/emacs/share/emacs/23.4/leim
for installuser in ${LOGNAME} ${USERNAME} ${USER} \
`id -un 2> /dev/null`; do \
[ -n "${installuser}" ] && break ; \
done ; \
find /home/ding34/emacs/share/emacs/23.4/leim -exec chown ${installuser} '{}' ';'
*** Error code 2
make: Fatal error: Command failed for target `install'
Current working directory /l/mobilityhome/ding34/emacs/tar/emacs-23.4/leim
*** Error code 1
It turned out that the error is from the line
for installuser in ${LOGNAME} ${USERNAME} ${USER} \
`id -un 2> /dev/null`; do \
in leim/Makefile.
The reason is the "id" command has different syntax on Solari compared to on Unbuntu, run "id -un 2" and it will tell you "id: illegal option -- u". Since the id command fails, the make will consider it as an error, report it, and exit.
Solution: delete `id -un 2> /dev/null` part in the leim/Makefile, and re-run make install
With one afternoon and one morning's effort, finally I got our lovely emacs working.
Oh, one more thing, don't forget to put the emacs binary directory (which is /home/xxx/emacs/bin) into PATH!
-----------------------
Set up PATH:
Edit ~/.bash_profile file (create it if it does not exist), and put all the export statement in it. It will take effect when you launch terminal next time. (So for the current terminal, you may still need to manually run export to set up PATH)
Thursday, June 6, 2013
cannot open google.com
This morning, I find my chrome cannot visit google.com -- it always says "the website is not available", while all other websites work well
Solution:
clear cookies
for Chrome, go to Settings -> Show advanced settings... -> content settings .. (under Privacy tab) -> All cookies and site data... -> remove all
And google works again.
Solution:
clear cookies
for Chrome, go to Settings -> Show advanced settings... -> content settings .. (under Privacy tab) -> All cookies and site data... -> remove all
And google works again.
Saturday, May 11, 2013
Friday, May 10, 2013
Missing "Developer Option" in CM 10.1
After flashing CM 10.1, find the developer option missing
Solution is here:
Settings -> About phone
click "Build number" for several times, the developer option will appear...
I know it sounds like a joke... but try it, it works...
Thursday, May 9, 2013
extract-files.sh: remote object does not exist
According to the official Cyanogenmod build guide, there is one step called "Extract Proprietary Blobs", in which you have to connect the device with USB and run "extract-file.sh" to get those "blobs" from the device.
However, in running the extract-files, it's very often to see output like
remote object '/system/lib/egl/libplayback_adreno200.so' does not exist
It didn't say it's an "Error", but actually the script will just stop there, leaving the remaining blobs unextracted.
If you thought, oh, only one file does not exists, maybe not a big deal, so you continue to build the framework, it's highly likely that the framework you build will not work properly, due to lack of blobs.
Solution:
Download a released Cyanogenmod for that device (the same version with the one you are trying to compiling), unzip it to a folder, suppose the folder is "/home/cm"
Then when running the extract-file.sh, instead of connecting your device to USB and extracting from device (which is the default behavior if you don't provide any argument to the extract-files.sh), you can simply run
./extract-files.sh /home/cm
(replace /home/cm to the folder where you unzip the Cyanogenmod, of course)
Then the extract-files.sh will copy blobs from that folder.
If there is still some file missing (e.g. libpn544_fw.so for Galaxy S3), then google it, download it and put it in the right path -- in general, missing blobs is not a good thing, we should avoid it as much as we can, and that's why I commented out the text below, which is a very bad solution.
When I try to follow the wiki page to build Cyanogenmod from source, there is one step called
Extract Proprietary Blobs
in which I need to go to device/samsung/quincyatt folder and execute extract-files.sh to get those "blobs" from the device.
In executing the extract-files.sh, the script stops and says
remote object '/system/lib/egl/libplayback_adreno200.so' does not exist
Well, it's not an error, so I thought it happens to be the last file not exists, but actually it's not.
Go to the device folder, and run
grep -lr "libplayback_adreno200.so" *
I find it's in samsung/msm8660-com/com-proprietary-files.txt, so open that file, search for "libplayback_adreno200.so", and comment it out, re-execute the script, the script proceeds to extracting more files.
If similar error happens again, just repeat the same process.
However, in running the extract-files, it's very often to see output like
remote object '/system/lib/egl/libplayback_adreno200.so' does not exist
It didn't say it's an "Error", but actually the script will just stop there, leaving the remaining blobs unextracted.
If you thought, oh, only one file does not exists, maybe not a big deal, so you continue to build the framework, it's highly likely that the framework you build will not work properly, due to lack of blobs.
Solution:
Download a released Cyanogenmod for that device (the same version with the one you are trying to compiling), unzip it to a folder, suppose the folder is "/home/cm"
Then when running the extract-file.sh, instead of connecting your device to USB and extracting from device (which is the default behavior if you don't provide any argument to the extract-files.sh), you can simply run
./extract-files.sh /home/cm
(replace /home/cm to the folder where you unzip the Cyanogenmod, of course)
Then the extract-files.sh will copy blobs from that folder.
If there is still some file missing (e.g. libpn544_fw.so for Galaxy S3), then google it, download it and put it in the right path -- in general, missing blobs is not a good thing, we should avoid it as much as we can, and that's why I commented out the text below, which is a very bad solution.
Subscribe to:
Posts (Atom)