frosix

Multiparty signature service (experimental)
Log | Files | Refs | README | LICENSE

os_installation.c (1905B)


      1 /*
      2      This file is part of GNU Frosix.
      3      Copyright (C) 2019, 2021 Anastasis SARL
      4 
      5      Frosix is free software; you can redistribute it and/or modify
      6      it under the terms of the GNU General Public License as published
      7      by the Free Software Foundation; either version 3, or (at your
      8      option) any later version.
      9 
     10      Frosix is distributed in the hope that it will be useful, but
     11      WITHOUT ANY WARRANTY; without even the implied warranty of
     12      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
     13      General Public License for more details.
     14 
     15      You should have received a copy of the GNU General Public License
     16      along with Frosix; see the file COPYING.  If not, write to the
     17      Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
     18      Boston, MA 02110-1301, USA.
     19 */
     20 
     21 /**
     22  * @file os_installation.c
     23  * @brief initialize libgnunet OS subsystem for Frosix.
     24  * @author Christian Grothoff
     25  */
     26 #include "platform.h"
     27 #include <gnunet/gnunet_util_lib.h>
     28 #include "frost_high.h"
     29 
     30 
     31 /**
     32  * Default project data used for installation path detection
     33  * for Frosix.
     34  */
     35 static const struct GNUNET_OS_ProjectData frosix_pd = {
     36   .libname = "libfrosixutil",
     37   .project_dirname = "frosix",
     38   .binary_name = "frosix-httpd",
     39   .env_varname = "FROSIX_PREFIX",
     40   .base_config_varname = "FROSIX_BASE_CONFIG",
     41   .bug_email = "",
     42   .homepage = "",
     43   .config_file = "frosix.conf",
     44   .user_config_file = "~/.config/frosix.conf",
     45   .version = "0.0.0",
     46   .is_gnu = 0,
     47   .gettext_domain = "frosix",
     48   .gettext_path = NULL,
     49 };
     50 
     51 
     52 /**
     53  * Return default project data used by Frosix.
     54  */
     55 const struct GNUNET_OS_ProjectData *
     56 FROSIX_project_data_default (void)
     57 {
     58   return &frosix_pd;
     59 }
     60 
     61 
     62 /**
     63  * Initialize libfrosixutil.
     64  */
     65 void __attribute__ ((constructor))
     66 FROSIX_OS_init ()
     67 {
     68   GNUNET_OS_init (&frosix_pd);
     69   GNUNET_assert (-1 != FROST_init ());
     70 }
     71 
     72 
     73 /* end of os_installation.c */