How to solve this situation about ffmpeg with Android NDK - android-ndk

I used Android NDK to Compile ffmpeg ,when I run config.sh,so many erros happened,how to solve it.
Terry-L#Terry-L-HP /cygdrive/e/Android/android-ndk-r8d/samples/FFmpeg/jni/ffmpeg
$ ./config.sh
Unknown option "".
See ./configure --help for available options.
./config.sh: line 6: --target-os=linux: command not found
./config.sh: line 7: --arch=arm: command not found
./config.sh: line 8: --enable-version3: command not found
./config.sh: line 9: --enable-gpl: command not found
./config.sh: line 10: --enable-nonfree: command not found
./config.sh: line 11: --disable-stripping: command not found
./config.sh: line 12: --disable-ffmpeg: command not found
./config.sh: line 13: --disable-ffplay: command not found
./config.sh: line 14: --disable-ffserver: command not found
./config.sh: line 15: --disable-ffprobe: command not found
./config.sh: line 16: --disable-encoders: command not found
./config.sh: line 17: --disable-muxers: command not found
./config.sh: line 18: --disable-devices: command not found
./config.sh: line 19: --disable-protocols: command not found
./config.sh: line 20: --enable-protocol=file: command not found
./config.sh: line 21: --enable-avfilter: command not found
./config.sh: line 22: --disable-network: command not found
./config.sh: line 23: --disable-mpegaudio-hp: command not found
./config.sh: line 24: --disable-avdevice: command not found
./config.sh: line 25: --enable-cross-compile: command not found
./config.sh: line 26: --cc=/cygdrive/e/Android/android-ndk-r8d/toolchains/arm-li nux-androideabi-4.6/prebuilt/windows/bin/arm-linux-androideabi-gcc: No such file or directory
./config.sh: line 27: --cross-prefix=/cygdrive/e/Android/android-ndk-r8d/toolcha ins/arm-linux-androideabi-4.6/prebuilt/windows/bin/arm-linux-androideabi-: No su ch file or directory
./config.sh: line 28: --nm=/cygdrive/e/Android/android-ndk-r8d/toolchains/arm-li nux-androideabi-4.6/prebuilt/windows/bin/arm-linux-androideabi-nm: No such file or directory
./config.sh: line 29: --extra-cflags=-fPIC -DANDROID: command not found
./config.sh: line 30: --disable-asm: command not found
./config.sh: line 31: --enable-neon: command not found
./config.sh: line 32: --enable-armv5te: command not found
./config.sh: line 33: --extra-ldflags=-Wl,-T,/cygdrive/e/Android/android-ndk-r8d
/toolchains/arm-linux-androideabi-4.6/prebuilt/windows/arm-linux-androideabi/lib /ldscripts/armelf_linux_eabi.x -Wl,-rpath-link=/cygdrive/e/Android/android-ndk-r 8d/platforms/android-14/arch-arm/usr/lib -L/cygdrive/e/Android/android-ndk-r8d/p latforms/android-14/arch-arm/usr/lib -nostdlib /cygdrive/e/Android/android-ndk-r 8d/toolchains/arm-linux-androideabi-4.6/prebuilt/windows/lib/gcc/arm-linux-andro ideabi/4.6/crtbegin.o /cygdrive/e/Android/android-ndk-r8d/toolchains/arm-linux-a ndroideabi-4.6/prebuilt/windows/lib/gcc/arm-linux-androideabi/4.6/crtend.o -lc - lm -ldl: No such file or directory

You are using cywin to build ffmpeg, so you will get many problems with it. I recommend you should build it on linux.
The above error maybe missing configure ENV. You need to add $NDK to $PATH.

Related

Why is vim picking up vimrc_example.vim and _vimrc?

I can't work this out, I thought vimrc_example.vim was an example file but turns out Vim is reading this file for some reason as well as _vimrc.
On windows 10 Home with Vim 8.2.24 not using gvim but vim.
The directory of both these files are:
C:\Program Files\Vim\_vimrc
C:\Program Files\Vim\vim82\vimrc_example.vim
When I delete vimrc_example.vim it does not start Vim properly then, it just starts with a blank screen then I have to push enter to start up vim. Somewhere my vim is telling it to read this file I just don't understand the how and why as I am new to vim.
The reason I realised this is I was trying to set tw=0 via _vimrc but turned out vimrc_example.vim kept overriding this and setting it back to 78. I have tried to google a solution to this, but I just thought common sense wise an example file should not be this relevant and if it is why?
Output of :scriptnames
1: C:\Program Files\Vim\_vimrc
2: C:\Program Files\Vim\vim82\vimrc_example.vim
3: C:\Program Files\Vim\vim82\defaults.vim
4: C:\Program Files\Vim\vim82\syntax\syntax.vim
5: C:\Program Files\Vim\vim82\syntax\synload.vim
6: C:\Program Files\Vim\vim82\syntax\syncolor.vim
7: C:\Program Files\Vim\vim82\filetype.vim
8: C:\Program Files\Vim\vim82\ftplugin.vim
9: C:\Program Files\Vim\vim82\indent.vim
10: C:\Program Files\Vim\vim82\autoload\plug.vim
11: C:\Program Files\Vim\vim82\ftoff.vim
12: C:\Program Files\Vim\vim82\syntax\nosyntax.vim
13: ~\.vim\plugged\vim-monokai\colors\monokai.vim
14: ~\.vim\plugged\vim-wakatime\plugin\wakatime.vim
15: ~\.vim\plugged\vim-airline\plugin\airline.vim
16: ~\.vim\plugged\vim-airline\autoload\airline\init.vim
17: ~\.vim\plugged\vim-airline\autoload\airline\parts.vim
18: ~\.vim\plugged\vim-airline\autoload\airline\util.vim
19: ~\.vim\plugged\vim-airline-themes\plugin\airline-themes.vim
20: ~\.vim\plugged\vim-clang-format\plugin\clang_format.vim
21: ~\.vim\plugged\vim-gitgutter\plugin\gitgutter.vim
22: ~\.vim\plugged\vim-gitgutter\autoload\gitgutter\utility.vim
23: ~\.vim\plugged\vim-gitgutter\autoload\gitgutter\highlight.vim
24: ~\.vim\plugged\vim-gitgutter\autoload\gitgutter\async.vim
25: ~\.vim\plugged\DrawIt\plugin\cecutil.vim
26: ~\.vim\plugged\DrawIt\plugin\DrawItPlugin.vim
27: C:\Program Files\Vim\vim82\plugin\getscriptPlugin.vim
28: C:\Program Files\Vim\vim82\plugin\gzip.vim
29: C:\Program Files\Vim\vim82\plugin\logiPat.vim
30: C:\Program Files\Vim\vim82\plugin\manpager.vim
31: C:\Program Files\Vim\vim82\plugin\matchparen.vim
32: C:\Program Files\Vim\vim82\plugin\netrwPlugin.vim
33: C:\Program Files\Vim\vim82\plugin\rrhelper.vim
34: C:\Program Files\Vim\vim82\plugin\spellfile.vim
35: C:\Program Files\Vim\vim82\plugin\tarPlugin.vim
36: C:\Program Files\Vim\vim82\plugin\tohtml.vim
37: C:\Program Files\Vim\vim82\plugin\vimballPlugin.vim
38: C:\Program Files\Vim\vim82\plugin\zipPlugin.vim
39: C:\Program Files\Vim\vim82\pack\dist\opt\matchit\plugin\matchit.vim
40: ~\.vim\plugged\vim-airline\autoload\airline\extensions.vim
41: ~\.vim\plugged\vim-airline\autoload\airline\extensions\quickfix.vim
42: ~\.vim\plugged\vim-airline\autoload\airline.vim
43: ~\.vim\plugged\vim-airline\autoload\airline\extensions\netrw.vim
44: ~\.vim\plugged\vim-airline\autoload\airline\extensions\term.vim
45: ~\.vim\plugged\vim-airline\autoload\airline\section.vim
46: ~\.vim\plugged\vim-airline\autoload\airline\highlighter.vim
47: ~\.vim\plugged\vim-airline\autoload\airline\extensions\hunks.vim
48: ~\.vim\plugged\vim-airline\autoload\airline\extensions\whitespace.vim
49: ~\.vim\plugged\vim-airline\autoload\airline\extensions\wordcount.vim
50: ~\.vim\plugged\vim-airline\autoload\airline\extensions\keymap.vim
51: ~\.vim\plugged\vimtex\autoload\vimtex.vim
52: ~\.vim\plugged\vim-airline\autoload\airline\extensions\vimtex.vim
53: ~\.vim\plugged\vim-airline-themes\autoload\airline\themes\molokai.vim
54: ~\.vim\plugged\vim-airline\autoload\airline\themes.vim
55: ~\.vim\plugged\vim-airline\autoload\airline\builder.vim
56: ~\.vim\plugged\vim-airline\autoload\airline\extensions\default.vim
57: ~\.vim\plugged\vim-gitgutter\autoload\gitgutter.vim
58: ~\.vim\plugged\vim-gitgutter\autoload\gitgutter\hunk.vim
https://i.gyazo.com/7ca9c5002ec1f95aa545c859b498cba5.png
Files:
_vimrc located in C:\program files\Vim\_vimrc:
http://dpaste.com/202QAN3
vimrc_example.vim located in C:\Program Files\Vim\vim82:
http://dpaste.com/2MWVY7V
You see I would think you could delete vimrc_example but not sure if it is doing anything important?????? Please refer to the specific line numbers if you wish to point out anything incorrect.
Your C:\Program Files\Vim\_vimrc has this on line 7:
" Vim with all enhancements
source $VIMRUNTIME/vimrc_example.vim
That's what's sourcing the vimrc_example.vim file. So it looks like you added this there, or copied it from somewhere (perhaps a guide or tip you found on the web?) or this _vimrc file is one you downloaded (or came with a Vim distribution you installed?) and had this in it already.
Anyways, that should explain why vimrc_example.vim is being sourced.
If you don't want that behavior anymore, you can either:
Remove that source command from C:\Program Files\Vim\_vimrc
Or, if you don't want to modify that specific _vimrc file (because it came with a distro or similar), then you can instead start using a _vimrc file from a different location (note that this one corresponds to the one listed as "3rd user vimrc file" in the :version output, you could use $HOME/_vimrc or $HOME/vimfiles/vimrc that come before it.)
Note that the vimrc_example.vim file is not really originally meant to be sourced this way... Instead, it's meant to be a template for you to copy to your own _vimrc that you can then modify to your taste. So while you'll probably be fine with sourcing it, it's not how it was meant to be used.
You'll also note that the vimrc_example.vim file doesn't actually have a lot of commands itself... But a lot of what it does is actually coming from defaults.vim that is sourced from it. Please note that the defaults.vim file is meant to be sourced from your vimrc (see :help defaults.vim for more details.)
So you might want to consider swapping the sourcing of vimrc_example.vim with the sourcing of defaults.vim. Additionally, if you like some of the other settings from vimrc_example.vim (such as enabling backup and undofile), consider replicating those into your vimrc.

Bash: exit in script doesn't close terminal

I'm working on a script to run on terminal like this one
#!/bin/bash
COUNTER=0
while [ $COUNTER -lt 10 ]; do
echo The counter is $COUNTER
yoooooooo
sleep 2
let COUNTER=COUNTER+1
done
exit
But once the counter reaches 9 and the while cycle stops, the terminal wont close with the command "exit".
Here's the output
pi#raspberrypi:~/Desktop $ ./sxdd
The counter is 0
./sxdd: line 7: yoooooooo: command not found
The counter is 1
./sxdd: line 7: yoooooooo: command not found
The counter is 2
./sxdd: line 7: yoooooooo: command not found
The counter is 3
./sxdd: line 7: yoooooooo: command not found
The counter is 4
./sxdd: line 7: yoooooooo: command not found
The counter is 5
./sxdd: line 7: yoooooooo: command not found
The counter is 6
./sxdd: line 7: yoooooooo: command not found
The counter is 7
./sxdd: line 7: yoooooooo: command not found
The counter is 8
./sxdd: line 7: yoooooooo: command not found
The counter is 9
./sxdd: line 7: yoooooooo: command not found
pi#raspberrypi:~/Desktop $
And it never quits... how do I fix that?
the terminal wont close with the command "exit"
That's because you run the exit command inside a script. There exit means "exit the script", not "exit the terminal".
If you want to close the terminal window from a script, you probably have to use commands like kill $pidOfTheTerminalWindow.
As an alternative, you can source the script, that is execute the script as if you typed it directely into the command line. Use either
source sxdd
or
. sxdd
Try to run your script like this:
exec ./sxdd
It replaces the shell process with your script and when the script exits your window will close.

Can't run Neo4j on Antergos (integer expression expected)

Every time I try to run the latest version of Neo4j (2.3.2 Community) I keep getting an error that just keeps looping.
[telmo#Telmo-LT neo4j-community-2.3.2]$ bin/neo4j start
WARNING: Max 1024 open files allowed, minimum of 40 000 recommended. See the Neo4j manual.
bin/neo4j: line 150: [: : integer expression expected
bin/neo4j: line 153: lsof: command not found
Starting Neo4j Server...WARNING: not changing user
process [1283]... waiting for server to be ready.bin/neo4j: line 150: [: : integer expression expected
bin/neo4j: line 153: lsof: command not found
.bin/neo4j: line 150: [: : integer expression expected
bin/neo4j: line 153: lsof: command not found
.bin/neo4j: line 150: [: : integer expression expected
bin/neo4j: line 153: lsof: command not found
.bin/neo4j: line 150: [: : integer expression expected
bin/neo4j: line 153: lsof: command not found
This is a stable release and I couldn't find anyone with a similar problem.
Can you run the 'lsof' command in your shell? Looks like it is missing on your machine. It's used to define the PID of the neo4j process and failing in your case. Just have a look into the /bin/neo4j file and see what fails. I had some issues with the lsof version number which caused the IF in line 150 to fail. I ended up using a dirty hack to get it running by just hard coding the version number.
line 153: lsof: command not found, you can try install losf,I use centos system, and use this command yum install lsof -y,then try bin/neo4j start

vim Vundle's PluginInstall conflict with fish in Archlinux

In Arch, when I use Vim Vundle's PluginInstall/PluginUpdate, it will show many mistake message
Processing 'tpope/vim-fugitive'
Error detected while processing function vundle#installer#new..<SNR>146_process..vundle#installer#run..vundle#installer#ins
tall..<SNR>146_sync..<SNR>146_make_sync_command..<SNR>146_get_current_origin_url..<SNR>146_system:
line 1:
E484: Can't open file /tmp/v8J8IUB/7
Error detected while processing function vundle#installer#new..<SNR>146_process..vundle#installer#run..vundle#installer#ins
tall..<SNR>146_sync:
line 6:
E714: List required
Error detected while processing function vundle#installer#new..<SNR>146_process:
line 13:
E121: Undefined variable: s:last_status
E15: Invalid expression: 'error' == s:last_status
line 17:
E121: Undefined variable: s:last_status
-- More --
I have to type Enter repeatly so that it can process next Plugin, and while processing every plugin, it will show the same mistake message:
Processing 'sjl/gundo.vim'
Error detected while processing function vundle#installer#new..<SNR>146_process..vundle#installer#run..vundle#installer#ins
tall..<SNR>146_sync..<SNR>146_make_sync_command..<SNR>146_get_current_origin_url..<SNR>146_system:
line 1:
E484: Can't open file /tmp/v8J8IUB/12
Error detected while processing function vundle#installer#new..<SNR>146_process..vundle#installer#run..vundle#installer#ins
tall..<SNR>146_sync:
line 6:
E714: List required
Error detected while processing function vundle#installer#new..<SNR>146_process:
line 13:
E121: Undefined variable: s:last_status
E15: Invalid expression: 'error' == s:last_status
line 17:
E121: Undefined variable: s:last_status
When I set fish shell as default shell , it will conflict. when I switch back to zsh, it will work normally. How can I do?
Either update to at least Vim 7.4.276, which adds support for fish, or set the shell that Vim uses to one that your version of Vim supports (like zsh):
set shell=/usr/bin/zsh

FreeBSD Echoprint codegen

I am trying to compile Echoprint codegen on FreeBSD, but fail. But here's what i get when i try to run make or make install
> make
"Makefile", line 35: Missing dependency operator
"Makefile", line 39: Need an operator
"Makefile", line 41: Need an operator
"Makefile", line 50: warning: duplicate script for target "%.o" ignored
"Makefile", line 53: warning: duplicate script for target "%.o" ignored
"Makefile", line 56: warning: duplicate script for target "%.o" ignored
"Makefile", line 61: Missing dependency operator
"Makefile", line 62: warning: duplicate script for target "ifeq" ignored
"Makefile", line 62: warning: duplicate script for target "(,Darwin)" ignored
"Makefile", line 63: Need an operator
"Makefile", line 77: Missing dependency operator
"Makefile", line 78: warning: duplicate script for target "ifeq" ignored
"Makefile", line 78: warning: duplicate script for target "(,Darwin)" ignored
"Makefile", line 79: warning: duplicate script for target "ifeq" ignored
"Makefile", line 79: warning: duplicate script for target "(,Darwin)" ignored
"Makefile", line 80: warning: duplicate script for target "ifeq" ignored
"Makefile", line 80: warning: duplicate script for target "(,Darwin)" ignored
"Makefile", line 81: Need an operator
"Makefile", line 85: Need an operator
I tried running it as a root, and as a normal user. Both to no avail.
Unfortunately, i know nothing about makefiles. Is there a makefile for FreeBSD?
Best regards,
Timofey
Install the devel/gmake port and use gmake instead of make.

Resources