ChessUSA.com TalkChess.com
Hosted by Your Move Chess & Games
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Android build fails?
Post new topic    TalkChess.com Forum Index -> Computer Chess Club: Programming and Technical Discussions Flat
View previous topic :: View next topic  
Author Message
Rasmus Althoff



Joined: 30 Aug 2016
Posts: 630

PostPost subject: Android build fails?    Posted: Fri Jul 07, 2017 11:02 pm Reply to topic Reply with quote

Hi,

I'm trying to make an Android compile of my C engine under Win7. I got the Android NDK and used that included Python script to make a standalone toolchain.

I want to simply use the GCC like I'm also using the MingW GCC, from a build batch file. So I'm calling GCC with a bunch of C files all at once, a lot of compiler options and the -o option to tell what output file I want.

That works also nicely for the bare metal GCC I'm using for the build for my microcontroller target platform. No need to set any special paths or stuff. However, the Android NDK is behaving completely differently.

Things compile nicely, all headers are found. Since I've set -Werror, unknown functions would already cause the compilation to fail.

The issue now is that I'm running into linker problems: undefined references to stuff from the C standard library. I guess that either I have to configure something to the PATH variable, possibly right in the build batch file, or that I have to add some -ldunnowhat to the compiler call to get some libraries added.

Code:
C:\Users\ras\AppData\Local\Temp\ccpdbTSL.o: In function `Play_Xboard':
play.c:(.text+0xc40): undefined reference to `signal'
play.c:(.text+0x1bd4): undefined reference to `stdout'
play.c:(.text+0x1bd8): undefined reference to `stdin'
C:\Users\ras\AppData\Local\Temp\ccpdbTSL.o: In function `main':
play.c:(.text.startup+0x118): undefined reference to `srand'
play.c:(.text.startup+0x1f4): undefined reference to `stdout'
C:\Users\ras\AppData\Local\Temp\cccu1wsd.o: In function `Book_Is_Line':
book.c:(.text+0x624): undefined reference to `rand'
C:\Users\ras\AppData\Local\Temp\cc5GGOKD.o: In function `Search_Get_Best_Mov
e':
search.c:(.text+0x3f04): undefined reference to `stdout'
collect2.exe: error: ld returned 1 exit status



On a second question, my engine is allocating around 230 MB for the hash tables on startup. I want to support also older Android devices, e.g. the Galaxy S4 mini has something like 1.5 GB RAM.

What amount of available RAM can I reasonably expect, assuming that also MP3 playback may be going on, a browser in the background, and of course some xboard-protocol capable chess GUI running?
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Subject Author Date/Time
Android build fails? Rasmus Althoff Fri Jul 07, 2017 11:02 pm
      Re: Android build fails? Jon Dart Sat Jul 08, 2017 2:57 am
            Re: Android build fails? Rasmus Althoff Sat Jul 08, 2017 9:04 am
      Re: Android build fails? Rasmus Althoff Thu Jul 13, 2017 10:40 pm
            Re: Android build fails? Salvatore Giannotti Tue Sep 19, 2017 1:33 pm
                  Re: Android build fails? Gurcan Uckardes Sat Sep 23, 2017 3:23 pm
                        Re: Android build fails? Rasmus Althoff Sat Sep 30, 2017 5:50 pm
                        Re: Android build fails? Salvatore Giannotti Mon Dec 04, 2017 10:42 pm
                              Re: Android build fails? Aart Bik Tue Dec 05, 2017 6:20 pm
                                    Re: Android build fails? Salvatore Giannotti Tue Dec 05, 2017 9:04 pm
            Re: Android build fails? Rasmus Althoff Wed Nov 29, 2017 12:05 am
Post new topic    TalkChess.com Forum Index -> Computer Chess Club: Programming and Technical Discussions

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum




Powered by phpBB © 2001, 2005 phpBB Group
Enhanced with Moby Threads