| View previous topic :: View next topic |
| Author |
Message |
liberty
Joined: 16 Sep 2009 Posts: 35
|
Posted: Mon Oct 12, 2009 10:17 pm Post subject: |
|
|
| coolkehon wrote: | | so are you going to do it? |
Yes, I am going to.
But seems not very easy.
I get the many errors compiling it. It cannot find printf, exit, fopen, fseek ... ALL libc function.
I don't know whether I do the right thing:
1. Modify the config.sub, add psp
2. Modify the configure file, so it won't get error about executable.
3. LDFLAGS="-L$(psp-config --pspsdk-path)/lib -lpspuser -lc"
CFLAGS="-ffast-math -fsigned-char -G0"
I have also tried -lpsplibc. It also does not work.
4. ./configure --host=psp --prefix=$(psp-config --psp-prefix)
5. make
Some error like this:
| Code: |
psp-gcc -g -O2 -Wall -o ../bin/find_sts find_sts_main.o -L../build/mipsallegrexel-elf/lib -L/opt/pspdev//psp/sdk/lib -L/opt/pspdev/psplib/ -lflite -lpsplibc -lm
/home/Liberty/programs/pspdev/bin/../lib/gcc/psp/4.3.2/../../../../psp/lib/crt0.o: In function `_start':
/home/Liberty/install/psptoolchain/build/pspsdk/src/startup/crt0.c:149: undefined reference to `sceKernelCreateThread'
/home/Liberty/install/psptoolchain/build/pspsdk/src/startup/crt0.c:150: undefined reference to `sceKernelStartThread'
find_sts_main.o: In function `save_sts':
/home/Liberty/install/flite-1.3-release/tools/find_sts_main.c:197: undefined reference to `_impure_ptr'
/home/Liberty/install/flite-1.3-release/tools/find_sts_main.c:197: relocation truncated to fit: R_MIPS_GPREL16 against `_impure_ptr'
find_sts_main.o: In function `main':
/home/Liberty/install/flite-1.3-release/tools/find_sts_main.c:226: undefined reference to `_impure_ptr'
/home/Liberty/install/flite-1.3-release/tools/find_sts_main.c:226: relocation truncated to fit: R_MIPS_GPREL16 against `_impure_ptr'
/home/Liberty/install/flite-1.3-release/tools/find_sts_main.c:236: undefined reference to `_impure_ptr'
/home/Liberty/install/flite-1.3-release/tools/find_sts_main.c:236: relocation truncated to fit: R_MIPS_GPREL16 against `_impure_ptr'
../build/mipsallegrexel-elf/lib/libflite.a(cst_error.o): In function `cst_errmsg':
/home/Liberty/install/flite-1.3-release/src/utils/cst_error.c:101: undefined reference to `_impure_ptr'
/home/Liberty/install/flite-1.3-release/src/utils/cst_error.c:101: relocation truncated to fit: R_MIPS_GPREL16 against `_impure_ptr'
../build/mipsallegrexel-elf/lib/libflite.a(cst_track_io.o): In function `cst_track_load_est':
/home/Liberty/install/flite-1.3-release/src/speech/cst_track_io.c:217: undefined reference to `atoi'
/home/Liberty/install/flite-1.3-release/src/speech/cst_track_io.c:219: undefined reference to `atoi'
../build/mipsallegrexel-elf/lib/libflite.a(cst_string.o): In function `cst_upcase':
/home/Liberty/install/flite-1.3-release/src/utils/cst_string.c:146: undefined reference to `__ctype_ptr'
/home/Liberty/install/flite-1.3-release/src/utils/cst_string.c:146: relocation truncated to fit: R_MIPS_GPREL16 against `__ctype_ptr'
/home/Liberty/install/flite-1.3-release/src/utils/cst_string.c:144: undefined reference to `__ctype_ptr'
/home/Liberty/install/flite-1.3-release/src/utils/cst_string.c:144: relocation truncated to fit: R_MIPS_GPREL16 against `__ctype_ptr'
../build/mipsallegrexel-elf/lib/libflite.a(cst_string.o): In function `cst_downcase':
/home/Liberty/install/flite-1.3-release/src/utils/cst_string.c:132: undefined reference to `__ctype_ptr'
/home/Liberty/install/flite-1.3-release/src/utils/cst_string.c:132: relocation truncated to fit: R_MIPS_GPREL16 against `__ctype_ptr'
/home/Liberty/install/flite-1.3-release/src/utils/cst_string.c:130: undefined reference to `__ctype_ptr'
/home/Liberty/install/flite-1.3-release/src/utils/cst_string.c:130: relocation truncated to fit: R_MIPS_GPREL16 against `__ctype_ptr'
../build/mipsallegrexel-elf/lib/libflite.a(cst_tokenstream.o): In function `ts_close':
/home/Liberty/install/flite-1.3-release/src/utils/cst_tokenstream.c:185: undefined reference to `_impure_ptr'
/home/Liberty/install/flite-1.3-release/src/utils/cst_tokenstream.c:185: relocation truncated to fit: R_MIPS_GPREL16 against `_impure_ptr'
../build/mipsallegrexel-elf/lib/libflite.a(cst_tokenstream.o): In function `ts_open':
/home/Liberty/install/flite-1.3-release/src/utils/cst_tokenstream.c:147: undefined reference to `_impure_ptr'
/home/Liberty/install/flite-1.3-release/src/utils/cst_tokenstream.c:147: relocation truncated to fit: R_MIPS_GPREL16 against `_impure_ptr'
../build/mipsallegrexel-elf/lib/libflite.a(cst_val.o): In function `val_int':
/home/Liberty/install/flite-1.3-release/src/utils/cst_val.c:136: undefined reference to `atoi'
/opt/pspdev//psp/sdk/lib/libpsplibc.a(vprintf.o): In function `vprintf':
/home/Liberty/install/psptoolchain/build/pspsdk/src/libc/xprintf.c:973: undefined reference to `sceIoWrite'
/opt/pspdev//psp/sdk/lib/libpsplibc.a(fclose.o): In function `fclose':
/home/Liberty/install/psptoolchain/build/pspsdk/src/libc/stdio.c:115: undefined reference to `sceIoClose'
/opt/pspdev//psp/sdk/lib/libpsplibc.a(fopen.o): In function `fopen':
/home/Liberty/install/psptoolchain/build/pspsdk/src/libc/stdio.c:472: undefined reference to `sceIoOpen'
/opt/pspdev//psp/sdk/lib/libpsplibc.a(fread.o): In function `fread':
/home/Liberty/install/psptoolchain/build/pspsdk/src/libc/stdio.c:646: undefined reference to `sceIoRead'
|
I think it is not hard to resolve. But help![/code] |
|
| Back to top |
|
 |
mypspdev
Joined: 11 Jul 2007 Posts: 178
|
Posted: Tue Oct 13, 2009 7:20 am Post subject: |
|
|
I'm reading just now....
If anybody is interested in Flite (Text to speech) for PSP and PocketSphinx (Speech recognition) for PSP1000 (few commands) PSP2000 and PSP3000 (full dictionary), using all microphones Gocam, Socom, USB Microphone, PSP3000 microphone, let me know, I'll send you full package and libraries.
Regards |
|
| Back to top |
|
 |
J.F.
Joined: 22 Feb 2004 Posts: 2906
|
Posted: Tue Oct 13, 2009 9:22 am Post subject: |
|
|
| Been very busy, but I'll try to look at it myself sometime in the next few weeks. |
|
| Back to top |
|
 |
Art
Joined: 09 Nov 2005 Posts: 647
|
Posted: Tue Oct 13, 2009 10:26 am Post subject: |
|
|
Good to see you got the PSP3000 mic working.
I still would like to see the voice recognition working on the PSP1000,
even if with limited words. _________________ If not actually, then potentially. |
|
| Back to top |
|
 |
liberty
Joined: 16 Sep 2009 Posts: 35
|
Posted: Tue Oct 13, 2009 11:30 am Post subject: |
|
|
| mypspdev wrote: | I'm reading just now....
If anybody is interested in Flite (Text to speech) for PSP and PocketSphinx (Speech recognition) for PSP1000 (few commands) PSP2000 and PSP3000 (full dictionary), using all microphones Gocam, Socom, USB Microphone, PSP3000 microphone, let me know, I'll send you full package and libraries.
Regards |
I am interested in porting Flite. Do you have the package that can be compiled? |
|
| Back to top |
|
 |
mypspdev
Joined: 11 Jul 2007 Posts: 178
|
Posted: Tue Oct 13, 2009 8:29 pm Post subject: |
|
|
| liberty wrote: | | mypspdev wrote: | I'm reading just now....
If anybody is interested in Flite (Text to speech) for PSP and PocketSphinx (Speech recognition) for PSP1000 (few commands) PSP2000 and PSP3000 (full dictionary), using all microphones Gocam, Socom, USB Microphone, PSP3000 microphone, let me know, I'll send you full package and libraries.
Regards |
I am interested in porting Flite. Do you have the package that can be compiled? |
yes sure, it's impemented into MyPSP as well as within some work of Art... under pspsdk...
let me have time to prepare the zip... |
|
| Back to top |
|
 |
liberty
Joined: 16 Sep 2009 Posts: 35
|
Posted: Tue Oct 13, 2009 10:23 pm Post subject: |
|
|
| mypspdev wrote: | | liberty wrote: | | mypspdev wrote: | I'm reading just now....
If anybody is interested in Flite (Text to speech) for PSP and PocketSphinx (Speech recognition) for PSP1000 (few commands) PSP2000 and PSP3000 (full dictionary), using all microphones Gocam, Socom, USB Microphone, PSP3000 microphone, let me know, I'll send you full package and libraries.
Regards |
I am interested in porting Flite. Do you have the package that can be compiled? |
yes sure, it's impemented into MyPSP as well as within some work of Art... under pspsdk...
let me have time to prepare the zip... |
Great work! |
|
| Back to top |
|
 |
whistler
Joined: 04 Mar 2008 Posts: 40
|
Posted: Wed Oct 14, 2009 3:59 am Post subject: |
|
|
| thanks mypspdev, could you post a link to the zip or send a pm:) |
|
| Back to top |
|
 |
liberty
Joined: 16 Sep 2009 Posts: 35
|
Posted: Wed Oct 14, 2009 10:13 am Post subject: |
|
|
| whistler wrote: | | thanks mypspdev, could you post a link to the zip or send a pm:) |
If it is ready, please post here. Thanks! |
|
| Back to top |
|
 |
mypspdev
Joined: 11 Jul 2007 Posts: 178
|
Posted: Thu Oct 15, 2009 3:33 am Post subject: |
|
|
....you both interested of Flite should have MP....
(with package and ready to be recompiled solutions ...) |
|
| Back to top |
|
 |
whistler
Joined: 04 Mar 2008 Posts: 40
|
Posted: Sat Oct 17, 2009 12:29 am Post subject: |
|
|
mypspdev, i've downloaded the flite lib and even though i'm not that familiar with it this is the code and makefile i'm using as a simple test
| Code: | #include <pspkernel.h>
#include <flite/flite.h>
cst_voice *register_cmu_us_kal();
PSP_MODULE_INFO("exflite", 0, 1, 1);
int main()
{
cst_voice *v;
flite_init();
v = register_cmu_us_kal ();
flite_text_to_speech("How are you today", v, "play");
sceKernelExitGame();
return 0;
}
|
| Code: |
TARGET = exflite
OBJS = exflite.o
BUILD_PRX=1
INCDIR =
CFLAGS = -O2 -G0 -Wall
CXXFLAGS = $(CFLAGS) -fno-exceptions -fno-rtti
ASFLAGS = $(CFLAGS)
LIBDIR =
LDFLAGS =
LIBS = -lflite -lm -lpspaudio -lpspaudiolib
EXTRA_TARGETS = EBOOT.PBP
PSP_EBOOT_TITLE = Speech Sample
PSPSDK=$(shell psp-config --pspsdk-path)
include $(PSPSDK)/lib/build.mak
|
| Code: |
[nicky@localhost Desktop]$ make
psp-gcc -I. -I/usr/local/pspdev/psp/sdk/include -O2 -G0 -Wall -D_PSP_FW_VERSION=150 -L. -L/usr/local/pspdev/psp/sdk/lib -specs=/usr/local/pspdev/psp/sdk/lib/prxspecs -Wl,-q,-T/usr/local/pspdev/psp/sdk/lib/linkfile.prx exflite.o /usr/local/pspdev/psp/sdk/lib/prxexports.o -lflite -lm -lpspaudio -lpspaudiolib -lpspdebug -lpspdisplay -lpspge -lpspctrl -lpspsdk -lc -lpspnet -lpspnet_inet -lpspnet_apctl -lpspnet_resolver -lpsputility -lpspuser -lpspkernel -o exflite.elf
/usr/local/pspdev/lib/gcc/psp/4.3.2/../../../../psp/lib/libflite.a(audio.o): In function `audio_flush':
audio.c:(.text+0x18): undefined reference to `audio_flush_none'
/usr/local/pspdev/lib/gcc/psp/4.3.2/../../../../psp/lib/libflite.a(audio.o): In function `audio_drain':
audio.c:(.text+0x20): undefined reference to `audio_drain_none'
/usr/local/pspdev/lib/gcc/psp/4.3.2/../../../../psp/lib/libflite.a(audio.o): In function `audio_write':
audio.c:(.text+0x3ec): undefined reference to `audio_write_none'
/usr/local/pspdev/lib/gcc/psp/4.3.2/../../../../psp/lib/libflite.a(audio.o): In function `audio_close':
audio.c:(.text+0x4d8): undefined reference to `audio_close_none'
/usr/local/pspdev/lib/gcc/psp/4.3.2/../../../../psp/lib/libflite.a(audio.o): In function `audio_open':
audio.c:(.text+0x4f8): undefined reference to `audio_open_none'
/usr/local/pspdev/lib/gcc/psp/4.3.2/../../../../psp/lib/libflite.a(audio.o): In function `play_wave_sync':
audio.c:(.text+0x6e8): undefined reference to `audio_flush_none'
collect2: ld returned 1 exit status
make: *** [exflite.elf] Error 1
|
thanks for any help :~) |
|
| Back to top |
|
 |
mypspdev
Joined: 11 Jul 2007 Posts: 178
|
Posted: Sat Oct 17, 2009 11:15 pm Post subject: |
|
|
It works in my environment.... I've to check, as well as we share sorces by MP may be best way to communicate is via MP....
Did you recompiled libflite?
1st step: let try using the libflite I send into the package
2st step: let try to recompile libflite using makefile and evironment I sent
....
Last edited by mypspdev on Sun Oct 18, 2009 4:02 am; edited 1 time in total |
|
| Back to top |
|
 |
whistler
Joined: 04 Mar 2008 Posts: 40
|
Posted: Sun Oct 18, 2009 3:27 am Post subject: |
|
|
a cursory grep of the source makes me believe all those audio_xxxxx_none should have resolved to audio_xxxx_psp
though i'm probably wrong:) |
|
| Back to top |
|
 |
mypspdev
Joined: 11 Jul 2007 Posts: 178
|
Posted: Sun Oct 18, 2009 4:04 am Post subject: |
|
|
| whistler wrote: | a cursory grep of the source makes me believe all those audio_xxxxx_none should have resolved to audio_xxxx_psp
though i'm probably wrong:) |
Of course to compile libflite.a you should use the makefile as it is and
/src/audio/psp/au_psp.c
do not use
/src/audio/au_none.c
ok? |
|
| Back to top |
|
 |
whistler
Joined: 04 Mar 2008 Posts: 40
|
Posted: Sun Oct 18, 2009 7:53 am Post subject: |
|
|
| Code: | TARGET_LIB = libflite.a
OBJS = ./src/audio/au_command.o \
./src/audio/audio.o \
./src/audio/psp/au_psp.o \
./src/hrg/cst_ffeature.o \
./src/hrg/cst_item.o \
./src/hrg/cst_rel_io.o \
./src/hrg/cst_relation.o \
./src/hrg/cst_utterance.o \
./src/lexicon/cst_lexicon.o \
./src/lexicon/cst_lts.o \
./src/lexicon/cst_lts_rewrites.o \
./src/regex/cst_regex.o \
./src/regex/regexp.o \
./src/regex/regsub.o \
./src/speech/cst_wave.o \
./src/speech/cst_wave_io.o \
./src/speech/cst_track.o \
./src/speech/cst_track_io.o \
./src/speech/cst_lpcres.o \
./src/speech/cst_wave_utils.o \
./src/speech/rateconv.o \
./src/stats/cst_cart.o \
./src/stats/cst_ss.o \
./src/stats/cst_viterbi.o \
./src/synth/cst_phoneset.o \
./src/synth/cst_synth.o \
./src/synth/cst_utt_utils.o \
./src/synth/cst_voice.o \
./src/synth/flite.o \
./src/utils/cst_alloc.o \
./src/utils/cst_args.o \
./src/utils/cst_endian.o \
./src/utils/cst_error.o \
./src/utils/cst_features.o \
./src/utils/psp/cst_file_psp.o \
./src/utils/cst_socket.o \
./src/utils/cst_string.o \
./src/utils/cst_tokenstream.o \
./src/utils/cst_val.o \
./src/utils/cst_val_const.o \
./src/utils/cst_val_user.o \
./src/utils/cst_mmap_none.o \
./src/wavesynth/cst_clunits.o \
./src/wavesynth/cst_diphone.o \
./src/wavesynth/cst_reflpc.o \
./src/wavesynth/cst_sigpr.o \
./src/wavesynth/cst_sigprFP.o \
./src/wavesynth/cst_sts.o \
./src/wavesynth/cst_units.o \
./lang/cmulex/cmu_lex.o \
./lang/cmulex/cmu_lex_data.o \
./lang/cmulex/cmu_lts_model.o \
./lang/cmulex/cmu_lex_entries.o \
./lang/cmulex/cmu_lts_rules.o \
./lang/cmu_time_awb/cmu_time_awb.o \
./lang/cmu_time_awb/cmu_time_awb_cart.o \
./lang/cmu_time_awb/cmu_time_awb_clunits.o \
./lang/cmu_time_awb/cmu_time_awb_lex_entry.o \
./lang/cmu_time_awb/cmu_time_awb_lpc.o \
./lang/cmu_time_awb/cmu_time_awb_mcep.o \
./lang/usenglish/us_aswd.o \
./lang/usenglish/us_dur_stats.o \
./lang/usenglish/us_durz_cart.o \
./lang/usenglish/us_expand.o \
./lang/usenglish/us_f0_model.o \
./lang/usenglish/us_f0lr.o \
./lang/usenglish/us_ffeatures.o \
./lang/usenglish/us_gpos.o \
./lang/usenglish/us_int_accent_cart.o \
./lang/usenglish/us_int_tone_cart.o \
./lang/usenglish/us_nums_cart.o \
./lang/usenglish/us_phoneset.o \
./lang/usenglish/us_phrasing_cart.o \
./lang/usenglish/us_postlex.o \
./lang/usenglish/us_text.o \
./lang/usenglish/usenglish.o \
./lang/cmu_us_kal/cmu_us_kal.o \
./lang/cmu_us_kal/cmu_us_kal_diphone.o \
./lang/cmu_us_kal/cmu_us_kal_lpc.o \
./lang/cmu_us_kal/cmu_us_kal_res.o \
./lang/cmu_us_kal/cmu_us_kal_residx.o \
./lang/cmu_us_kal16/cmu_us_kal16.o \
./lang/cmu_us_kal16/cmu_us_kal16_diphone.o \
./lang/cmu_us_kal16/cmu_us_kal16_lpc.o \
./lang/cmu_us_kal16/cmu_us_kal16_res.o \
./lang/cmu_us_kal16/cmu_us_kal16_residx.o
INCDIR = ./inc
CFLAGS = -O2 -G0 -Wall
CXXFLAGS = $(CFLAGS) -DCST_AUDIO_PSP -fno-exceptions -fno-rtti
ASFLAGS = $(CFLAGS)
LIBDIR =
LDFLAGS =
PSPSDK=$(shell psp-config --pspsdk-path)
include $(PSPSDK)/lib/build.mak |
Obviously i've not changed the makefile in any way. Thats my point whats causing it to use the audio_XXXX_none functions. i can see that CST_AUDIO_PSP has been defined in the makefile so the functions should be resolved to audio_xxxxx_psp.
btw i''ve tried compiling it myself and i've tried using the libflite.a and includes that you've sent.
At this point i could do with a small example and makefile that is known to compile coz i can't see any problems with the simple example i posted. Could you test the example code and makefile that i posted (its a few posts up) and see if it compiles and runs on your machine?
Thanks for persevering with this:) |
|
| Back to top |
|
 |
mypspdev
Joined: 11 Jul 2007 Posts: 178
|
Posted: Sun Oct 18, 2009 9:06 pm Post subject: |
|
|
Have a look at
/src/audio/native_audio.h, the right version
and let delete /inc/native_audio.h the original version.
The right initialization of the Audio Platform is the following:
#define AUDIO_OPEN_NATIVE audio_open_psp
#define AUDIO_CLOSE_NATIVE audio_close_psp
#define AUDIO_SET_SAMPLE_RATE_NATIVE audio_set_sample_rate_none
#define AUDIO_WRITE_NATIVE audio_write_psp
#define AUDIO_DRAIN_NATIVE audio_drain_psp
#define AUDIO_FLUSH_NATIVE audio_flush_psp
having added and prepared
au_psp.c with those functions.
Within the package I collected all needed Headers into /inc, including the original native_audio.h which is wrong.
Be sure only one native_audio.h with the right psp #define is used.
Best way is to rearrange to be included Headers, may be you can prepare final package of psp_flite.
Let use also pspAudioInit();
bye bye |
|
| Back to top |
|
 |
|