I install cygwin-x86: source/binary binutils, flex, bison, source/binary gcc, etc..
In order to cross-compile binutils, I run the follwing commands:
export PREFIX=/usr/cross
export TARGET=x86_64-pc-linux
cd /usr/src/binutils-2.23.51-1
./configure --target=$TARGET --prefix=$PREFIX --enable-64-bit-bfd --disable-shared --disable-nls
make configure-host
make LDFLAGS="-all-static"
make install
On "make install", It occur errors
./c-arc.texi:223: command #bullet not accepting argument in brace should not be on #table line
./c-arm.texi:393: command #bullet not accepting argument in brace should not be on #table line
./c-arm.texi:394: warning: #item missing argument
./c-arm.texi:397: warning: #item missing argument
./c-arm.texi:402: warning: #item missing argument
./c-arm.texi:407: warning: #item missing argument
./c-arm.texi:412: warning: #item missing argument
./c-arm.texi:415: warning: #item missing argument
./c-cr16.texi:49: warning: #item missing argument
./c-cr16.texi:51: warning: #item missing argument
./c-cr16.texi:53: warning: #item missing argument
./c-cr16.texi:58: warning: #item missing argument
./c-cr16.texi:63: warning: #item missing argument
./c-cr16.texi:65: warning: #item missing argument
./c-tic54x.texi:113: #code expected braces
./c-tic54x.texi:130: #code expected braces
./c-tic54x.texi:137: #code expected braces
./c-tic54x.texi:313: #code expected braces
as.texinfo:4385: warning: node `Byte' is next for `Bundle directives' in menu but not in sectioning
as.texinfo:4441: warning: node `Bundle directives' is prev for `Byte' in menu but not in sectioning
as.texinfo:4449: warning: node `Comm' is next for `CFI directives' in menu but not in sectioning
as.texinfo:4571: warning: node `CFI directives' is prev for `Comm' in menu but not in sectioning
./c-arm.texi:447: warning: node next `ARM-Regs' in menu `ARM-Relocations' and in sectioning `ARM-Neon-Alignment' differ
./c-arm.texi:454: warning: node prev `ARM-Neon-Alignment' in menu `ARM-Relocations' and in sectioning `ARM-Regs' differ
./c-arm.texi:476: warning: node `ARM-Neon-Alignment' is next for `ARM-Relocations' in menu but not in sectioning
./c-arm.texi:476: warning: node `ARM-Regs' is prev for `ARM-Relocations' in menu but not in sectioning
./c-arm.texi:476: warning: node up `ARM-Relocations' in menu `ARM Syntax' and in sectioning `ARM Floating Point' differ
./c-arm.texi:469: node `ARM Floating Point' lacks menu item for `ARM-Relocations' despite being its Up target
./c-i386.texi:412: warning: node `i386-Regs' is next for `i386-Mnemonics' in menu but not in sectioning
./c-i386.texi:512: warning: node `i386-Mnemonics' is prev for `i386-Regs' in menu but not in sectioning
./c-i386.texi:927: warning: node next `i386-16bit' in menu `i386-Arch' and in sectioning `i386-Bugs' differ
./c-i386.texi:979: warning: node next `i386-Bugs' in menu `i386-Notes' and in sectioning `i386-Arch' differ
./c-i386.texi:979: warning: node prev `i386-Bugs' in menu `i386-Arch' and in sectioning `i386-16bit' differ
./c-i386.texi:1000: warning: node next `i386-Arch' in menu `i386-Bugs' and in sectioning `i386-Notes' differ
./c-i386.texi:1000: warning: node prev `i386-Arch' in menu `i386-16bit' and in sectioning `i386-Bugs' differ
./c-i386.texi:1067: warning: node prev `i386-Notes' in menu `i386-Bugs' and in sectioning `i386-Arch' differ
./c-mips.texi:449: warning: node next `MIPS Stabs' in menu `MIPS ISA' and in sectioning `MIPS symbol sizes' differ
./c-mips.texi:463: warning: node next `MIPS symbol sizes' in menu `MIPS autoextend' and in sectioning `MIPS ISA' differ
./c-mips.texi:463: warning: node prev `MIPS symbol sizes' in menu `MIPS ISA' and in sectioning `MIPS Stabs' differ
./c-mips.texi:518: warning: node next `MIPS ISA' in menu `MIPS symbol sizes' and in sectioning `MIPS autoextend' differ
./c-mips.texi:518: warning: node prev `MIPS ISA' in menu `MIPS Stabs' and in sectioning `MIPS symbol sizes' differ
./c-mips.texi:557: warning: node prev `MIPS autoextend' in menu `MIPS symbol sizes' and in sectioning `MIPS ISA' differ
./c-ns32k.texi:35: warning: node next `NS32K-Dependent' in menu `SH-Dependent' and in sectioning `PDP-11-Dependent' differ
./c-pdp11.texi:6: warning: node prev `PDP-11-Dependent' in menu `SH64-Dependent' and in sectioning `NS32K-Dependent' differ
./c-score.texi:7: warning: node next `SCORE-Dependent' in menu `Sparc-Dependent' and in sectioning `SH-Dependent' differ
./c-sh.texi:6: warning: node prev `SH-Dependent' in menu `NS32K-Dependent' and in sectioning `SCORE-Dependent' differ
./c-sh64.texi:5: warning: node next `SH64-Dependent' in menu `PDP-11-Dependent' and in sectioning `Sparc-Dependent' differ
./c-sparc.texi:8: warning: node prev `Sparc-Dependent' in menu `SCORE-Dependent' and in sectioning `SH64-Dependent' differ
./c-tilepro.texi:7: warning: node next `TILEPro-Dependent' in menu `V850-Dependent' and in sectioning `Z80-Dependent' differ
./c-z80.texi:7: warning: node prev `Z80-Dependent' in menu `Xtensa-Dependent' and in sectioning `TILEPro-Dependent' differ
./c-vax.texi:7: warning: node `V850-Dependent' is next for `Vax-Dependent' in sectioning but not in menu
./c-v850.texi:5: warning: node prev `V850-Dependent' in menu `TILEPro-Dependent' and in sectioning `Vax-Dependent' differ
./c-xtensa.texi:9: warning: node `Z80-Dependent' is next for `Xtensa-Dependent' in menu but not in sectioning
Makefile:397: recipe for target 'as.info' failed
make[4]: *** [as.info] Error 1
make[4]: Leaving directory '/usr/src/binutils-2.23.51-1/gas/doc'
Makefile:592: recipe for target 'install-am' failed
make[3]: *** [install-am] Error 2
make[3]: Leaving directory '/usr/src/binutils-2.23.51-1/gas/doc'
Makefile:2182: recipe for target 'install-recursive' failed
make[2]: *** [install-recursive] Error 1
make[2]: Leaving directory '/usr/src/binutils-2.23.51-1/gas'
Makefile:4762: recipe for target 'install-gas' failed
make[1]: *** [install-gas] Error 2
make[1]: Leaving directory '/usr/src/binutils-2.23.51-1'
Makefile:2142: recipe for target 'install' failed
make: *** [install] Error 2
It worked well when I did cross-compile before.. so I don't know what's wrong more
What should I do?
Related
I am trying to compile linux kernel v5.9.12 using my buildroot toolchain (2020.08.2) and I keep getting an error related to libfdt. I can't figure out how to fix this and I've been banging my head against the wall for several hours now.
username#local:~/linux-stable$ make ARCH=arm CROSS_COMPILE=arm-linux- -j64
CALL scripts/atomic/check-atomics.sh
CALL scripts/checksyscalls.sh
CHK include/generated/compile.h
Kernel: arch/arm/boot/Image is ready
AS arch/arm/boot/compressed/piggy.o
CC arch/arm/boot/compressed/fdt_ro.o
In file included from arch/arm/boot/compressed/../../../../lib/fdt_ro.c:2,
from arch/arm/boot/compressed/fdt_ro.c:2:
arch/arm/boot/compressed/../../../../lib/../scripts/dtc/libfdt/fdt_ro.c: In function ‘fdt_generate_phandle’:
arch/arm/boot/compressed/../../../../lib/../scripts/dtc/libfdt/fdt_ro.c:149:13: error: ‘FDT_MAX_PHANDLE’ undeclared (first use in this function)
149 | if (max == FDT_MAX_PHANDLE)
| ^~~~~~~~~~~~~~~
arch/arm/boot/compressed/../../../../lib/../scripts/dtc/libfdt/fdt_ro.c:149:13: note: each undeclared identifier is reported only once for each function it appears in
arch/arm/boot/compressed/../../../../lib/../scripts/dtc/libfdt/fdt_ro.c: In function ‘fdt_get_mem_rsv’:
arch/arm/boot/compressed/../../../../lib/../scripts/dtc/libfdt/fdt_ro.c:182:13: error: implicit declaration of function ‘fdt64_ld’ [-Werror=implicit-function-declaration]
182 | *address = fdt64_ld(&re->address);
| ^~~~~~~~
arch/arm/boot/compressed/../../../../lib/../scripts/dtc/libfdt/fdt_ro.c: In function ‘fdt_get_property_by_offset_’:
arch/arm/boot/compressed/../../../../lib/../scripts/dtc/libfdt/fdt_ro.c:371:11: error: implicit declaration of function ‘fdt32_ld’ [-Werror=implicit-function-declaration]
371 | *lenp = fdt32_ld(&prop->len);
| ^~~~~~~~
cc1: some warnings being treated as errors
make[2]: *** [scripts/Makefile.build:283: arch/arm/boot/compressed/fdt_ro.o] Error 1
make[1]: *** [arch/arm/boot/Makefile:64: arch/arm/boot/compressed/vmlinux] Error 2
make: *** [arch/arm/Makefile:330: zImage] Error 2
make: *** Waiting for unfinished jobs....
I have added output/host/usr/bin to my PATH env variable so make can find the toolchain. Any ideas?
It turns out that in arch/arm/boot/compressed there were a bunch of old libfdt related header files still hanging around, so by deleting these I was able to build the kernel. I found the files using git status.
There is quite old uClinux-dist-20080808 with uClinux-dist-20080808-20090112 and uClinux_on_stm32 patches for STM32F10x MCU, as described here AN3012.
I use Ubuntu 18.04 (inside VirtualBox) to build uClinux and go through AN3012 step-by-step.
So, I run "make menuconfig", enter settings as shown on page 15 (AN3012) and then exit menu. There are a number of messages in terminal and finally I got this:
configuration written to .config
make[ 2]: Leaving directory '/home/maksim/Projects/STM/uClinux-dist/config'
make[ 1]: Leaving directory '/home/maksim/Projects/STM/uClinux-dist'
make[ 1]: Entering directory '/home/maksim/Projects/STM/uClinux-dist'
Makefile:228: *** mixed implicit and normal rules: deprecated syntax
Makefile:245: *** mixed implicit and normal rules: deprecated syntax
KCONFIG_NOTIMESTAMP=1 make ARCH=arm CROSS_COMPILE=arm-uclinuxeabi- -C linux-2.6.x menuconfig
make[ 2]: Entering directory '/home/maksim/Projects/STM/uClinux-dist/linux-2.6.x'
Makefile:434: *** mixed implicit and normal rules: deprecated syntax
Makefile:1563: *** mixed implicit and normal rules: deprecated syntax
make[ 2]: *** No rule to make target 'menuconfig'. Stop.
make[ 2]: Leaving directory '/home/maksim/Projects/STM/uClinux-dist/linux-2.6.x'
Makefile:183: recipe for target 'linux_menuconfig' failed
make[ 1]: *** [linux_menuconfig] Error 2
make[ 1]: Leaving directory '/home/maksim/Projects/STM/uClinux-dist'
Makefile:127: recipe for target 'menuconfig' failed
make: *** [menuconfig] Error 2
Please help to understand what is wrong and fix it. Many thanks for any help!
Notes for those who want to reproduce the issue:
1) you need to fix the uCLinux-dist/kconfig/config/zconf.hash.c (insert the snippet below at line 165)
#if defined __GNUC_STDC_INLINE__ || defined __GNUC_GNU_INLINE__
__attribute__ ((__gnu_inline__))
#endif
2) uClinux uClinux-dist-20080808 is available here
3) uClinux-dist-20080808-20090112 patch is available here
4) uClinux_on_stm32 patch is available here here
The solution is to use older Linux version. Ubuntu 12.04.5 is OK.
Do not forget to add CodeSourcery /bin folder to PATH.
I have installed haskell stack and I'm trying to setup ghc for the same. stack version is
stack --version
Version 1.5.1, Git revision 600c1f01435a10d127938709556c1682ecfd694e (4861 commits) x86_64 hpack-0.17.1
I have updated the ~/.stack/global-project/stack.yaml as below
# This is the implicit global project's config file, which is only used when
# 'stack' is run outside of a real project. Settings here do _not_ act as
# defaults for all projects. To change stack's default settings, edit
# '/home/rajkumar/.stack/config.yaml' instead.
#
# For more information about stack's configuration, see
# http://docs.haskellstack.org/en/stable/yaml_configuration/
#
flags: {}
extra-package-dbs: []
packages: []
extra-deps: []
resolver: ghc-8.2.1
Then I run stack setup command and got the below error -
stack setup
The GHC located at /home/rajkumar/.stack/programs/x86_64-linux/ghc-8.2.1/bin/ghc failed to compile a sanity check. Please see:
http://docs.haskellstack.org/en/stable/install_and_upgrade/
for more information. Exception was:
Running /home/rajkumar/.stack/programs/x86_64-linux/ghc-8.2.1/bin/ghc /tmp/stack-sanity-check3048/Main.hs -no-user-package-db in directory /tmp/stack-sanity-check3048/ exited with ExitFailure 1
[1 of 1] Compiling Main ( /tmp/stack-sanity-check3048/Main.hs, /tmp/stack-sanity-check3048/Main.o )
Linking /tmp/stack-sanity-check3048/Main ...
/usr/bin/ld.bfd: /home/rajkumar/.stack/programs/x86_64-linux/ghc-8.2.1/lib64/ghc-8.2.1/rts/libHSrts.a(OSThreads.o): undefined reference to symbol 'pthread_setname_np##GLIBC_2.12'
/lib64/libpthread.so.0: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
`gcc' failed in phase `Linker'. (Exit code: 1)
So maybe the problem is that you need GLIBC_2.12 installed on your machine and not 2.26
No, that is not the issue. GLIBC-2.26 most certainly provides the pthread_setname_np##GLIBC_2.12 symbol (see this answer to understand how symbol versioning works).
You can verify that the symbol is indeed available in your GLIBC-2.26 like so:
$ readelf -Ws /lib/x86_64-linux-gnu/libpthread.so.0 | grep pthread_setname_np
89: 00000000000113c0 258 FUNC GLOBAL DEFAULT 13 pthread_setname_np##GLIBC_2.12
704: 00000000000113c0 258 FUNC GLOBAL DEFAULT 13 pthread_setname_np
(Above command was executed on a system with GLIBC-2.19, but you'll get the same output on a system with GLIBC-2.26).
Now to what your real problem is: libHSrts.a(OSThreads.o) references pthread_setname_np (and likely other pthread_* symbols, but you are not linking with -pthread or -lpthread flag.
I don't know where to add this flag to GHC, but once you find that out, your problem will be solved.
I've been trying to use stack to start a yesod-simple project, but nothing I do will build this project. I've looked into other similar stackoverflow questions but couldn't get this to work. Can some one help me figure out what I need to do to get started?
Error
> stack build
Populated index cache.
yesod-persistent-1.4.0.6: configure
yesod-persistent-1.4.0.6: build
yesod-persistent-1.4.0.6: copy/register
yesod-form-1.4.9: configure
yesod-form-1.4.9: build
yesod-form-1.4.9: copy/register
yesod-auth-1.4.15: configure
yesod-auth-1.4.15: build
Progress: 3/6
-- While building package yesod-auth-1.4.15 using:
/Users/scottyluciano/.stack/setup-exe-cache/x86_64-osx/setup-Simple-Cabal-1.22.5.0-ghc-7.10.3 --builddir=.stack-work/dist/x86_64-osx/Cabal-1.22.5.0 build --ghc-options " -ddump-hi -ddump-to-file"
Process exited with code: ExitFailure 1
Logs have been written to: /Users/scottyluciano/Documents/tutorials/practice/.stack-work/logs/yesod-auth-1.4.15.log
Configuring yesod-auth-1.4.15...
Building yesod-auth-1.4.15...
Preprocessing library yesod-auth-1.4.15...
[ 1 of 12] Compiling Yesod.PasswordStore ( Yesod/PasswordStore.hs, .stack-work/dist/x86_64-osx/Cabal-1.22.5.0/build/Yesod/PasswordStore.o )
/private/var/folders/kl/yp2gqzf116131b5gvs9pzttw0000gn/T/stack64861/yesod-auth-1.4.15/Yesod/PasswordStore.hs:166:31: Warning:
Defaulting the following constraint(s) to type ‘Integer’
(Integral b0)
arising from a use of ‘^’ at Yesod/PasswordStore.hs:166:31
(Num b0)
arising from the literal ‘32’ at Yesod/PasswordStore.hs:166:32-33
In the first argument of ‘(-)’, namely ‘2 ^ 32’
In the first argument of ‘(*)’, namely ‘(2 ^ 32 - 1)’
In the second argument of ‘(>)’, namely ‘(2 ^ 32 - 1) * hLen’
/private/var/folders/kl/yp2gqzf116131b5gvs9pzttw0000gn/T/stack64861/yesod-auth-1.4.15/Yesod/PasswordStore.hs:419:1: Warning:
Defined but not used: ‘toStrict’
/private/var/folders/kl/yp2gqzf116131b5gvs9pzttw0000gn/T/stack64861/yesod-auth-1.4.15/Yesod/PasswordStore.hs:422:1: Warning:
Defined but not used: ‘fromStrict’
[ 2 of 12] Compiling Yesod.Auth.Message ( Yesod/Auth/Message.hs, .stack-work/dist/x86_64-osx/Cabal-1.22.5.0/build/Yesod/Auth/Message.o )
/private/var/folders/kl/yp2gqzf116131b5gvs9pzttw0000gn/T/stack64861/yesod-auth-1.4.15/Yesod/Auth/Message.hs:24:1: Warning:
The import of ‘mappend’ from module ‘Data.Monoid’ is redundant
/private/var/folders/kl/yp2gqzf116131b5gvs9pzttw0000gn/T/stack64861/yesod-auth-1.4.15/Yesod/Auth/Message.hs:460:1: Warning:
Pattern match(es) are overlapped
In an equation for ‘finnishMessage’: finnishMessage Password = ...
/private/var/folders/kl/yp2gqzf116131b5gvs9pzttw0000gn/T/stack64861/yesod-auth-1.4.15/Yesod/Auth/Message.hs:460:1: Warning:
Pattern match(es) are non-exhaustive
In an equation for ‘finnishMessage’:
Patterns not matched: CurrentPassword
[ 3 of 12] Compiling Yesod.Auth.Routes ( Yesod/Auth/Routes.hs, .stack-work/dist/x86_64-osx/Cabal-1.22.5.0/build/Yesod/Auth/Routes.o )
[ 4 of 12] Compiling Yesod.Auth ( Yesod/Auth.hs, .stack-work/dist/x86_64-osx/Cabal-1.22.5.0/build/Yesod/Auth.o )
ghc: panic! (the 'impossible' happened)
(GHC version 7.10.3 for x86_64-apple-darwin):
Loading temp shared object failed: dlopen(/var/folders/kl/yp2gqzf116131b5gvs9pzttw0000gn/T/ghc65133_0/libghc_21.dylib, 5): no suitable image found. Did find:
/var/folders/kl/yp2gqzf116131b5gvs9pzttw0000gn/T/ghc65133_0/libghc_21.dylib: malformed mach-o: load commands size (36784) > 32768
Please report this as a GHC bug: http://www.haskell.org/ghc/reportabug
GHC 8.0.2 fixes the panic issue. By changing LTS to 8.0, the upgrade resolves all issues.
I want to build an off-line speech recognition application for android.For that i tried building android NDK.But when i give ndk-build command i get the following error.I have no idea what that means as i am very new to Linux environment..Anyone please help me.
Android NDK: Could not find application project directory !
Android NDK: Please define the NDK_PROJECT_PATH variable to point to it.
/home/cenuser/android/android-ndk-r7b/build/core/build-local.mk:130: *** Android NDK: Aborting . Stop.
and when i changed the location to i got this
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c:760:26: error: pocketsphinx.h: No such file or directory
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c:761:28: error: sphinxbase/err.h: No such file or directory
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c: In function 'new_Hypothesis':
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c:780: warning: initialization makes pointer from integer without a cast
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c:782: warning: assignment makes pointer from integer without a cast
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c:784: warning: assignment makes pointer from integer without a cast
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c: In function 'new_Config__SWIG_0':
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c:795: error: 'FALSE' undeclared (first use in this function)
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c:795: error: (Each undeclared identifier is reported only once
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c:795: error: for each function it appears in.)
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c: In function 'new_Config__SWIG_1':
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c:799: error: 'FALSE' undeclared (first use in this function)
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c: In function 'Config_getString':
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c:830: warning: return makes pointer from integer without a cast
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c: In function 'new_Decoder__SWIG_0':
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c:839: error: 'FALSE' undeclared (first use in this function)
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c: In function 'new_Decoder__SWIG_1':
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c:843: warning: initialization makes pointer from integer without a cast
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c: In function 'Decoder_getConfig':
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c:847: warning: return makes pointer from integer without a cast
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c: In function 'Decoder_getUttid':
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c:856: warning: return makes pointer from integer without a cast
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c: In function 'Decoder_getHyp':
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c:869: error: 'int32' undeclared (first use in this function)
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c:869: error: expected ';' before 'best_score'
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c:870: error: 'best_score' undeclared (first use in this function)
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c: In function 'Java_edu_cmu_pocketsphinx_pocketsphinxJNI_Decoder_1processRaw_1_1SWIG_10':
/home/cenuser/android/sphinx/PocketSphinxDemo/jni/pocketsphinx_wrap.c:1441: warning: assignment discards qualifiers from pointer target type
make: *** [/home/cenuser/android/sphinx/PocketSphinxDemo/obj/local/armeabi/objs-debug/pocketsphinx_jni/pocketsphinx_wrap.o] Error 1
Go to the ndk root folder from terminal
Type the command with your project path
ndk-build -C your_project_path
This will solve the problem. If you want more information on "ndk-build" command just type the command
ndk-build --help
This usually happens when you invoke ndk-build from incorrect diretory. You must be in folder which contains jni subdirectory.
Or alternatively do what error message tells you - specify NDK_PROJECT_PATH to correct folder.
you need to declare the path to the location while running the ndk-build command
1. cd
2. ndk-build NDK_PROJECT_PATH=
Go to /build/core
Change the NDK_PROJECT_PATH to app project path
Open terminal
Go to Project folder
Run the NDK_BUILD
This could be solves as follows:
I have faced the same problem. I was working on an text recognition application.
1- You should go the directory of your folder (which is inside the AndroidStudioProjects - "YOUR PROJECT",
2- There should be a jni (Java Native interface) folder. Search for this folder. whenever, this is found.
3- cd in cmd to that folder (The Parent folder of jni).
4- run **ndk-build**