Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
lxc
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Chen Yisong
lxc
Commits
b6b918a1
Commit
b6b918a1
authored
Mar 11, 2013
by
Stéphane Graber
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
API: export lxc_get_version()
Signed-off-by:
Stéphane Graber
<
stgraber@ubuntu.com
>
Acked-by:
Serge E. Hallyn
<
serge.hallyn@ubuntu.com
>
parent
24fcdb39
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
42 additions
and
7 deletions
+42
-7
Makefile.am
src/lxc/Makefile.am
+4
-2
lxc.h
src/lxc/lxc.h
+0
-5
lxccontainer.c
src/lxc/lxccontainer.c
+6
-0
lxccontainer.h
src/lxc/lxccontainer.h
+1
-0
version.h
src/lxc/version.h
+31
-0
No files found.
src/lxc/Makefile.am
View file @
b6b918a1
...
...
@@ -15,7 +15,8 @@ pkginclude_HEADERS = \
state.h
\
attach.h
\
lxccontainer.h
\
lxclock.h
lxclock.h
\
version.h
if
IS_BIONIC
pkginclude_HEADERS
+=
\
...
...
@@ -71,7 +72,8 @@ liblxc_so_SOURCES = \
lxcutmp.c lxcutmp.h
\
apparmor.c apparmor.h
\
lxclock.h lxclock.c
\
lxccontainer.c lxccontainer.h
lxccontainer.c lxccontainer.h
\
version.c version.h
if
IS_BIONIC
liblxc_so_SOURCES
+=
\
...
...
src/lxc/lxc.h
View file @
b6b918a1
...
...
@@ -197,11 +197,6 @@ extern int lxc_checkpoint(const char *name, int sfd, int flags);
extern
int
lxc_restart
(
const
char
*
,
int
,
struct
lxc_conf
*
,
int
,
const
char
*
);
/*
* Returns the version number of the library
*/
extern
const
char
const
*
lxc_version
(
void
);
/*
* Create and return a new lxccontainer struct.
*/
extern
struct
lxc_container
*
lxc_container_new
(
const
char
*
name
,
const
char
*
configpath
);
...
...
src/lxc/lxccontainer.c
View file @
b6b918a1
...
...
@@ -25,6 +25,7 @@
#include "confile.h"
#include "cgroup.h"
#include "commands.h"
#include "version.h"
#include "log.h"
#include <unistd.h>
#include <sys/types.h>
...
...
@@ -978,6 +979,11 @@ const char *lxc_get_default_config_path(void)
return
default_lxc_path
();
}
const
char
*
lxc_get_version
(
void
)
{
return
lxc_version
();
}
struct
lxc_container
*
lxc_container_new
(
const
char
*
name
,
const
char
*
configpath
)
{
struct
lxc_container
*
c
;
...
...
src/lxc/lxccontainer.h
View file @
b6b918a1
...
...
@@ -87,6 +87,7 @@ int lxc_container_get(struct lxc_container *c);
int
lxc_container_put
(
struct
lxc_container
*
c
);
int
lxc_get_wait_states
(
const
char
**
states
);
const
char
*
lxc_get_default_config_path
(
void
);
const
char
*
lxc_get_version
(
void
);
#if 0
char ** lxc_get_valid_keys();
...
...
src/lxc/version.h
0 → 100644
View file @
b6b918a1
/*
* lxc: linux Container library
*
* (C) Copyright IBM Corp. 2007, 2008
*
* Authors:
* Daniel Lezcano <dlezcano at fr.ibm.com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library 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
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#ifndef _version_h
#define _version_h
/*
* Returns the version number of the library
*/
extern
const
char
const
*
lxc_version
(
void
);
#endif
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment