Main  /  Edit  /  History  /   /  Users Area

Howto

Introduction

This is a collection of small howtos. Most experienced C++ developers would find the official documentation enough, but some less experienced developers might find the following useful.

How to compile the templates with cmake?

First, create your CMakeLists.txt as you would for a simple application (see cmake documentation or see the cmake file of wikipp).

In order for cmake to compile the template whenever your .tmpl files have changed and only then, add the following to your CMakeList.txt file:

set(TEMPLATES my_view.tmpl)
add_custom_command(
   OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/my_view.cpp
   COMMAND cppcms_tmpl_cc
               ${TEMPLATES}
               -o ${CMAKE_CURRENT_BINARY_DIR}/my_view.cpp
               ${TEMPLATES}
   DEPENDS ${TEMPLATES}) 

See also the discussion at Stack overflow.

How to activate CppCMS logging?

Add the following lines to config.js (CppCMS configuration file):

"logging" : {
   "level" : "debug"
}

debug is the more verbose logging level.

You can now generate debug messages by including the following lines in your application:

#include <booster/log.h>

...

BOOSTER_DEBUG("application_name") << "message";

See also logging.


Reload the application | Top | Plugin Architecture

About

CppCMS is a web development framework for performance demanding applications.

Commercial

CppCMS is available under Open Source and Commercial Licenses.

For more details, visit our website: commercial.cppcms.com

Support This Project

SourceForge.net Logo

Поддержать проект

CppCMS needs You


Navigation

Main Page



Valid CSS | Valid XHTML 1.0