File: INSTALL

package info (click to toggle)
ccid 1.3.11-2
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 2,716 kB
  • ctags: 897
  • sloc: sh: 10,390; ansic: 6,869; makefile: 318; lex: 160; perl: 113
file content (160 lines) | stat: -rw-r--r-- 4,993 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
INSTALLATION PROCEDURE
======================

Installation from source:
"""""""""""""""""""""""""

get the ccid-x.y.z.tar.gz archive and do:

$ tar xzvf ccid-x.y.z.tar.gz
$ cd ccid-x.y.z
$ ./configure
$ make
$ sudo make install

By default pcscd and my ccid driver use /usr/local/pcsc/drivers/ as
directory for hotplug drivers. The ./configure script try to get the
directory used by pcscd using 'pkg-config libpcsclite --variable=usbdropdir'
So you should not have to use the --enable-usbdropdir=DIR argument.


udev use
~~~~~~~~

It is possible to configure the driver to use udev events so that pcscd
will not poll the USB bus every second. Use:

$ ./configure --enable-udev
$ make

You will then have to install the udev rules file in the correct
directory. It could be something like:

$ sudo cp src/pcscd_ccid.rules /etc/udev/rules.d/


On FreeBSD you can also use --enable-udev and add the following rules to
devd.conf (thanks to Tilman Linneweh for the info)

attach 100 {
	device-name "ugen[0-9]+";
	action "/usr/sbin/pcscd -H";
};

detach 100 {
	device-name "ugen[0-9]+";
	action "/usr/sbin/pcscd -H";
};


libusb not found
~~~~~~~~~~~~~~~~

If the ./configure script says something like:
  configure: error: usb.h not found, use --enable-libusb=PATH
You should use --enable-libusb=PATH to tell ./configure where to find
the usb.h and libusb.so files. The ./configure script will use
PATH/include/ to search for usb.h and PATH/lib/ to search for libusb.so


building serial reader driver
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

A serial CCID reader can also be connected on a serial port. By default
the serial driver is not built. You must explicitely do:

$ ./configure --enable-twinserial
$ make
# make install


builing serial reader driver only
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

It is possible to generate the driver for the GemPC Twin using serial
communication only (for example on an embedded system without USB).
Just do:
$ ./configure --enable-twinserial --disable-libusb
$ make
# make install

By default ./configure try to get the directory used by pcscd using
'pkg-config libpcsclite --variable=usbdropdir' and add '/serial'.
You should not have to use --enable-ccidtwindir=DIR to specify the
target directory to use. 


configuring the driver for the serial reader
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

You have to create or edit the file /etc/reader.conf. The file should
contain something like:

# Gemplus reader with serial communication
#  - reader is the reader name. It is needed for multi-slot readers.
#    Possible reader values are: GemPCPinPad, GemCorePOSPro, GemCoreSIMPro,
#    GemPCTwin (default value)
# example: /dev/ttyS0:GemPCPinPad
#FRIENDLYNAME      "GemPCTwin serial"
#DEVICENAME        /dev/ttySn[:reader]
#LIBPATH           TARGET
#CHANNELID         1

FRIENDLYNAME      "GemPC Twin serial"
DEVICENAME        /dev/ttyS0
LIBPATH           /usr/local/pcsc/drivers/serial/libccidtwin.so.1.2.3
CHANNELID         1

You will have to adapt the library path to your configuration and library
version.

By default the GemPC Twin serial reader parameters are loaded by the
driver, if you use a GemPC PinPad, a GemCore POS Pro or a GemCore SIM
Pro you have to indicate it in the DEVICENAME field. You will then have
something like:
DEVICENAME        /dev/ttyS0:GemPCPinPad

/dev/ttyS0 (DEVICENAME field) is the first serial port under Linux
(known as COM1 under DOS/Windows). Of course if your reader is connected
to another serial port you have to adapt that.


Binary installation:
""""""""""""""""""""

Contact your distribution support.


Test procedure:
"""""""""""""""

- check the reader is supported by the driver.
  Get your reader USB identification using the lsusb(1) command:
  $ lsusb
  [...]
  Bus 001 Device 048: ID 08e6:4433 Gemplus

  Look for 08E6 (ifdVendorID) and 4433 (ifdProductID) in
  /usr/local/pcsc/drivers/ifd-ccid.bundle/Contents/Info.plist
  Of course your numbers will be different.

  If you can't find them add them (if you know what you do) and/or mail me.

- (re)start pcscd with debug on stdout. Simply do 'pcscd --debug stdout'
  (you will need to have root priviledges). And look for:
  [...]
  readerfactory.c:1319 RFInitializeReader: Attempting startup of ReaderName
  readerfactory.c:1061 RFBindFunctions: Loading IFD Handler 2.0
  ifdhandler.c:76 Entering IFDHCreateChannel (lun: 0)
  ccid_usb.c:131 Manufacturer: Ludovic Rousseau (ludovic.rousseau@free.fr)
  ccid_usb.c:139 ProductString: Generic CCID reader v0.1.0
  ccid_usb.c:143 Copyright: This driver is protected by terms of the GNU General Public License version 2, or (at your option) any later version.
  ccid_usb.c:223 Found Vendor/Product: 08E6/4433 (GemPC433 SL)
  ccid_usb.c:224 Using USB bus/device: 001/047

  If you don't see this the driver is not installed correctly or your
  reader is not yet supported. Read
  http://pcsclite.alioth.debian.org/ccid.html#CCID_compliant to know
  what to do.

$Id: INSTALL 3001 2008-06-14 16:15:11Z rousseau $