Instructions to compile for android

2 replies [Last post]
francot514
User offline. Last seen 1 year 21 weeks ago. Offline
Joined: 2015-03-20
Posts: 163
Hey i need some instruction to compile project, mostly how to use freepascal and pas2c to get so files
Wuzzy
Wuzzy's picture
User offline. Last seen 4 days 3 hours ago. Offline
Joined: 2012-06-20
Posts: 1301
I am not responsible for the Anrdoid build, and I don't know if it still works, but here's a guide: https://hedgewars.org/kb/BuildingForAndroid The guide might be outdated, I don't know. The main platform for Hedgewars is still PC. If you manage to build it somehow, please let me know! Smile I hope someone else from our team shows up to answer this question.
Hi, I am a Hedgewars developer. Smile
sheepluva
sheepluva's picture
User is online Online
Joined: 2009-07-18
Posts: 561
My build setup partially died with my SSD recently, but here's some hints/downfalls I remember or see in my current local repo diff: * Building a 64-bit binary is the default these days and pretty much mandatory, even if you decide to (additionally) build for a 32-bit target. * Make sure to provide the 64-bit versions of the libraries to the 64-bit build (and 32-bit to the 32-bit build, if you're going for that) * Since you will need different FPC cross-compilers inluding their respective run-time libraries and such, I found the program FPCupdeluxe extremly helpful. It's purpose is to generate FPC cross-compilers tailored to your needs. * I build with local libphysfs in the repo. We removed it from there a while ago, so you'll have to place it in misc/ again manually. Also you may want to checkout misc/libphysfs/Android.mk from a revision before it was deleted ( 0e113487c4b2 ) * If you're trying to build using SDL2, you'll have to replace/update the SDL project files in the repos, which are partially just copied of the boilerplate/example code iirc * project_files/Android-build/download_libs.sh is full of dead links, you'll have to manually download these * In hedgewars/uWorld.pas it seems I ran into an compiler issue: [code] -procedure ShiftWorld(Dir: LongInt); inline; +// inlining this with fpc-dev for aarch64-android produced garbage asm for me +procedure ShiftWorld(Dir: LongInt);{$IFNDEF ANDROID} inline;{$ENDIF} [/code]
  [url=/user/3290][color=white][b]sheepluva[/b][/color][/url][color=#90BA5D] <- me[float=right]  [/float][float=right][url=https://www.openhub.net/accounts/80048][img]https://www.openhub.net/accounts/80048/widgets/account_tiny.gif[/img][/url][/float][float=right]my code stats -> [/float][/color] [i][color=#6080C0][size=8]a[size=4] [/size][/size][/color][color=yellow]Hedgewars Developer[/color][/i] [center][float=left]  [/float][float=left][url=https://twitter.com/sheepytweety][img]/images/twitter.png[/img][/url][/float] [url=/privatemsg/new/3290][color=#C0C0C0]click here to message me[/color][/url][/center] [color=#90BA5D][float=left]  [/float][float=left][url=https://en.wikipedia.org/wiki/Austria][img]/images/Flags/austria.png[/img][/url][/float][float=left] <- where I'm from[/float][float=right]  [/float][float=right][img]/images/Flags/united_kingdom.png[/img][/float][float=right][img]/images/Flags/germany.png[/img][/float][float=right]what I speak -> [/float][/color]
Copyright © 2004-2023 Hedgewars Project. All rights reserved. [ contact ]