]> andersk Git - libyaml.git/commitdiff
Move yaml/yaml.h to yaml.h and merge version.c to api.c.
authorKirill Simonov <xi@resolvent.net>
Mon, 3 Jul 2006 13:49:14 +0000 (13:49 +0000)
committerKirill Simonov <xi@resolvent.net>
Mon, 3 Jul 2006 13:49:14 +0000 (13:49 +0000)
include/Makefile.am
include/yaml.h [moved from include/yaml/yaml.h with 100% similarity]
include/yaml/yaml_error.h [deleted file]
include/yaml/yaml_version.h [deleted file]
src/Makefile.am
src/api.c
src/reader.c
src/scanner.c
src/version.c [deleted file]
tests/test-reader.c
tests/test-version.c

index 5c5f7dd69540ef3688be5a596c361d7743ff2e9a..3c7323c40dffed4c7dc805f855d0fcd69417dace 100644 (file)
@@ -1,4 +1,4 @@
-INCLUDES = yaml/yaml.h #yaml/yaml_version.h yaml/yaml_error.h
+INCLUDES = yaml.h
 DOXYGEN_CFG = $(top_srcdir)/doc/doxygen.cfg
 
 nobase_include_HEADERS = $(INCLUDES)
similarity index 100%
rename from include/yaml/yaml.h
rename to include/yaml.h
diff --git a/include/yaml/yaml_error.h b/include/yaml/yaml_error.h
deleted file mode 100644 (file)
index df0ca7d..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-#ifndef YAML_ERROR_H
-#define YAML_ERROR_H
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-typedef enum {
-    YAML_NO_ERROR,
-
-    YAML_MEMORY_ERROR,
-
-    YAML_READER_ERROR,
-    YAML_SCANNER_ERROR,
-    YAML_PARSER_ERROR,
-
-    YAML_WRITER_ERROR,
-    YAML_EMITTER_ERROR
-} yaml_error_type_t;
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* #ifndef YAML_ERROR_H */
diff --git a/include/yaml/yaml_version.h b/include/yaml/yaml_version.h
deleted file mode 100644 (file)
index 9718db2..0000000
+++ /dev/null
@@ -1,33 +0,0 @@
-/*
- * @file yaml_version.h
- * @brief Version information.
- *
- * Do not include yaml_version.h directly.
- */
-
-#ifndef YAML_VERSION_H
-#define YAML_VERSION_H
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*
- * @brief Get the library version.
- */
-
-const char *
-yaml_get_version_string(void);
-
-/*
- * @brief Get the library version numbers.
- */
-
-void
-yaml_get_version(int *major, int *minor, int *patch);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* #ifndef YAML_VERSION_H */
index d30f3dd1837e5c13a6c0b2326a532cdeae04e460..c8797dc09a83843130362cf34fc814f67de6647b 100644 (file)
@@ -1,4 +1,4 @@
 AM_CPPFLAGS = -I$(top_srcdir)/include
 lib_LTLIBRARIES = libyaml.la
-libyaml_la_SOURCES = version.c api.c reader.c scanner.c
+libyaml_la_SOURCES = api.c reader.c scanner.c
 libyaml_la_LDFLAGS = -release $(YAML_LT_RELEASE) -version-info $(YAML_LT_CURRENT):$(YAML_LT_REVISION):$(YAML_LT_AGE)
index 88e03e7652947d3f4ef4996bf7ba8e3f8edaf758..304775362bfb3d8c375a0d856340768252d614ac 100644 (file)
--- a/src/api.c
+++ b/src/api.c
@@ -3,10 +3,24 @@
 #include <config.h>
 #endif
 
-#include <yaml/yaml.h>
+#include <yaml.h>
 
 #include <assert.h>
 
+YAML_DECLARE(const char *)
+yaml_get_version_string(void)
+{
+    return YAML_VERSION_STRING;
+}
+
+YAML_DECLARE(void)
+yaml_get_version(int *major, int *minor, int *patch)
+{
+    *major = YAML_VERSION_MAJOR;
+    *minor = YAML_VERSION_MINOR;
+    *patch = YAML_VERSION_PATCH;
+}
+
 /*
  * Allocate a dynamic memory block.
  */
index 946d298d16c05f6d109532519f90688f895f1dc1..9cc8e7bb1190eff5f59b22c3d1b97553c81c1526 100644 (file)
@@ -3,7 +3,7 @@
 #include <config.h>
 #endif
 
-#include <yaml/yaml.h>
+#include <yaml.h>
 
 #include <assert.h>
 
index 8313acd2019f51b69c1ae1fcd9f12117b9daea12..45af0c1938c2b5e14c8797d8dc9e37b94902be76 100644 (file)
 #include <config.h>
 #endif
 
-#include <yaml/yaml.h>
+#include <yaml.h>
 
 #include <assert.h>
 
diff --git a/src/version.c b/src/version.c
deleted file mode 100644 (file)
index b7f5904..0000000
+++ /dev/null
@@ -1,21 +0,0 @@
-
-#if HAVE_CONFIG_H
-#include <config.h>
-#endif
-
-#include <yaml/yaml.h>
-
-const char *
-yaml_get_version_string(void)
-{
-    return YAML_VERSION_STRING;
-}
-
-void
-yaml_get_version(int *major, int *minor, int *patch)
-{
-    *major = YAML_VERSION_MAJOR;
-    *minor = YAML_VERSION_MINOR;
-    *patch = YAML_VERSION_PATCH;
-}
-
index 53e4e7a0a67b5196b07762e50d8e62210d722903..c5ce279074cfa3583bc471054d9d3880a28bbcb2 100644 (file)
@@ -1,4 +1,4 @@
-#include <yaml/yaml.h>
+#include <yaml.h>
 
 #include <stdlib.h>
 #include <stdio.h>
index 578d6780d9b29a4562e5a70a05a4eccebf656805..ab4f93c27b38500a7ff0b0ada62c23b668ca69ba 100644 (file)
@@ -1,4 +1,4 @@
-#include <yaml/yaml.h>
+#include <yaml.h>
 
 #include <stdlib.h>
 #include <stdio.h>
This page took 0.15927 seconds and 5 git commands to generate.