Rework how standard C library handling is done.
commit1f8bf3e195d25a27c34f2e5767eef812b9432106
authorThomas Martitz <thomas.martitz@student.htw-berlin.de>
Sun, 2 May 2010 00:43:30 +0000 (2 02:43 +0200)
committerThomas Martitz <thomas.martitz@student.htw-berlin.de>
Sun, 2 May 2010 01:07:29 +0000 (2 03:07 +0200)
tree92f980b5c76f6b2f2f77b0777073a386c314744c
parent8129c255a77a6759f06f4e7a1d170a2def83c17e
Rework how standard C library handling is done.

* Move standard C libraries into firmware/libc and their headers into firmware/libc/includes.
* Don't compile these for the sim, and link the OS library instead, and fix up code that didn't work with that.
* This means a lot of clean up with w.r.t. to includes, so update most files.
* strlcpy/strlcat/strcasecmp/strcasecmp now in string-extra.h as they're not ANSI C.
216 files changed:
apps/alarm_menu.c
apps/apps.make
apps/bookmark.c
apps/buffering.c
apps/buffering.h
apps/codecs.c
apps/codecs.h
apps/codecs/adx.c
apps/codecs/demac/demac.c
apps/codecs/demac/libdemac/parser.c
apps/codecs/demac/wavwrite.c
apps/codecs/lib/codeclib.h
apps/codecs/lib/codeclib_misc.h
apps/codecs/lib/tlsf/src/tlsf.c
apps/codecs/lib/tlsf/src/tlsf.h
apps/codecs/libatrac/main.c
apps/codecs/libcook/main.c
apps/codecs/libfaad/common.h
apps/codecs/libfaad/faad_config.h
apps/codecs/libffmpegFLAC/main.c
apps/codecs/libmad/decoder.c
apps/codecs/libmad/libmad.make
apps/codecs/libpcm/adpcm_seek.h
apps/codecs/libpcm/ima_adpcm_common.h
apps/codecs/libpcm/pcm_common.h
apps/codecs/librm/rm.c
apps/codecs/libspeex/config-speex.h
apps/codecs/libspeex/speex/speex_types.h
apps/codecs/libtremor/config-tremor.h
apps/codecs/libtremor/ctype.c
apps/codecs/libtremor/misc.h
apps/codecs/libwavpack/words.c
apps/cuesheet.c
apps/debug_menu.c
apps/enc_config.c
apps/filetree.c
apps/filetypes.c
apps/gui/bitmap/list.c
apps/gui/charcell/list.c
apps/gui/list.c
apps/gui/option_select.c
apps/gui/pitchscreen.c
apps/gui/skin_engine/skin_backdrops.c
apps/gui/skin_engine/skin_display.c
apps/gui/skin_engine/skin_tokens.c
apps/gui/statusbar.c
apps/gui/usb_screen.c
apps/gui/viewport.c
apps/gui/wps.c
apps/main.c
apps/menus/eq_menu.c
apps/menus/recording_menu.c
apps/menus/settings_menu.c
apps/menus/time_menu.c
apps/metadata.c
apps/metadata/metadata_common.c
apps/metadata/mp3.c
apps/metadata/smaf.c
apps/misc.c
apps/onplay.c
apps/player/keyboard.c
apps/playlist.c
apps/playlist_catalog.c
apps/playlist_viewer.c
apps/plugin.c
apps/plugin.h
apps/plugins/calculator.c
apps/plugins/doom/d_deh.c
apps/plugins/doom/doom.make
apps/plugins/doom/rockmacros.h
apps/plugins/frotz/frotz.c
apps/plugins/frotz/frotzplugin.h
apps/plugins/imageviewer/png/zconf.h
apps/plugins/invadrox.c
apps/plugins/lib/buflib.c
apps/plugins/lib/jhash.h
apps/plugins/lib/strncpy.c
apps/plugins/lua/gmtime.c
apps/plugins/lua/malloc.c
apps/plugins/lua/strftime.c
apps/plugins/midi/midiplay.c
apps/plugins/midi/midiutil.c
apps/plugins/midi/midiutil.h
apps/plugins/pdbox/PDa/extra/dumpOSC.c
apps/plugins/pdbox/PDa/extra/sendOSC.c
apps/plugins/pdbox/PDa/extra/shell.c
apps/plugins/pdbox/PDa/src/d_array.c
apps/plugins/pdbox/PDa/src/d_osc.c
apps/plugins/pdbox/PDa/src/d_soundfile.c
apps/plugins/pdbox/PDa/src/s_audio_alsa.c
apps/plugins/pdbox/PDa/src/s_audio_oss.c
apps/plugins/pdbox/PDa/src/s_file.c
apps/plugins/pdbox/PDa/src/s_inter.c
apps/plugins/pdbox/PDa/src/s_main.c
apps/plugins/pdbox/PDa/src/s_midi.c
apps/plugins/pdbox/PDa/src/s_midi_oss.c
apps/plugins/pdbox/PDa/src/s_midi_sgi.c
apps/plugins/pdbox/PDa/src/s_watchdog.c
apps/plugins/pdbox/PDa/src/t_tkcmd.c
apps/plugins/pdbox/PDa/src/u_pdreceive.c
apps/plugins/pdbox/PDa/src/u_pdsend.c
apps/plugins/pdbox/PDa/src/x_misc.c
apps/plugins/pdbox/PDa/src/x_net.c
apps/plugins/random_folder_advance_config.c
apps/plugins/rockboy/rockboy.make
apps/plugins/rockboy/rtc.c
apps/plugins/search.c
apps/plugins/stats.c
apps/plugins/wav2wv.c
apps/plugins/zxbox/helpers.h
apps/plugins/zxbox/snapshot.c
apps/plugins/zxbox/spconf.c
apps/plugins/zxbox/sptape.c
apps/plugins/zxbox/tapefile.c
apps/plugins/zxbox/zxmisc.h
apps/recorder/albumart.c
apps/recorder/icons.c
apps/recorder/jpeg_load.c
apps/recorder/keyboard.c
apps/recorder/peakmeter.c
apps/recorder/radio.c
apps/recorder/recording.c
apps/replaygain.c
apps/root_menu.c
apps/screen_access.c
apps/screens.c
apps/scrobbler.c
apps/settings.c
apps/settings_list.c
apps/tagcache.c
apps/tagtree.c
apps/talk.c
apps/tree.c
firmware/SOURCES
firmware/common/dircache.c
firmware/common/format.c [moved from firmware/common/sprintf.c with 76% similarity]
firmware/common/strlcat.c
firmware/common/strlcpy.c
firmware/common/timefuncs.c
firmware/drivers/lcd-bitmap-common.c
firmware/drivers/lcd-charcell.c
firmware/drivers/tuner/lv24020lp.c
firmware/export/audio.h
firmware/export/config/sim.h
firmware/export/pcm.h
firmware/export/structec.h
firmware/firmware.make
firmware/general.c
firmware/ifp_usb_serial.c
firmware/include/file.h
firmware/include/format.h [moved from firmware/include/sprintf.h with 77% similarity]
firmware/include/inttypes.h
firmware/include/memory.h
firmware/include/strcasecmp.h [copied from firmware/include/sscanf.h with 78% similarity]
firmware/include/strcasestr.h [moved from uisimulator/sdl/sprintf.h with 66% similarity]
firmware/include/string-extra.h [copied from firmware/include/sscanf.h with 78% similarity]
firmware/include/strlcat.h [copied from firmware/include/sscanf.h with 78% similarity]
firmware/include/strlcpy.h [moved from firmware/include/sscanf.h with 78% similarity]
firmware/include/sys/types.h [deleted file]
firmware/include/timefuncs.h
firmware/libc/atoi.c [moved from firmware/common/atoi.c with 100% similarity]
firmware/libc/ctype.c [moved from firmware/common/ctype.c with 100% similarity]
firmware/libc/errno.c [moved from firmware/common/errno.c with 100% similarity]
firmware/libc/include/ctype.h [moved from firmware/include/ctype.h with 100% similarity]
firmware/libc/include/errno.h [moved from firmware/include/errno.h with 100% similarity]
firmware/libc/include/stdio.h [moved from firmware/include/stdio.h with 59% similarity]
firmware/libc/include/stdlib.h [moved from firmware/include/stdlib.h with 94% similarity]
firmware/libc/include/string.h [moved from firmware/include/string.h with 99% similarity]
firmware/libc/include/time.h [moved from firmware/include/time.h with 69% similarity]
firmware/libc/memchr.c [moved from firmware/common/memchr.c with 100% similarity]
firmware/libc/memcmp.c [moved from firmware/common/memcmp.c with 100% similarity]
firmware/libc/memcpy.c [moved from firmware/common/memcpy.c with 100% similarity]
firmware/libc/memmove.c [moved from firmware/common/memmove.c with 100% similarity]
firmware/libc/memset.c [moved from firmware/common/memset.c with 99% similarity]
firmware/libc/mktime.c [copied from firmware/include/timefuncs.h with 53% similarity]
firmware/libc/qsort.c [moved from firmware/common/qsort.c with 100% similarity]
firmware/libc/random.c [moved from firmware/common/random.c with 100% similarity]
firmware/libc/sprintf.c [new file with mode: 0644]
firmware/libc/sscanf.c [moved from firmware/common/sscanf.c with 100% similarity]
firmware/libc/strcat.c [moved from firmware/common/strcat.c with 100% similarity]
firmware/libc/strchr.c [moved from firmware/common/strchr.c with 100% similarity]
firmware/libc/strcmp.c [moved from firmware/common/strcmp.c with 100% similarity]
firmware/libc/strcpy.c [moved from firmware/common/strcpy.c with 100% similarity]
firmware/libc/strlen.c [moved from firmware/common/strlen.c with 100% similarity]
firmware/libc/strncmp.c [moved from firmware/common/strncmp.c with 100% similarity]
firmware/libc/strrchr.c [moved from firmware/common/strrchr.c with 100% similarity]
firmware/libc/strstr.c [moved from firmware/common/strstr.c with 100% similarity]
firmware/libc/strtok.c [moved from firmware/common/strtok.c with 100% similarity]
firmware/profile.c
firmware/rolo.c
firmware/target/arm/as3525/debug-as3525.c
firmware/target/arm/imx31/debug-imx31.c
firmware/target/arm/imx31/gigabeat-s/lcd-gigabeat-s.c
firmware/target/arm/ipod/video/lcd-video.c
firmware/target/arm/lcd-c200_c200v2.c
firmware/target/arm/philips/hdd1630/lcd-hdd1630.c
firmware/target/arm/pnx0101/iriver-ifp7xx/usb-ifp7xx.c
firmware/target/arm/s3c2440/debug-s3c2440.c
firmware/target/arm/s3c2440/lcd-s3c2440.c
firmware/target/arm/s5l8700/debug-s5l8700.c
firmware/target/arm/samsung/yh820/lcd-yh820.c
firmware/target/arm/sandisk/sansa-e200/lcd-e200.c
firmware/target/arm/tcc77x/debug-tcc77x.c
firmware/target/arm/tcc77x/iaudio7/ata2501.c
firmware/target/arm/tcc780x/cowond2/lcd-cowond2.c
firmware/target/arm/tcc780x/debug-tcc780x.c
firmware/target/arm/tms320dm320/creative-zvm/pic-creativezvm.c
firmware/target/arm/tms320dm320/debug-dm320.c
firmware/target/arm/usb-s3c6400x.c
firmware/target/arm/usb-tcc.c
firmware/target/mips/ingenic_jz47xx/lcd-jz4740.c
firmware/target/mips/ingenic_jz47xx/system-jz4740.c
firmware/test/snprintf/test.c
firmware/thread.c
firmware/usb.c
tools/configure