For Embedded System
This chapter will introduce how to build the CCID and PC/SC into embedded system, to develop the app please check the developer -> Linux:
Build with toolchain
mkdir /usr/ccid
build libusb
./configure --build=i686-linux --host=arm-fsl-linux CC=/opt/freescale/usr/local/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/fsl-linaro-toolchain/bin/arm-fsl-linux-gnueabi-gcc --prefix=/usr/ccid/install --disable-udev --enable-static
build pcsc
apt-get install git
git clone https://github.com/LudovicRousseau/PCSC
aclocal
./bootstrap
./configure CC=/opt/freescale/usr/local/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/fsl-linaro-toolchain/bin/arm-fsl-linux-gnueabi-gcc --host=arm-fsl-linux prefix=/usr/ccid --enable-libusb LIBUSB_LIBS="-L/usr/ccid/install/lib -lusb-1.0" LIBUSB_CFLAGS="-I/usr/ccid/install/include/libusb-1.0" PCSC_CFLAGS="-I/usr/ccid/include/PCSC" PCSC_LIBS="-L/usr/ccid/lib/ -lpcsclite" --enable-usbdropdir="/usr/ccid/lib/pcsc/drivers" --enable-static --disable-libudev --disable-libsystemd
build ccid
git clone https://github.com/LudovicRousseau/CCID
aclocal
./bootstrap
./configure CC=/opt/freescale/usr/local/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/fsl-linaro-toolchain/bin/arm-fsl-linux-gnueabi-gcc --host=arm-fsl-linux prefix=/usr/ccid --disable-udev --enable-libusb LIBUSB_LIBS="-L/usr/ccid/install/lib -lusb-1.0" LIBUSB_CFLAGS="-I/usr/ccid/install/include/libusb-1.0" PCSC_CFLAGS="-I/usr/ccid/include/PCSC" PCSC_LIBS="-L/usr/ccid/lib/ -lpcsclite" --enable-usbdropdir="/usr/ccid/lib/pcsc/drivers"
Try build under A33 platform:
mkdir -p /usr/ccid
build libusb
git clone libusb-latest-version
aclocal
./bootstrap.sh
./configure --build=i686-linux --host=arm-none-linux CC=/opt/arm-2014.05/bin/arm-none-linux-gnueabi-gcc --prefix=/usr/ccid --disable-udev --enable-static
make
make install
#The lib and header file will saved at install folder
#download latest pcsc
git clone https://github.com/LudovicRousseau/PCSC
aclocal
./bootstrap
./configure CC=/opt/arm-2014.05/bin/arm-none-linux-gnueabi-gcc --host=arm-none-linux --prefix=/usr/ccid --enable-libusb LIBUSB_LIBS="-L/usr/ccid/lib/ -lusb-1.0" LIBUSB_CFLAGS="-I/usr/ccid/include/libusb-1.0" PCSC_CFLAGS="-I/usr/ccid/include/PCSC" PCSC_LIBS="-L/usr/ccid/lib/ -lpcsclite" --enable-usbdropdir="/usr/ccid/lib/pcsc/drivers" --enable-static --disable-libudev --disable-libsystemd
#if found error of pcsc-wirecheck-gen, this is cross compiled for ARM but is executed on the x86 system, comments this line pcsc-wirecheck-main.c +12
make
make install
build ccid
download latest ccid
aclocal #if give error of m4, then cp PCSC source code folder and do replacement PCSC in CCID folder
./bootstrap
./configure CC=/opt/arm-2014.05/bin/arm-none-linux-gnueabi-gcc --host=arm-none-linux --prefix=/usr/ccid --prefix=/usr/ccid --enable-libusb LIBUSB_LIBS="-L/usr/ccid/lib/ -lusb-1.0 -lrt" LIBUSB_CFLAGS="-I/usr/ccid/include/libusb-1.0" PCSC_CFLAGS="-I/usr/ccid/include/PCSC" PCSC_LIBS="-L/usr/ccid/lib/ -lpcsclite" --enable-usbdropdir="/usr/ccid/lib/pcsc/drivers"
make # if got error libPCSCv2part10, then create below folder and find PCSCv2part10.c and PCSCv2part10.h source code from internet, copy to contrib_libPCSCv2part10/libPCSCv2part10/
mkdir -p contrib_libPCSCv2part10/libPCSCv2part10/
make install
go to /usr/ccid
tar cvf ccid.tar.gz *
copy ccid.tar.gz to ramdisk, unzip to folder /usr/ccid
Contents