[glibmm] tools/gen_scripts: Don't read private.h files
- From: Kjell Ahlstedt <kjellahl src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glibmm] tools/gen_scripts: Don't read private.h files
- Date: Thu, 30 Jul 2015 15:03:35 +0000 (UTC)
commit 40b6ca519a10da8279bd59f65f703d034ed90147
Author: Kjell Ahlstedt <kjell ahlstedt bredband net>
Date: Thu Jul 30 16:56:38 2015 +0200
tools/gen_scripts: Don't read private.h files
* tools/gen_scripts/gio_generate_enums.sh:
* tools/gen_scripts/gio_generate_methods.sh:
* tools/gen_scripts/glib_generate_enums.sh:
* tools/gen_scripts/glib_generate_methods.sh: Don't collect information
from header files with names ending in private.h.
tools/gen_scripts/gio_generate_enums.sh | 4 +++-
tools/gen_scripts/gio_generate_methods.sh | 4 +++-
tools/gen_scripts/glib_generate_enums.sh | 8 +++++---
tools/gen_scripts/glib_generate_methods.sh | 8 +++++---
4 files changed, 16 insertions(+), 8 deletions(-)
---
diff --git a/tools/gen_scripts/gio_generate_enums.sh b/tools/gen_scripts/gio_generate_enums.sh
index f9de800..f891868 100755
--- a/tools/gen_scripts/gio_generate_enums.sh
+++ b/tools/gen_scripts/gio_generate_enums.sh
@@ -28,10 +28,12 @@ OUT_DIR="$ROOT_DIR/gio/src"
OUT_FILE=gio_enums.defs
OUT_DIR_FILE="$OUT_DIR"/$OUT_FILE
+shopt -s extglob # Enable extended pattern matching
if [ $# -eq 0 ]
then
ENUM_PL="$JHBUILD_SOURCES/glibmm/tools/enum.pl"
- $ENUM_PL "$PREFIX"/gio/*.h > "$OUT_DIR_FILE"
+ # Process files whose names end with .h, but not with private.h.
+ $ENUM_PL "$PREFIX"/gio/!(*private).h > "$OUT_DIR_FILE"
# patch version 2.7.5 does not like directory names.
cd "$OUT_DIR"
PATCH_OPTIONS="--backup --version-control=simple --suffix=.orig"
diff --git a/tools/gen_scripts/gio_generate_methods.sh b/tools/gen_scripts/gio_generate_methods.sh
index 1616037..c7dc79f 100755
--- a/tools/gen_scripts/gio_generate_methods.sh
+++ b/tools/gen_scripts/gio_generate_methods.sh
@@ -13,6 +13,8 @@ PREFIX="$JHBUILD_SOURCES/glib"
ROOT_DIR="$(dirname "$0")/../.."
OUT_DIR="$ROOT_DIR/gio/src"
+shopt -s extglob # Enable extended pattern matching
H2DEF_PY="$JHBUILD_SOURCES/glibmm/tools/defs_gen/h2def.py"
-$H2DEF_PY "$PREFIX"/gio/*.h > "$OUT_DIR"/gio_methods.defs
+# Process files whose names end with .h, but not with private.h.
+$H2DEF_PY "$PREFIX"/gio/!(*private).h > "$OUT_DIR"/gio_methods.defs
#patch "$OUT_DIR"/gio_methods.defs "$OUT_DIR"/gio_methods.defs.patch
diff --git a/tools/gen_scripts/glib_generate_enums.sh b/tools/gen_scripts/glib_generate_enums.sh
index 220064e..b366ffd 100755
--- a/tools/gen_scripts/glib_generate_enums.sh
+++ b/tools/gen_scripts/glib_generate_enums.sh
@@ -26,12 +26,14 @@ PREFIX="$JHBUILD_SOURCES/glib"
ROOT_DIR="$(dirname "$0")/../.."
OUT_DIR="$ROOT_DIR/glib/src"
+shopt -s extglob # Enable extended pattern matching
if [ $# -eq 0 ]
then
ENUM_PL="$JHBUILD_SOURCES/glibmm/tools/enum.pl"
- $ENUM_PL "$PREFIX"/glib/*.h "$PREFIX"/glib/deprecated/*.h > "$OUT_DIR"/glib_enums.defs
- $ENUM_PL "$PREFIX"/gmodule/*.h > "$OUT_DIR"/gmodule_enums.defs
- $ENUM_PL "$PREFIX"/gobject/*.h > "$OUT_DIR"/gobject_enums.defs
+ # Process files whose names end with .h, but not with private.h.
+ $ENUM_PL "$PREFIX"/glib/!(*private).h "$PREFIX"/glib/deprecated/!(*private).h > "$OUT_DIR"/glib_enums.defs
+ $ENUM_PL "$PREFIX"/gmodule/!(*private).h > "$OUT_DIR"/gmodule_enums.defs
+ $ENUM_PL "$PREFIX"/gobject/!(*private).h > "$OUT_DIR"/gobject_enums.defs
# patch version 2.7.5 does not like directory names.
cd "$OUT_DIR"
PATCH_OPTIONS="--backup --version-control=simple --suffix=.orig"
diff --git a/tools/gen_scripts/glib_generate_methods.sh b/tools/gen_scripts/glib_generate_methods.sh
index ef41146..701856a 100755
--- a/tools/gen_scripts/glib_generate_methods.sh
+++ b/tools/gen_scripts/glib_generate_methods.sh
@@ -26,12 +26,14 @@ PREFIX="$JHBUILD_SOURCES/glib"
ROOT_DIR="$(dirname "$0")/../.."
OUT_DIR="$ROOT_DIR/glib/src"
+shopt -s extglob # Enable extended pattern matching
if [ $# -eq 0 ]
then
H2DEF_PY="$JHBUILD_SOURCES/glibmm/tools/defs_gen/h2def.py"
- $H2DEF_PY "$PREFIX"/glib/*.h "$PREFIX"/glib/deprecated/*.h > "$OUT_DIR"/glib_functions.defs
- $H2DEF_PY "$PREFIX"/gmodule/*.h > "$OUT_DIR"/gmodule_functions.defs
- $H2DEF_PY "$PREFIX"/gobject/*.h > "$OUT_DIR"/gobject_functions.defs
+ # Process files whose names end with .h, but not with private.h.
+ $H2DEF_PY "$PREFIX"/glib/!(*private).h "$PREFIX"/glib/deprecated/!(*private).h >
"$OUT_DIR"/glib_functions.defs
+ $H2DEF_PY "$PREFIX"/gmodule/!(*private).h > "$OUT_DIR"/gmodule_functions.defs
+ $H2DEF_PY "$PREFIX"/gobject/!(*private).h > "$OUT_DIR"/gobject_functions.defs
# patch version 2.7.5 does not like directory names.
cd "$OUT_DIR"
PATCH_OPTIONS="--backup --version-control=simple --suffix=.orig"
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]