It might be worth noting that need to have python2 on your path for it to build MAME2014
I haven’t even tried to build for android though
Did you failed with an error related to the issue i post about netlist in 0.152 ? https://github.com/libretro/mame-libretro/issues/20 or something else ?
The netlist code is apparently necessary for discrete emulation (ie. Pong) - so copy and pasting the sources from 0.151 would likely break Pong. But I guess getting the thing to compile at all would be better than not getting it to compile in the first place.
Yes , it’s why i backported also pong’s driver ( see the above github issue ) , although i’ve not testing PONG yet in mame 0.152 android ,to see if it work.
By the way , in the SVN code , also issue the same pb with netlist code , but backport is more difficult because structure is completely different and now not only use in PONG (see aleisttl.c in mame/drivers/ ) but also for example in Allied Leisure discrete hardware games.
Related to the error , anyone know why just undef the _C (marco used in ndk tc) not working ?
@7rtype, yes that was the original problem when I tried to compile 0.152 but for a while now the issues that’s been kicking my butt is this:
n3dev@n3dev-vm:~/android/libretro-super/libretro-mame/0152$ make -f Makefile.libretro "VRENDER=soft" "platform=android" emulator
Makefile.libretro:721: warning: overriding commands for target `obj/retro64/build/file2str'
src/build/build.mak:63: warning: ignoring old commands for target `obj/retro64/build/file2str'
Makefile.libretro:728: warning: overriding commands for target `obj/retro64/build/png2bdc'
src/build/build.mak:115: warning: ignoring old commands for target `obj/retro64/build/png2bdc'
Makefile.libretro:731: warning: overriding commands for target `obj/retro64/build/makedep'
src/build/build.mak:76: warning: ignoring old commands for target `obj/retro64/build/makedep'
Makefile.libretro:734: warning: overriding commands for target `obj/retro64/build/makelist'
src/build/build.mak:102: warning: ignoring old commands for target `obj/retro64/build/makelist'
Makefile.libretro:737: warning: overriding commands for target `obj/retro64/build/verinfo'
src/build/build.mak:128: warning: ignoring old commands for target `obj/retro64/build/verinfo'
cp -R prec-build/makelist obj/retro64/build
Linking obj/retro64/build/makemak...
g++ -Wl,--warn-common -lstdc++ obj/retro64/build/makemak.o obj/retro64/libutil.a obj/retro64/libocore.a -lstdc++ -lz -o obj/retro64/build/makemak
/usr/bin/ld: obj/retro64/libutil.a(astring.o): Relocations in generic ELF (EM: 40)
/usr/bin/ld: obj/retro64/libutil.a(astring.o): Relocations in generic ELF (EM: 40)
/usr/bin/ld: obj/retro64/libutil.a(astring.o): Relocations in generic ELF (EM: 40)
/usr/bin/ld: obj/retro64/libutil.a(astring.o): Relocations in generic ELF (EM: 40)
/usr/bin/ld: obj/retro64/libutil.a(astring.o): Relocations in generic ELF (EM: 40)
obj/retro64/libutil.a: error adding symbols: File in wrong format
collect2: error: ld returned 1 exit status
make: *** [obj/retro64/build/makemak] Error 1
I’ve been banging my head for a while now on this, I have even setup new VM’s with a fresh installs of kubuntu (this time 13.10 instead of 13.04) with fresh android NDK’s & toolchains, fresh git clones and easily reproducible each time and coping makemak from prebuilt doesn’t make a difference. I know it’s a cross compile issue but at this point I’m not sure what to do next.
thinks you could try to add in makefile.libretro after line 770 to override the rule for makemak .
$(OBJ)/build/makemak:
cp -R prec-build/makemak $(OBJ)/build
this should works i think.
In this case you have to copy also the makemak.o along with makemak.
lol, yeah i figured that out too, but full change needs to be from:
$(OBJ)/build/makedep:
cp -R prec-build/makelist $(OBJ)/build
$(OBJ)/build/makelist:
cp -R prec-build/makelist $(OBJ)/build
to
$(OBJ)/build/makedep:
cp -R prec-build/makedep $(OBJ)/build
$(OBJ)/build/makelist:
cp -R prec-build/makelist $(OBJ)/build
$(OBJ)/build/makemak:
cp -R prec-build/makemak $(OBJ)/build
I also noticed something else, just cosmetics but
$(OBJ)/%.o: $(SRC)/%.c | $(OSPREBUILD)
$(CC) $(CDEFS) $(CFLAGS) -c $< -o $@
to
$(OBJ)/%.o: $(SRC)/%.c | $(OSPREBUILD)
@echo Compiling $<..
$(CC) $(CDEFS) $(CFLAGS) -c $< -o $@
I post a ticket on git hub, asap. thnx again
I also ran into this issue
Compiling src/emu/uimenu.c..
Compiling src/emu/validity.c..
Compiling src/emu/debug/debugcmd.c..
src/emu/validity.c:23:57: error: size of array 'your_ptr64_flag_is_wrong' is negative
UINT8 your_ptr64_flag_is_wrong[(int)(sizeof(void *) - 7)];
^
make: *** [obj/retro64/emu/validity.o] Error 1
make: *** Waiting for unfinished jobs....
I had to remove PTR=1 in line 61 of Makefile.libretro.
I think that was required for WIN64, I’ll test and add it only to the relevant part of the makefile
You should not remove ptr , else it break win and lin 64bits compile I build from lin64 and dont have thrse pb all build fine.
if you are in 64 bit you only have to use -DPTR=64 for the buildtools not for emulator as android tc is 32 bits You should do a make clean and restart all the compile. Look at github there are a readme that explain command line to build for android.
For Win64 I use this in libretro-build-common.sh:
build_libretro_mame() {
cd "${BASE_DIR}"
if [ -d 'libretro-mame' ]; then
echo.
echo '=== Building MAME ==='
cd libretro-mame/0152
if [ $PROCESSOR_ARCHITEW6432 = "AMD64" ]; then
echo '=== Building MAME64 ==='
"${MAKE}" -f Makefile.libretro platform="${FORMAT_COMPILER_TARGET}" ${COMPILER} "-j${JOBS}" clean || die 'Failed to clean MAME'
"${MAKE}" PTR64=1 -f Makefile.libretro platform="${FORMAT_COMPILER_TARGET}" ${COMPILER} "-j${JOBS}" || die "Failed to build MAME"
else
echo '=== Building MAME32 ==='
"${MAKE}" -f Makefile.libretro platform="${FORMAT_COMPILER_TARGET}" ${COMPILER} "-j${JOBS}" clean || die 'Failed to clean MAME'
"${MAKE}" -f Makefile.libretro platform="${FORMAT_COMPILER_TARGET}" ${COMPILER} "-j${JOBS}" || die "Failed to build MAME"
fi
cp "mame_libretro${FORMAT}.${FORMAT_EXT}" "${RARCH_DIST_DIR}"
else
echo 'MAME not fetched, skipping ...'
fi
}
I’m not sure about a siimilar check for Lin64.
Ok i was talking about android compile .
for win64/lin64 : make -f Makefile.libretro “PTR64=1” -j4
for android (with host in 64 bits) compilation in 2 times : make -f Makefile.libretro “NATIVE=1” “PTR64=1” buildtools then make -f Makefile.libretro “platform=android” emulator -j4
Ok there is an error on the makefile ,2 time “cp -R prec-build/makelist $(OBJ)/build” and then fault for makedep. i commit a fix.
Edit:
Ha ok i was missing this one, it will break all 32 compilation, then android one too. You have to put in the make command line “PTR64=1” for the WIN64 compile as the flag is not set correctly ( unlike in linux64 as the flag is put correctly ) .
I can read and understand your French but unfortunately I’m too rusty with mine to reply back en français, so I’ll attempt to undo some of the confusion as best as I can:
In my libretro-build-common.sh I have added a check to see if the script is running on Win64 which then adds the PTR=1 to the bash/commandline if not then it assumes it’s 32bit and compiles without the PTR=1. I need to add a check for Lin64 so this will work with both Windows & Linux and without the need of having PTR=1 at line 61 still inside MAME 0.152’s Makefile.libretro which causes the Android port to fail when compiling.
For Android, I do exactly the two step method that you documented to compile MAME 0.152, but it will not work with PTR=1 at line 61 still inside MAME 0.152’s Makefile.libretro. I can successfully compile for Android again, like I have been doing previously prior to 0.152 when I remove PTR=1 at line 61 inside MAME 0.152’s Makefile.libretro.
Please re-read my code from my previous post then hopefully it makes since and helps clear things up.
Yes sorry for the french , lol i was not yet awake, i had edit it.
And yes (now i m awake ) i saw this PTR64 in line 61 and it was a bad error as it break all 32bit compile , But as i m only compiling SVN version for now , i never notice it. i had answer on github and put a commit to remove it .
lol, thanks
What about my idea of automating the 32bit & 64bit compiles of MAME for Linux & Windows in libretro-build-common.sh? Another thought would be to add a check for
$PROCESSOR_ARCHITEW6432 = "AMD64"
to also set X86=true && X86_64=true in libretro-config.sh for Win64 then change my code for libretro-build-common.sh to check for X86_64=true to set the PTR=1 flag.
Please test these, mame and mess x64 https://dl.dropboxusercontent.com/u/149 … bretro.zip
Only cart games work, adding “auto media detection” for MESS, readme here:
RetroArch-2014-03-18
Android: Updated: RetroArch, FinalBurnAlpha, FCEU, Gambatte, Genplus GX, MAME2003, Mupen64plus, Stella
Win64: RetroArch, Common-Shaders, DeSmuME-future, ffmpeg , FinalBurnAlpha, FCEU, Gambatte, Genplus GX, MAME2014, Mednafen, Mupen64plus, Stella Added: MESS2014, UME2014 Recompiled bSNEs back to gcc 4.7.3 for cx4 games
Added: Quake shareware for Tyrquake
NOTE: For best results with Android port, be sure to uninstall previous version before installing newer versions.
Notes: MESS games must be in the correct MESS system path, ie: games\mess es\gamename.zip, games\mess\coleco\gamename.zip
I was able to play an Atari 2600 game in folder called: C:\Games\roms\a2600
So far 32x failed due to MESS not finding the 32x bos files, UME seems to might work but wants the MESS softlist.
EDIT: I had forgotten for MESS to zip up the 32x bios files named 32x.zip in the 32x folder.
MESS
ONLY CART GAMES WORKING AS OF NOW
autodetection of media type for common systems
global retropad assignment
per driver retropad mappings for common systems
support for soflist games
Those notes are TODO by the way, those are not implemented
Gotcha, also I wasn’t sure what to tag MESS & UME, so I went with MULTI when I was creating the info files.