Commit Graph

30 Commits

Author SHA1 Message Date
Jakub Jelen 910020aeec Ignore non-useful check in clang-tidy as we have ton of memset/memcpy 2021-01-06 14:15:06 +01:00
Frank Morgner 94388f9538 fixed more clang-tidy warnings 2019-06-05 13:48:51 +02:00
Frank Morgner 28958af559 added compatibility function for VC14 2016-10-07 14:17:40 +02:00
Frank Morgner 89f9d9e85d add compatibility implementation for strnlen
fixes https://github.com/OpenSC/OpenSC/issues/660
2016-01-20 10:47:27 +01:00
Frank Morgner 622b71970f add compat_report_rangecheckfailure.c to libcompat 2015-11-01 21:02:34 +01:00
Ludovic Rousseau ea40e7fe24 Use AM_CPPFLAGS instead of INCLUDES
Fix autoreconf warnings:

$ autoreconf -vis -Wall
[...]
src/common/Makefile.am:12: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS')
src/libopensc/Makefile.am:19: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS')
src/minidriver/Makefile.am:15: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS')
src/pkcs11/Makefile.am:10: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS')
src/pkcs15init/Makefile.am:36: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS')
src/scconf/Makefile.am:12: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS')
src/sm/Makefile.am:8: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS')
src/tests/Makefile.am:9: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS')
src/tools/Makefile.am:15: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS')
2012-09-25 23:03:38 +02:00
Alon Bar-Lev df8715849d Remove libltdl: Remove ltld references
http://www.opensc-project.org/pipermail/opensc-devel/2011-December/017490.html
cherry-picked from 'libtool' branch of Alon Barlev's github project git://github.com/alonbl/OpenSC.git
and rebased

Remove libltdl: Remove ltld references
(cherry picked from commit a350326c520c5b0cb185f90946648633f4d0e456)

Remove libltdl: Detect libdl
(cherry picked from commit 51e7de45c11823460e776492dcbd40e60583a7eb)

Remove libltdl: Use libscdl
(cherry picked from commit 09f3eadb8a1a47407c011dcd3d5ce461516f3b87)

Remove libltdl: Cleanup libscdl
(cherry picked from commit 52d5f1be01146079e3a6fad1c88ebb0f577d0a94)

Remove libltdl: Cleanup libscdl usage at Microsoft VC build

Untested, I don't have the environment, Martin, please test.
(cherry picked from commit 7fb18f8d0b0bae6d181981a0c71190440e917c2c)

Change-Id: I73c98ccb9365584b12f4b0b97b69316a190b6e45
2012-03-17 20:55:05 +01:00
martin 8f4dfe2c85 Amend r5201: put libscdl.h/libpkcs11.h to distribution package and link against libltdl where needed.
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5210 c6295689-39f2-0310-b995-f0e70906c6a9
2011-02-17 20:46:13 +00:00
martin 2ea78bf741 Amend r5201: also move libltdl build properties to the right Makefile and other leftovers.
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5203 c6295689-39f2-0310-b995-f0e70906c6a9
2011-02-17 07:45:36 +00:00
dengert c6eb3a3085 Allow use of seperate build and source dir when building
common/libpkcs11            


git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5202 c6295689-39f2-0310-b995-f0e70906c6a9
2011-02-16 21:05:52 +00:00
martin ffb46d2573 core: reanimate the sc_dlopen API for dynamic loading
* shift libpkcs11 from src/pkcs11 to src/common as it is not used to implement the OpenSC PKCS#11 module
 * invent a "libscdl" mini library that implements either libltdl based dynamic loading or uses native interfaces
 * drop hard requirement for libltl to build OpenSC
 * native Windows build does not need libltdl any more
 * specify CNGSDK include dir to find cardmod.h. CNGSDK only registers with a handful of compilers

Deals with #323

git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@5201 c6295689-39f2-0310-b995-f0e70906c6a9
2011-02-16 19:02:11 +00:00
martin 471e43c7cb simclist: build with mingw32, Visual Studio and gcc on Linux. By default dumprestore is OFF.
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@4905 c6295689-39f2-0310-b995-f0e70906c6a9
2010-12-02 08:59:26 +00:00
martin ab6511cb63 Trac #264: fix mingw32 build with mingw32-runtime versions <= 3.13
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@4871 c6295689-39f2-0310-b995-f0e70906c6a9
2010-11-08 11:17:09 +00:00
ludovic.rousseau 43ee9f60ce build but do not install compat_getopt_main
This is just used for testing the compat_getopt code in libcompat


git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@4739 c6295689-39f2-0310-b995-f0e70906c6a9
2010-09-21 09:37:17 +00:00
ep b279287701 strlcat(3) implementation
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@4634 c6295689-39f2-0310-b995-f0e70906c6a9
2010-08-18 13:42:26 +00:00
aj d22a2483c0 Header file cleanup.
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@4081 c6295689-39f2-0310-b995-f0e70906c6a9
2010-03-04 08:14:36 +00:00
martin ff4c2c6aa2 Include simclist.h to opensc includes to be able to build OpenSC.tokend
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@3978 c6295689-39f2-0310-b995-f0e70906c6a9
2010-02-02 12:53:44 +00:00
martin 101df10ae5 Add simclist, also used by pcsc-lite, for list operations.
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@3929 c6295689-39f2-0310-b995-f0e70906c6a9
2010-01-24 15:05:14 +00:00
alonbl a160f0ebf7 common/main.c is part of getopt package
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@3476 c6295689-39f2-0310-b995-f0e70906c6a9
2008-04-16 04:42:31 +00:00
alonbl 87db3c96c2 More separate srcdir fixups
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@3450 c6295689-39f2-0310-b995-f0e70906c6a9
2008-04-01 19:04:33 +00:00
alonbl 8ac87f1b1e Remove useless comments
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@3414 c6295689-39f2-0310-b995-f0e70906c6a9
2008-03-09 21:24:24 +00:00
alonbl 0a809dd5cb Complete rewrite of OpenSC build system.
1.  Build system now supports MinGW (Windows) compilation using msys and cross compilation.
2.  Ability to explicitly disable and enable dependencies of the package.
3.  openct, pcsc and nsplugins features are disabled by default.
4.  Modified pcsc driver to use pcsc dynamically, no compile time dependency is required.
5.  --enable-pcsc-lite configuration option renamed to --enable-pcsc.
6.  Install opensc.conf file (as opensc.conf.new if opensc.conf exists).
7.  Add--enable-doc configuration option, allow installing documentation into target.
8.  Add --disable-man configuration option, allow msys mingw32 users to
    build from svn without extra dependencies.
9.  Add export files to each library in order to export only required symbols.
    Windows native build may use these files instead of scanning objects' symbols.
10. Add opensc-tool --info to display some general information about the build.
11. Create compatibility library to be linked against library instread of recompiling the
    same source files in different places.
12. Add different win32 version resource to each class of outputs.
13. Make xsl-stylesheets location selectable.
14. Some win32 fixups.
15. Some warning fixups.
16. Many other autoconf/automake cleanups.

Alon Bar-Lev

svn diff -r 3315:3399 https://www.opensc-project.org/svn/opensc/branches/alonbl/mingw

_M   .
D    configure.in
_M   src
_M   src/openssh
M    src/openssh/Makefile.am
_M   src/tools
M    src/tools/rutoken-tool.c
M    src/tools/opensc-tool.c
M    src/tools/cardos-info.c
M    src/tools/pkcs15-crypt.c
M    src/tools/pkcs15-init.c
M    src/tools/piv-tool.c
M    src/tools/netkey-tool.c
M    src/tools/eidenv.c
M    src/tools/cryptoflex-tool.c
M    src/tools/util.c
M    src/tools/pkcs11-tool.c
M    src/tools/pkcs15-tool.c
M    src/tools/util.h
M    src/tools/opensc-explorer.c
M    src/tools/Makefile.am
_M   src/pkcs11
M    src/pkcs11/pkcs11-global.c
M    src/pkcs11/framework-pkcs15.c
M    src/pkcs11/mechanism.c
M    src/pkcs11/pkcs11-display.c
M    src/pkcs11/pkcs11-object.c
A    src/pkcs11/opensc-pkcs11.exports
M    src/pkcs11/sc-pkcs11.h
M    src/pkcs11/pkcs11-spy.c
M    src/pkcs11/openssl.c
M    src/pkcs11/Makefile.am
A    src/pkcs11/pkcs11-spy.exports
_M   src/tests
_M   src/tests/regression
M    src/tests/regression/Makefile.am
M    src/tests/sc-test.c
M    src/tests/pintest.c
M    src/tests/Makefile.am
_M   src/include
_M   src/include/opensc
M    src/include/opensc/Makefile.am
A    src/include/opensc/svnignore
M    src/include/Makefile.am
_M   src/signer
_M   src/signer/npinclude
M    src/signer/npinclude/Makefile.am
M    src/signer/Makefile.am
A    src/signer/signer.exports
_M   src/common
A    src/common/compat_dummy.c
D    src/common/getopt.txt
D    src/common/strlcpy.c
D    src/common/LICENSE
A    src/common/compat_getopt.txt
A    src/common/compat_strlcpy.c
A    src/common/LICENSE.compat_getopt
A    src/common/compat_getopt.c
D    src/common/strlcpy.h
D    src/common/ChangeLog
D    src/common/getpass.c
D    src/common/my_getopt.c
A    src/common/compat_strlcpy.h
A    src/common/compat_getpass.c
A    src/common/compat_getopt.h
A    src/common/ChangeLog.compat_getopt
D    src/common/README.strlcpy
D    src/common/my_getopt.h
A    src/common/compat_getpass.h
A    src/common/README.compat_strlcpy
D    src/common/strlcpy.3
A    src/common/README.compat_getopt
D    src/common/getopt.3
D    src/common/README.my_getopt
A    src/common/compat_strlcpy.3
A    src/common/compat_getopt.3
M    src/common/Makefile.am
M    src/Makefile.am
_M   src/pkcs15init
M    src/pkcs15init/pkcs15-oberthur.c
M    src/pkcs15init/profile.c
M    src/pkcs15init/pkcs15-lib.c
M    src/pkcs15init/pkcs15-rutoken.c
A    src/pkcs15init/pkcs15init.exports
M    src/pkcs15init/pkcs15-gpk.c
M    src/pkcs15init/Makefile.am
_M   src/scconf
M    src/scconf/Makefile.am
M    src/scconf/parse.c
A    src/scconf/scconf.exports
_M   src/libopensc
M    src/libopensc/card-rutoken.c
M    src/libopensc/compression.c
M    src/libopensc/sc.c
M    src/libopensc/card-piv.c
M    src/libopensc/pkcs15-openpgp.c
M    src/libopensc/pkcs15-postecert.c
M    src/libopensc/pkcs15-tcos.c
M    src/libopensc/opensc-config.in
M    src/libopensc/reader-pcsc.c
A    src/libopensc/internal-winscard.h
M    src/libopensc/ctx.c
A    src/libopensc/libopensc.exports
M    src/libopensc/pkcs15-piv.c
M    src/libopensc/pkcs15-infocamere.c
M    src/libopensc/internal.h
M    src/libopensc/pkcs15-actalis.c
M    src/libopensc/pkcs15-starcert.c
M    src/libopensc/card-oberthur.c
M    src/libopensc/pkcs15-atrust-acos.c
M    src/libopensc/p15card-helper.c
D    src/libopensc/part10.h
M    src/libopensc/ui.c
M    src/libopensc/card-gpk.c
M    src/libopensc/pkcs15-wrap.c
M    src/libopensc/pkcs15-gemsafeGPK.c
M    src/libopensc/log.c
M    src/libopensc/pkcs15-esteid.c
M    src/libopensc/pkcs15-prkey-rutoken.c
M    src/libopensc/log.h
M    src/libopensc/Makefile.am
M    src/libopensc/reader-openct.c
_M   aclocal
M    aclocal/Makefile.am
_M   win32
M    win32/Makefile.am
A    win32/versioninfo.rc.in
A    win32/ltrc.inc
A    configure.ac
_M   doc
_M   doc/tools
M    doc/tools/pkcs15-profile.xml
D    doc/changelog.sh
D    doc/export-wiki.xsl
_M   doc/api
_M   doc/api/file
M    doc/api/man.xsl
_M   doc/api/asn1
_M   doc/api/apps
_M   doc/api/init
_M   doc/api/types
_M   doc/api/card
M    doc/api/html.xsl
_M   doc/api/misc
_M   doc/api/util
M    doc/Makefile.am
D    doc/export-wiki.sh
AM   doc/nonpersistent
A    doc/nonpersistent/export-wiki.xsl
A    doc/nonpersistent/Makefile.am
A    doc/nonpersistent/export-wiki.sh
A    doc/nonpersistent/svn2cl.xsl
D    doc/generate-man.sh
D    doc/svn2cl.xsl
M    Makefile.am
A    svnignore
_M   etc
M    etc/opensc.conf.in
M    etc/Makefile.am
D    man
_M   solaris
M    solaris/Makefile



git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@3405 c6295689-39f2-0310-b995-f0e70906c6a9
2008-03-06 16:06:59 +00:00
ludovic.rousseau 9ce3d4c663 add strlcpy.{c,h} from
ftp://ftp.openbsd.org/pub/OpenBSD/src/lib/libc/string/


git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@2990 c6295689-39f2-0310-b995-f0e70906c6a9
2006-07-12 08:05:54 +00:00
ludovic.rousseau 2495268d98 - remove src/common/getopt.h since it collide with /usr/include/getopt.h
- replace @GETOPTSRC@ by $(top_srcdir)/src/common/my_getopt.c in
  Makefile.am files

- change the detection of getopt_long in configure.in since GETOPTSRC is
  not used anymore. my_getopt.c is now always compiled and used but
  provides getopt_long() only if HAVE_GETOPT_H is NOT defined (ie. if
  getopt_long() is not provided by the system)

- src/common/my_getopt.c: the code is within #ifndef HAVE_GETOPT_H

- move the useful lines of src/common/getopt.h in src/common/my_getopt.h


git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@2989 c6295689-39f2-0310-b995-f0e70906c6a9
2006-07-12 07:43:38 +00:00
ludovic.rousseau 1eb33bc946 rename README in README.my_getopt
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@2988 c6295689-39f2-0310-b995-f0e70906c6a9
2006-07-12 07:32:40 +00:00
aj 40ad6b0037 replace GNU/glibc getopt (LGPL) with my_getopt (BSD).
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@2630 c6295689-39f2-0310-b995-f0e70906c6a9
2005-10-05 15:23:51 +00:00
aj 7bf15d3d7d replace gpl'ed and old version with new lgpl'ed version from glibc.
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@2622 c6295689-39f2-0310-b995-f0e70906c6a9
2005-09-23 15:47:44 +00:00
fabled 7635468ed9 - Initial support for win32
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@654 c6295689-39f2-0310-b995-f0e70906c6a9
2002-06-14 12:52:56 +00:00
aet 5a824f3fab Add maintainer-clean patch by Andreas Jellinghaus <aj@dungeon.inka.de>
git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@411 c6295689-39f2-0310-b995-f0e70906c6a9
2002-04-02 09:38:06 +00:00
aet 9bd6c8f9bb Add getopt/getopt_long sources from GNU C Library.
Use them only if platform lacks support for getopt_long,
like most commercial operating systems do.


git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@129 c6295689-39f2-0310-b995-f0e70906c6a9
2002-01-02 22:15:31 +00:00