Compile madplay on the pc end of the X86 machine (use gcc directly and use arm-linux-gcc to run on the Development Board) mkdirmadplay unzip the file to madplay first install zlib-1.1.4mkdirtargetlibid3tag to use the library generated by zlib cdsrc/zlib-1.1.4. /configure-prefix = target: CC = arm-
Compile madplay on the pc end of the X86 machine (use gcc directly and use arm-linux-gcc to run on the Development Board)
Mkdir madplay
Decompress the file to madplay.
Install zlib-1.1.4 first
Mkdir target
Libid3tag must use the library generated by zlib
Cd src/zlib-1.1.4
./Configure-prefix = target
Skip CC = arm-linux-gcc in Makefile. //
Make & make install
Cd./libid3tag-0.15.1b
. /Configure-host = arm-linux-prefix =/1234/target/CC = arm-linux-gcc. Do not write PPFLAG =-I/1234/target/include DFLAG =- l/1234/target/lib
Make & make install
Cd./libmad-0.15.1b
./Configure -- host = arm-linux-prefix =/1234/target/CC = arm-linux-gcc //
Make & make install
Cd./madplay-0.15.2b
. /Configure -- host = arm-linux-prefix =/1234/target/CC = arm-linux-gcc CPPFLAGS =-I/1234/target/include LDFLAGS =-L/1234/ target/lib
Make & ake install
There is a one-step compilation error in the middle, prompting the makefile about "-- ff * pm-m". I don't remember it. In this case, use Vim to open the Makefile and find it, delete it and run it again.
Succeeded, but it cannot run in the pc-side virtual machine. The/dev/dsp is missing.
If the Pc is successful, will the arm Board be far behind?
Next:
Mkdir target-arm
Steps are similar to those above ,,,,,
Add the bold italic text above to each command
Note that the above PATH says "1234", which I intentionally wrote here to remind you that it is best to use absolute paths here.
After correctly compiled into the arm-linux version:
Copy target-arm/bin/madplay TO THE DEVELOPMENT BOARD
Copy libmad. so.0 and libid3tag. so.0 to the development board/lib.
The two libraries required by madplay are under target-arm/lib. They are linked files, so they copy the linked files. You should copy the following four library files:
Libid3tag. so.0, libid3tag. so.0.3.0, libmad. so.0, and libmad. so.0.2.1 are stored in the/usr/lib directory.
For the reason, see: