====== Renaming library to ndn-cxx ======

Dependent applications should perform the following changes:

* all includes should be changed from <ndn-cpp-dev/...> to <ndn-cxx/...>
* documentation files/comments referring to ndn-cpp-dev should be
  updated and refer to ndn-cxx
* if the app uses pkgconfig for dependency detection, 'libndn-cpp-dev'
  should be replaced with 'libndn-cxx'.  Example for waf users:

    conf.check_cfg(package = 'libndn-cxx', args = ['--cflags', '--libs'],
                   uselib_store = 'NDN_CXX', mandatory = True)

Change-Id: I92d9ec7ff176b9fe8b4352bf04bbb32aa810422d
Refs: #1491
This commit is contained in:
Alexander Afanasyev committed 2014-04-24 22:49:51 -07:00
1 parent 5e96e00d24
commit 766cea7931
27 files changed
+126 -142

No files matched your search

+2
View File
@@ -5,6 +5,8 @@ from waflib import Logs, Configure
def options(opt): def options(opt):
opt.add_option('--debug', '--with-debug', action='store_true', default=False, dest='debug', opt.add_option('--debug', '--with-debug', action='store_true', default=False, dest='debug',
help='''Compile in debugging mode without all optimizations (-O0)''') help='''Compile in debugging mode without all optimizations (-O0)''')
opt.add_option('--with-c++11', action='store_true', default=False, dest='use_cxx11',
help='''Use C++ 11 features if available in the compiler''')
def configure(conf): def configure(conf):
areCustomCxxflagsPresent = (len(conf.env.CXXFLAGS) > 0) areCustomCxxflagsPresent = (len(conf.env.CXXFLAGS) > 0)
+1 -1
View File
@@ -1,4 +1,4 @@
ndn-cpp-dev authors ndn-cxx authors
=================== ===================
## The primary authors are (and/or have been): ## The primary authors are (and/or have been):
-36
View File
@@ -1,36 +0,0 @@
Interim changes since NDN-CPP v0.2(2013-12-17)
Bug fixes
* http://redmine.named-data.net/issues/1056 Fix DTAG NDNProtocolDataUnit to encode as "NDN\202\000".
* http://redmine.named-data.net/issues/1064 Add ax_lib_sqlite3.m4, etc. to m4 directory so that autogen.sh works out of the box.
* http://redmine.named-data.net/issues/1077 Move the BasicIdentityStorage sqlite file to ~/.ndnx/ndnsec-identity.db .
NOTE: If you have an old file at ~/.ndn-identity/identity.db, please move it to ~/.ndnx/ndnsec-identity.db .
* http://redmine.named-data.net/issues/1088 Certificate name in KeyLocator should not include the version number.
* Fix bug in getForwardingEntryFlags: Need to check all flags, not the first flag using "else if".
Changes
* http://redmine.named-data.net/issues/1085 In Name::Component, added comparison operators.
* http://redmine.named-data.net/issues/1086 In Name::getPrefix, support a negative argument, e.g. getPrefix(-1).
* http://redmine.named-data.net/issues/1089 Renamed key.hpp to key-locator.hpp .
* MetaInfo: Added setFinalBlockID for Name::Component, remove unused setFinalBlockID which take uint8_t*, etc.
* Fix clang compiler warnings: Include headers, parentheses and cast explicitly.
* Moved class ExcludeEntry to inner class Exclude::Entry.
* In BinaryXmlDecoder, cache the result of peekDTag for a speedup when decoding optional elements.
* Moved validation-request.hpp to public API security/policy, and moved OnVerified and OnVerifyFailed in there.
Documentation
* Move instructions for running ./autogen.sh from configure.ac to the Development section of INSTALL.
* http://redmine.named-data.net/issues/1072: In Doxyfile, fix EXCLUDE for ndnboost to new location include/ndnboost .
NDN-CPP v0.2 (2013-11-08)
This release fully supports the Common Client Libraries API.
http://named-data.net/codebase/platform/documentation/ndn-ccl-api/
Changes to future versions will be detailed in this CHANGELOG.
NDN-CPP v0.1 (2013-08-09)
This is the initial release, with support for expressInterest for one interest at a time. A new release
coming soon will have a Pending Interest Table and support processing multiple simultaneous interest and
data packets.
+6
View File
@@ -0,0 +1,6 @@
ndn-cxx v0.1 (2014-04-39)
Initial release of the ndn-cxx library.
The current set of features include:
* <to be listed>
+12 -14
View File
@@ -1,10 +1,10 @@
ndn-cpp-dev: A dev version of Named Data Networking client library for C++ ndn-cxx: NDN C++ library with eXperimental eXtensions
=========================================================================== ===========================================================================
Supported platforms Supported platforms
------------------- -------------------
ndn-cpp-dev is tested on the following platforms: ndn-cxx uses continuous integration testing and has been tested on the following platforms:
* Ubuntu 12.04 (64 bit and 32 bit) * Ubuntu 12.04 (64 bit and 32 bit)
* Ubuntu 13.10 (64 bit and 32 bit) * Ubuntu 13.10 (64 bit and 32 bit)
@@ -15,9 +15,6 @@ ndn-cpp-dev is tested on the following platforms:
Prerequisites Prerequisites
------------- -------------
(These are prerequisites to build ndn-cpp-dev. To do development of ndn-cpp-dev code and update the build system,
see Development Prerequisites.)
### Required: ### Required:
* `python` >= 2.6 * `python` >= 2.6
@@ -52,7 +49,7 @@ Following are the detailed steps for each platform to install the prerequisites.
# For Ubuntu 13.10 # For Ubuntu 13.10
sudo apt-get install libboost-all-dev sudo apt-get install libboost-all-dev
### Optional Dependencies: ### Optional:
To build tutorials, manpages, and API documentation the following To build tutorials, manpages, and API documentation the following
dependencies need to be installed: dependencies need to be installed:
@@ -76,10 +73,10 @@ The following lists steps for common platforms to install these prerequisites:
Build Build
----- -----
(These are instructions to build ndn-cpp-dev. To do development of ndn-cpp-dev (These are instructions to build ndn-cxx. To do development of ndn-cxx
code and update the build system, see Development.) code and update the build system, see Development.)
To build in a terminal, change directory to the ndn-cpp-dev root. Enter: To build in a terminal, change directory to the ndn-cxx root. Enter:
./waf configure ./waf configure
./waf ./waf
@@ -87,11 +84,11 @@ To build in a terminal, change directory to the ndn-cpp-dev root. Enter:
This builds and installs the following items: This builds and installs the following items:
* `<LIBPATH>/libndn-cpp-dev.a`: static NDN C++ library * `<LIBPATH>/libndn-cxx.a`: static NDN C++ library
* `<LIBPATH>/pkgconfig/libndn-cpp-dev.pc`: pkgconfig file storing all neccessary flags * `<LIBPATH>/pkgconfig/libndn-cxx.pc`: pkgconfig file storing all neccessary flags
to build against the library. For example, if pkgconfig or pkgconf package is to build against the library. For example, if pkgconfig or pkgconf package is
installed and `PKG_CONFIG_PATH` is configured properly (or `<LIBPATH>/pkgconfig` is a installed and `PKG_CONFIG_PATH` is configured properly (or `<LIBPATH>/pkgconfig` is a
default path), `pkgconfig --libs --clflags libndn-cpp-dev` will return all necessary default path), `pkgconfig --libs --clflags libndn-cxx` will return all necessary
compile and link flags for the library. compile and link flags for the library.
* `<BINPATH>/tlvdump`: a simple tool to dump contents of TLV-formatted data * `<BINPATH>/tlvdump`: a simple tool to dump contents of TLV-formatted data
* `<BINPATH>/ndncatchunks3`: a simplified equivalent to ndncatchunks2 in NDNx package * `<BINPATH>/ndncatchunks3`: a simplified equivalent to ndncatchunks2 in NDNx package
@@ -107,7 +104,7 @@ also produce:
Documentation Documentation
------------- -------------
ndn-cpp-dev tutorials and API documentation can be built using the following commands: ndn-cxx tutorials and API documentation can be built using the following commands:
# Full set of documentation (tutorials + API) in build/docs # Full set of documentation (tutorials + API) in build/docs
./waf docs ./waf docs
@@ -139,8 +136,9 @@ The following is the suggested configure commands for development build.
./waf ./waf
sudo ./waf install sudo ./waf install
In the development build all compiler optimizations are disabled by default and all warnings are treated as error. In the development build all compiler optimizations are disabled by default and all
The default behavior can be overridden by setting CXXFLAGS environment variable before running `./waf configure`: warnings are treated as error. The default behavior can be overridden by setting `CXXFLAGS`
environment variable before running `./waf configure`:
CXXFLAGS="-O1 -g3" ./waf configure --debug --with-tests CXXFLAGS="-O1 -g3" ./waf configure --debug --with-tests
... ...
+27 -11
View File
@@ -1,18 +1,34 @@
ndn-cpp-dev: A dev version of Named Data Networking client library for C++ ndn-cxx: NDN C++ library with eXperimental eXtensions
--------------------------------------------------------------------------- =====================================================
ndn-cpp-dev is a new implementation of a Named Data Networking client library written in C++. ndn-cxx is a C++ library, implementing Named Data Networking (NDN) primitives that can be
used to implement various NDN applications. The library is currently being used as part
of the following projects:
ndn-cpp-dev is open source under a license described in the file COPYING. While the license * [NFD - NDN Forwarding Daemon](https://github.com/named-data/NFD)
does not require it, we really would appreciate it if others would share their * [NLSR - Named-data Link-State Routing protocol](https://github.com/named-data/NLSR)
contributions to the library if they are willing to do so under the same license. * [repo-ng - Next generation of NDN repository](https://github.com/named-data/repo-ng)
* [ChronoChat - Multi-user NDN chat application](https://github.com/named-data/ChronoChat)
* [ChronoSync - Sync library for multiuser realtime applications for NDN](https://github.com/named-data/ChronoSync)
* [ndn-tlv-ping - Ping Application For NDN](https://github.com/named-data/ndn-tlv-ping)
* [ndn-traffic - Traffic Generator For NDN](https://github.com/named-data/ndn-traffic)
See the file INSTALL for build and install instructions. See the file INSTALL.md for build and install instructions.
Please submit any bugs or issues to the ndn-cpp-dev issue tracker: Please submit any bugs or issues to the ndn-cxx issue tracker:
http://redmine.named-data.net/projects/ndn-cpp-dev/issues http://redmine.named-data.net/projects/ndn-cxx/issues
## More ## More documentation
Additional library tutorials and manpages are available in `docs/` folder. Extensive documentation of the library is available on the library's homepage:
http://www.named-data.net/doc/ndn-cxx/
## License
ndn-cxx is an open source project licensed under BSD license. For more information about
the license, refer to [`COPYING`](https://github.com/named-data/ndn-cxx/blob/master/COPYING).
While the license does not require it, we really would appreciate it if others would share
their contributions to the library if they are willing to do so under the same license.
+2 -2
View File
@@ -1,5 +1,5 @@
Code style and coding guidelines ndn-cxx Code Style and Coding Guidelines
================================ ========================================
Based on Based on
+5 -5
View File
@@ -45,7 +45,7 @@ source_suffix = '.rst'
master_doc = 'index' master_doc = 'index'
# General information about the project. # General information about the project.
project = u'C++ library for Named Data Networking' project = u'NDN C++ library with eXperimental eXtensions'
copyright = u'2014, Named Data Networking Project' copyright = u'2014, Named Data Networking Project'
# The version info for the project you're documenting, acts as replacement for # The version info for the project you're documenting, acts as replacement for
@@ -53,9 +53,9 @@ copyright = u'2014, Named Data Networking Project'
# built documents. # built documents.
# #
# The short X.Y version. # The short X.Y version.
version = '0.4.0' version = '0.1.0'
# The full version, including alpha/beta/rc tags. # The full version, including alpha/beta/rc tags.
release = '0.4.0' release = '0.1.0'
# The language for content autogenerated by Sphinx. Refer to documentation # The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages. # for a list of supported languages.
@@ -179,7 +179,7 @@ html_static_path = ['_static']
html_file_suffix = ".html" html_file_suffix = ".html"
# Output file base name for HTML help builder. # Output file base name for HTML help builder.
htmlhelp_basename = 'ndn-cpp-dev-docs' htmlhelp_basename = 'ndn-cxx-docs'
# -- Options for LaTeX output --------------------------------------------- # -- Options for LaTeX output ---------------------------------------------
@@ -199,7 +199,7 @@ latex_elements = {
# (source start file, target name, title, # (source start file, target name, title,
# author, documentclass [howto, manual, or own class]). # author, documentclass [howto, manual, or own class]).
latex_documents = [ latex_documents = [
('index', 'ndn-cpp-dev-docs.tex', u'C++ library for Named Data Networking', ('index', 'ndn-cxx-docs.tex', u'NDN C++ library with eXperimental eXtensions',
u'Named Data Networking Project', 'manual'), u'Named Data Networking Project', 'manual'),
] ]
+2 -2
View File
@@ -32,13 +32,13 @@ DOXYFILE_ENCODING = UTF-8
# title of most generated pages and in a few other places. # title of most generated pages and in a few other places.
# The default value is: My Project. # The default value is: My Project.
PROJECT_NAME = "C++ library for Named Data Networking" PROJECT_NAME = "NDN C++ library with eXperimental eXtensions"
# The PROJECT_NUMBER tag can be used to enter a project or revision number. This # The PROJECT_NUMBER tag can be used to enter a project or revision number. This
# could be handy for archiving the generated documentation or if some version # could be handy for archiving the generated documentation or if some version
# control system is used. # control system is used.
PROJECT_NUMBER = PROJECT_NUMBER = 0.1.0
# Using the PROJECT_BRIEF tag one can provide an optional one line description # Using the PROJECT_BRIEF tag one can provide an optional one line description
# for a project that appears at the top of each page and should give viewer a # for a project that appears at the top of each page and should give viewer a
+2 -2
View File
@@ -1,5 +1,5 @@
C++ library for Named Data Networking NDN C++ library with eXperimental eXtensions
===================================== ============================================
`API documentation (doxygen) <doxygen/annotated.html>`_ `API documentation (doxygen) <doxygen/annotated.html>`_
+3 -3
View File
@@ -5,9 +5,9 @@
* BSD License, see COPYING for copyright and distribution information. * BSD License, see COPYING for copyright and distribution information.
*/ */
// correct way to include NDN-CPP headers // correct way to include ndn-cxx headers
// #include <ndn-cpp-dev/face.hpp> // #include <ndn-cxx/face.hpp>
// #include <ndn-cpp-dev/util/scheduler.hpp> // #include <ndn-cxx/util/scheduler.hpp>
#include "face.hpp" #include "face.hpp"
#include "util/scheduler.hpp" #include "util/scheduler.hpp"
+2 -2
View File
@@ -5,8 +5,8 @@
* BSD License, see COPYING for copyright and distribution information. * BSD License, see COPYING for copyright and distribution information.
*/ */
// correct way to include NDN-CPP headers // correct way to include ndn-cxx headers
// #include <ndn-cpp-dev/face.hpp> // #include <ndn-cxx/face.hpp>
#include "face.hpp" #include "face.hpp"
// Enclosing code in ndn simplifies coding (can also use `using namespace ndn`) // Enclosing code in ndn simplifies coding (can also use `using namespace ndn`)
+3 -3
View File
@@ -5,9 +5,9 @@
* BSD License, see COPYING for copyright and distribution information. * BSD License, see COPYING for copyright and distribution information.
*/ */
// correct way to include NDN-CPP headers // correct way to include ndn-cxx headers
// #include <ndn-cpp-dev/face.hpp> // #include <ndn-cxx/face.hpp>
// #include <ndn-cpp-dev/security/key-chain.hpp> // #include <ndn-cxx/security/key-chain.hpp>
#include "face.hpp" #include "face.hpp"
#include "security/key-chain.hpp" #include "security/key-chain.hpp"
+2 -2
View File
@@ -7,6 +7,6 @@ def build(bld):
bld(features=['cxx', 'cxxprogram'], bld(features=['cxx', 'cxxprogram'],
target = '%s' % (str(app.change_ext('','.cpp'))), target = '%s' % (str(app.change_ext('','.cpp'))),
source = app, source = app,
use = 'ndn-cpp-dev', use = 'ndn-cxx',
install_path = None, install_path = None,
) )
-10
View File
@@ -1,10 +0,0 @@
prefix=@prefix@
exec_prefix=@exec_prefix@
libdir=@libdir@
includedir=@includedir@
Name: libndn-cpp-dev
Description: Development version of C++ API for NDN (NDN-TLV packet format)
Version: @VERSION@
Libs: -L${libdir} @EXTRA_LINKFLAGS@ @EXTRA_LDFLAGS@ -lndn-cpp-dev @EXTRA_LIBS@ @EXTRA_FRAMEWORKS@
Cflags: -I${includedir} @EXTRA_CXXFLAGS@ @EXTRA_INCLUDES@
+10
View File
@@ -0,0 +1,10 @@
prefix=@prefix@
exec_prefix=@exec_prefix@
libdir=@libdir@
includedir=@includedir@
Name: libndn-cxx
Description: NDN C++ library with eXperimental eXtensions
Version: @VERSION@
Libs: -L${libdir} @EXTRA_LINKFLAGS@ @EXTRA_LDFLAGS@ -lndn-cxx @EXTRA_LIBS@ @EXTRA_FRAMEWORKS@
Cflags: -I${includedir} @EXTRA_CXXFLAGS@ @EXTRA_INCLUDES@
+6 -7
View File
@@ -1,14 +1,13 @@
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil -*- */ /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil -*- */
/** /**
* Copyright (C) 2013 Regents of the University of California. * Copyright (C) 2013-2014 Regents of the University of California.
* @author: Jeff Thompson <jefft0@remap.ucla.edu>
* See COPYING for copyright and distribution information. * See COPYING for copyright and distribution information.
*/ */
#ifndef NDN_COMMON_HPP #ifndef NDN_COMMON_HPP
#define NDN_COMMON_HPP #define NDN_COMMON_HPP
#include "ndn-cpp-config.hpp" #include "ndn-cxx-config.hpp"
#include <stdint.h> #include <stdint.h>
// TODO: Is stddef.h portable? // TODO: Is stddef.h portable?
#include <stddef.h> #include <stddef.h>
@@ -45,16 +44,16 @@
#define DEPRECATED(func) func #define DEPRECATED(func) func
#endif #endif
#ifdef NDN_CPP_HAVE_CXX11 #ifdef NDN_CXX_HAVE_CXX11
#if defined(__GNUC__) #if defined(__GNUC__)
# if !defined(__GXX_EXPERIMENTAL_CXX0X__) && __cplusplus < 201103L # if !defined(__GXX_EXPERIMENTAL_CXX0X__) && __cplusplus < 201103L
# error "NDN-CPP-DEV library is configured and compiled in C++11 mode, but the current compiler is not C++11 enabled" # error "NDN-CXX library is configured and compiled in C++11 mode, but the current compiler is not C++11 enabled"
# endif // !defined(__GXX_EXPERIMENTAL_CXX0X__) && __cplusplus < 201103L # endif // !defined(__GXX_EXPERIMENTAL_CXX0X__) && __cplusplus < 201103L
#endif // defined(__GNUC__) #endif // defined(__GNUC__)
#if defined(__clang__) && __cplusplus < 201103L #if defined(__clang__) && __cplusplus < 201103L
# error "NDN-CPP-DEV library is configured and compiled in C++11 mode, but the current compiler is not C++11 enabled" # error "NDN-CXX library is configured and compiled in C++11 mode, but the current compiler is not C++11 enabled"
#endif // defined(__clang__) && (__cplusplus < 201103L) #endif // defined(__clang__) && (__cplusplus < 201103L)
@@ -111,7 +110,7 @@ using boost::bind;
} // namespace ndn } // namespace ndn
#endif // NDN_CPP_HAVE_CXX11 #endif // NDN_CXX_HAVE_CXX11
namespace ndn { namespace ndn {
+4 -4
View File
@@ -25,7 +25,7 @@
#include "sec-tpm-file.hpp" #include "sec-tpm-file.hpp"
#include "sec-tpm-memory.hpp" #include "sec-tpm-memory.hpp"
#ifdef NDN_CPP_HAVE_OSX_SECURITY #ifdef NDN_CXX_HAVE_OSX_SECURITY
#include "sec-tpm-osx.hpp" #include "sec-tpm-osx.hpp"
#endif #endif
@@ -662,7 +662,7 @@ private:
#if defined(NDN_CPP_HAVE_OSX_SECURITY) and defined(NDN_CPP_WITH_OSX_KEYCHAIN) #if defined(NDN_CXX_HAVE_OSX_SECURITY) and defined(NDN_CXX_WITH_OSX_KEYCHAIN)
namespace ndn { namespace ndn {
@@ -678,6 +678,6 @@ typedef KeyChainImpl<SecPublicInfoSqlite3, SecTpmFile> KeyChain;
} // namespace ndn } // namespace ndn
#endif //NDN_CPP_HAVE_OSX_SECURITY #endif // NDN_CXX_HAVE_OSX_SECURITY
#endif //NDN_SECURITY_KEY_CHAIN_HPP #endif // NDN_SECURITY_KEY_CHAIN_HPP
+2 -2
View File
@@ -1,6 +1,6 @@
/* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil -*- */ /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil -*- */
/** /**
* Copyright (C) 2013 Regents of the University of California. * Copyright (c) 2013-2014 Regents of the University of California.
* @author: Yingdi Yu <yingdi@cs.ucla.edu> * @author: Yingdi Yu <yingdi@cs.ucla.edu>
* @author: Jeff Thompson <jefft0@remap.ucla.edu> * @author: Jeff Thompson <jefft0@remap.ucla.edu>
* See COPYING for copyright and distribution information. * See COPYING for copyright and distribution information.
@@ -92,7 +92,7 @@ SecPublicInfoSqlite3::SecPublicInfoSqlite3()
/// @todo Add define for windows/unix in wscript. The following may completely fail on windows /// @todo Add define for windows/unix in wscript. The following may completely fail on windows
int res = sqlite3_open_v2((identityDir / "ndnsec-public-info.db").c_str(), &m_database, int res = sqlite3_open_v2((identityDir / "ndnsec-public-info.db").c_str(), &m_database,
SQLITE_OPEN_READWRITE | SQLITE_OPEN_CREATE, SQLITE_OPEN_READWRITE | SQLITE_OPEN_CREATE,
#ifdef NDN_CPP_DISABLE_SQLITE3_FS_LOCKING #ifdef NDN_CXX_DISABLE_SQLITE3_FS_LOCKING
"unix-dotfile" "unix-dotfile"
#else #else
0 0
+3 -3
View File
@@ -45,15 +45,15 @@ ConfigFile::findConfigFile()
} }
} }
#ifdef NDN_CPP_SYSCONFDIR #ifdef NDN_CXX_SYSCONFDIR
path sysconfdir(NDN_CPP_SYSCONFDIR); path sysconfdir(NDN_CXX_SYSCONFDIR);
sysconfdir /= "ndn/client.conf"; sysconfdir /= "ndn/client.conf";
if (exists(sysconfdir)) if (exists(sysconfdir))
{ {
return absolute(sysconfdir); return absolute(sysconfdir);
} }
#endif // NDN_CPP_SYSCONFDIR #endif // NDN_CXX_SYSCONFDIR
path etc("/etc/ndn/client.conf"); path etc("/etc/ndn/client.conf");
if (exists(etc)) if (exists(etc))
+2 -2
View File
@@ -10,7 +10,7 @@
#include "logging.hpp" #include "logging.hpp"
#ifdef NDN_CPP_HAVE_LOG4CXX #ifdef NDN_CXX_HAVE_LOG4CXX
#include <log4cxx/logger.h> #include <log4cxx/logger.h>
#include <log4cxx/basicconfigurator.h> #include <log4cxx/basicconfigurator.h>
@@ -46,4 +46,4 @@ INIT_LOGGERS()
configured = true; configured = true;
} }
#endif #endif // NDN_CXX_HAVE_LOG4CXX
+4 -4
View File
@@ -11,7 +11,7 @@
#include "../common.hpp" #include "../common.hpp"
#ifdef NDN_CPP_HAVE_LOG4CXX #ifdef NDN_CXX_HAVE_LOG4CXX
#include <log4cxx/logger.h> #include <log4cxx/logger.h>
@@ -48,7 +48,7 @@
void void
INIT_LOGGERS() INIT_LOGGERS()
#else // else NDN_CPP_HAVE_LOG4CXX #else // else NDN_CXX_HAVE_LOG4CXX
#define INIT_LOGGER(name) struct LOGGING_DISABLED #define INIT_LOGGER(name) struct LOGGING_DISABLED
#define _LOG_FUNCTION(x) #define _LOG_FUNCTION(x)
@@ -67,12 +67,12 @@ INIT_LOGGERS()
#include <iostream> #include <iostream>
#define _LOG_DEBUG(x) \ #define _LOG_DEBUG(x) \
{ std::clog << s.substr(0, s.size() - 1) << " " << x << std::endl; } { std::clog << x << std::endl; }
#else #else
#define _LOG_DEBUG(x) #define _LOG_DEBUG(x)
#endif #endif
#endif // NDN_CPP_HAVE_LOG4CXX #endif // NDN_CXX_HAVE_LOG4CXX
#endif #endif
+1 -1
View File
@@ -10,7 +10,7 @@ def build(bld):
features="cxx cxxprogram", features="cxx cxxprogram",
source=bld.path.ant_glob(['**/*.cpp'], source=bld.path.ant_glob(['**/*.cpp'],
excl=['**/*-osx.cpp', '**/*-sqlite3.cpp']), excl=['**/*-osx.cpp', '**/*-sqlite3.cpp']),
use='ndn-cpp-dev', use='ndn-cxx',
includes='.', includes='.',
install_path=None, install_path=None,
) )
+1 -1
View File
@@ -28,7 +28,7 @@ public:
m_hasOldDefaultIdentity = false; m_hasOldDefaultIdentity = false;
} }
m_newIdentity.set("/ndn-cpp-dev-test-identity"); m_newIdentity.set("/ndn-cxx-test-identity");
m_newIdentity.appendVersion(); m_newIdentity.appendVersion();
// create the new identity and self-signed certificate // create the new identity and self-signed certificate
+1 -1
View File
@@ -10,7 +10,7 @@ def build(bld):
features="cxx cxxprogram", features="cxx cxxprogram",
source=bld.path.ant_glob(['**/*.cpp'], source=bld.path.ant_glob(['**/*.cpp'],
excl=['**/*-osx.cpp', '**/*-sqlite3.cpp']), excl=['**/*-osx.cpp', '**/*-sqlite3.cpp']),
use='ndn-cpp-dev', use='ndn-cxx',
includes='.', includes='.',
install_path=None, install_path=None,
) )
+4 -3
View File
@@ -10,12 +10,13 @@ def build(bld):
bld(features=['cxx', 'cxxprogram'], bld(features=['cxx', 'cxxprogram'],
target = '%s' % (str(app.change_ext('','.cpp'))), target = '%s' % (str(app.change_ext('','.cpp'))),
source = app, source = app,
use = 'ndn-cpp-dev', use = 'ndn-cxx',
) )
bld (features = "subst", bld (features = "subst",
source = bld.path.ant_glob(['wrapper/*.sh']), source = bld.path.ant_glob(['wrapper/*.sh']),
target = ['%s' % node.change_ext('', '.sh') for node in bld.path.ant_glob(['wrapper/*.sh'])], target = ['%s' % node.change_ext('', '.sh')
for node in bld.path.ant_glob(['wrapper/*.sh'])],
install_path = "${BINDIR}", install_path = "${BINDIR}",
chmod = 0755, chmod = 0755,
) )
+19 -21
View File
@@ -1,9 +1,9 @@
# -*- Mode: python; py-indent-offset: 4; indent-tabs-mode: nil; coding: utf-8; -*- # -*- Mode: python; py-indent-offset: 4; indent-tabs-mode: nil; coding: utf-8; -*-
VERSION = '0.4.0' VERSION = '0.1.0'
APPNAME = "ndn-cpp-dev" APPNAME = "ndn-cxx"
PACKAGE_BUGREPORT = "http://redmine.named-data.net/projects/ndn-cpp-dev" PACKAGE_BUGREPORT = "http://redmine.named-data.net/projects/ndn-cxx"
PACKAGE_URL = "https://github.com/named-data/ndn-cpp-dev" PACKAGE_URL = "https://github.com/named-data/ndn-cxx"
from waflib import Logs, Utils from waflib import Logs, Utils
@@ -21,8 +21,6 @@ def options(opt):
opt.add_option('--with-log4cxx', action='store_true', default=False, dest='log4cxx', opt.add_option('--with-log4cxx', action='store_true', default=False, dest='log4cxx',
help='''Compile with log4cxx logging support''') help='''Compile with log4cxx logging support''')
opt.add_option('--with-c++11', action='store_true', default=False, dest='use_cxx11',
help='''Use C++11 features, even if available in the compiler''')
opt.add_option('--without-tools', action='store_false', default=True, dest='with_tools', opt.add_option('--without-tools', action='store_false', default=True, dest='with_tools',
help='''Do not build tools''') help='''Do not build tools''')
@@ -98,14 +96,14 @@ def configure(conf):
conf.define('SYSCONFDIR', conf.env['SYSCONFDIR']) conf.define('SYSCONFDIR', conf.env['SYSCONFDIR'])
conf.write_config_header('src/ndn-cpp-config.hpp', define_prefix='NDN_CPP_') conf.write_config_header('src/ndn-cxx-config.hpp', define_prefix='NDN_CXX_')
def build(bld): def build(bld):
libndn_cpp = bld( libndn_cxx = bld(
features=['cxx', 'cxxstlib'], # 'cxxshlib', features=['cxx', 'cxxstlib'], # 'cxxshlib',
# vnum="0.3.0", # vnum="0.3.0",
target="ndn-cpp-dev", target="ndn-cxx",
name="ndn-cpp-dev", name="ndn-cxx",
source=bld.path.ant_glob('src/**/*.cpp', source=bld.path.ant_glob('src/**/*.cpp',
excl=['src/**/*-osx.cpp', 'src/**/*-sqlite3.cpp']), excl=['src/**/*-osx.cpp', 'src/**/*-sqlite3.cpp']),
use='BOOST OPENSSL LOG4CXX CRYPTOPP SQLITE3 RT PIC PTHREAD', use='BOOST OPENSSL LOG4CXX CRYPTOPP SQLITE3 RT PIC PTHREAD',
@@ -115,15 +113,15 @@ def build(bld):
) )
if bld.env['WITH_PCH']: if bld.env['WITH_PCH']:
libndn_cpp.pch="src/common.hpp" libndn_cxx.pch="src/common.hpp"
if bld.env['HAVE_OSX_SECURITY']: if bld.env['HAVE_OSX_SECURITY']:
libndn_cpp.source += bld.path.ant_glob('src/**/*-osx.cpp') libndn_cxx.source += bld.path.ant_glob('src/**/*-osx.cpp')
libndn_cpp.mac_app = True libndn_cxx.mac_app = True
libndn_cpp.use += " OSX_COREFOUNDATION OSX_SECURITY" libndn_cxx.use += " OSX_COREFOUNDATION OSX_SECURITY"
# In case we want to make it optional later # In case we want to make it optional later
libndn_cpp.source += bld.path.ant_glob('src/**/*-sqlite3.cpp') libndn_cxx.source += bld.path.ant_glob('src/**/*-sqlite3.cpp')
# Prepare flags that should go to pkgconfig file # Prepare flags that should go to pkgconfig file
pkgconfig_libs = [] pkgconfig_libs = []
@@ -131,7 +129,7 @@ def build(bld):
pkgconfig_linkflags = [] pkgconfig_linkflags = []
pkgconfig_includes = [] pkgconfig_includes = []
pkgconfig_cxxflags = [] pkgconfig_cxxflags = []
for lib in Utils.to_list(libndn_cpp.use): for lib in Utils.to_list(libndn_cxx.use):
if bld.env['LIB_%s' % lib]: if bld.env['LIB_%s' % lib]:
pkgconfig_libs += Utils.to_list(bld.env['LIB_%s' % lib]) pkgconfig_libs += Utils.to_list(bld.env['LIB_%s' % lib])
if bld.env['LIBPATH_%s' % lib]: if bld.env['LIBPATH_%s' % lib]:
@@ -152,8 +150,8 @@ def build(bld):
return [set.setdefault(e,e) for e in alist if e not in set] return [set.setdefault(e,e) for e in alist if e not in set]
pkconfig = bld(features="subst", pkconfig = bld(features="subst",
source="libndn-cpp-dev.pc.in", source="libndn-cxx.pc.in",
target="libndn-cpp-dev.pc", target="libndn-cxx.pc",
install_path="${LIBDIR}/pkgconfig", install_path="${LIBDIR}/pkgconfig",
VERSION=VERSION, VERSION=VERSION,
@@ -178,11 +176,11 @@ def build(bld):
bld.recurse("examples") bld.recurse("examples")
headers = bld.path.ant_glob(['src/**/*.hpp']) headers = bld.path.ant_glob(['src/**/*.hpp'])
bld.install_files("%s/ndn-cpp-dev" % bld.env['INCLUDEDIR'], headers, bld.install_files("%s/ndn-cxx" % bld.env['INCLUDEDIR'], headers,
relative_trick=True, cwd=bld.path.find_node('src')) relative_trick=True, cwd=bld.path.find_node('src'))
bld.install_files("%s/ndn-cpp-dev" % bld.env['INCLUDEDIR'], bld.install_files("%s/ndn-cxx" % bld.env['INCLUDEDIR'],
bld.path.find_resource('src/ndn-cpp-config.hpp')) bld.path.find_resource('src/ndn-cxx-config.hpp'))
bld.install_files("${SYSCONFDIR}/ndn", "client.conf.sample") bld.install_files("${SYSCONFDIR}/ndn", "client.conf.sample")