mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Make business sql backend initialization functions accessible when statically linking.
Same change as what r18841 added in business-core/xml. git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@19255 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
parent
f21313c526
commit
e37590aa2f
@ -31,6 +31,7 @@ SET (libgnc_business_backend_sql_SOURCES
|
||||
gnc-vendor-sql.c
|
||||
)
|
||||
SET (libgnc_business_backend_sql_HEADERS
|
||||
gncmod-business-backend-sql.h
|
||||
gnc-address-sql.h
|
||||
gnc-bill-term-sql.h
|
||||
gnc-customer-sql.h
|
||||
|
@ -28,6 +28,7 @@ libgncmod_business_backend_sql_la_SOURCES = \
|
||||
gnc-vendor-sql.c
|
||||
|
||||
noinst_HEADERS = \
|
||||
gncmod-business-backend-sql.h \
|
||||
gnc-address-sql.h \
|
||||
gnc-bill-term-sql.h \
|
||||
gnc-customer-sql.h \
|
||||
|
@ -49,6 +49,7 @@
|
||||
#include "gnc-owner-sql.h"
|
||||
#include "gnc-tax-table-sql.h"
|
||||
#include "gnc-vendor-sql.h"
|
||||
#include "gncmod-business-backend-sql.h"
|
||||
|
||||
GNC_MODULE_API_DECL(libgncmod_business_backend_sql)
|
||||
|
||||
@ -79,6 +80,25 @@ libgncmod_business_backend_sql_gnc_module_description(void)
|
||||
static const gchar* fixed_load_order[] =
|
||||
{ GNC_ID_BILLTERM, GNC_ID_TAXTABLE, NULL };
|
||||
|
||||
void
|
||||
gnc_module_init_business_core_sql_init(void)
|
||||
{
|
||||
/* Initialize our pointers into the backend subsystem */
|
||||
gnc_address_sql_initialize();
|
||||
gnc_billterm_sql_initialize();
|
||||
gnc_customer_sql_initialize();
|
||||
gnc_employee_sql_initialize();
|
||||
gnc_entry_sql_initialize();
|
||||
gnc_invoice_sql_initialize();
|
||||
gnc_job_sql_initialize();
|
||||
gnc_order_sql_initialize();
|
||||
gnc_owner_sql_initialize();
|
||||
gnc_taxtable_sql_initialize();
|
||||
gnc_vendor_sql_initialize();
|
||||
|
||||
gnc_sql_set_load_order( fixed_load_order );
|
||||
}
|
||||
|
||||
int
|
||||
libgncmod_business_backend_sql_gnc_module_init(int refcount)
|
||||
{
|
||||
@ -92,20 +112,7 @@ libgncmod_business_backend_sql_gnc_module_init(int refcount)
|
||||
|
||||
if ( refcount == 0 )
|
||||
{
|
||||
/* Initialize our pointers into the backend subsystem */
|
||||
gnc_address_sql_initialize();
|
||||
gnc_billterm_sql_initialize();
|
||||
gnc_customer_sql_initialize();
|
||||
gnc_employee_sql_initialize();
|
||||
gnc_entry_sql_initialize();
|
||||
gnc_invoice_sql_initialize();
|
||||
gnc_job_sql_initialize();
|
||||
gnc_order_sql_initialize();
|
||||
gnc_owner_sql_initialize();
|
||||
gnc_taxtable_sql_initialize();
|
||||
gnc_vendor_sql_initialize();
|
||||
|
||||
gnc_sql_set_load_order( fixed_load_order );
|
||||
gnc_module_init_business_core_sql_init();
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
|
32
src/business/business-core/sql/gncmod-business-backend-sql.h
Normal file
32
src/business/business-core/sql/gncmod-business-backend-sql.h
Normal file
@ -0,0 +1,32 @@
|
||||
/*********************************************************************
|
||||
* gncmod-business-backend-sql.h
|
||||
* module definition/initialization for the sql backend module
|
||||
*
|
||||
* Copyright (c) 2010 Christian Stimming <stimming@tuhh.de>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License as
|
||||
* published by the Free Software Foundation; either version 2 of
|
||||
* the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, contact:
|
||||
*
|
||||
* Free Software Foundation Voice: +1-617-542-5942
|
||||
* 51 Franklin Street, Fifth Floor Fax: +1-617-542-2652
|
||||
* Boston, MA 02110-1301, USA gnu@gnu.org
|
||||
*
|
||||
*********************************************************************/
|
||||
|
||||
#ifndef GNCMOD_BUSINESS_BACKEND_SQL_H
|
||||
#define GNCMOD_BUSINESS_BACKEND_SQL_H
|
||||
|
||||
void
|
||||
gnc_module_init_business_core_sql_init(void);
|
||||
|
||||
#endif
|
Loading…
Reference in New Issue
Block a user