Commit cf0d7380 for tesseract
commit cf0d7380ceca398d6a741915ece36153cfbd724c
Author: Stefan Weil <sw@weilnetz.de>
Date: Fri Jun 19 08:00:45 2026 +0200
Remove src/ccutil/fileerr.h
Signed-off-by: Stefan Weil <sw@weilnetz.de>
diff --git a/Makefile.am b/Makefile.am
index af061b80..0a3e6348 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -365,7 +365,6 @@ noinst_HEADERS += src/ccutil/clst.h
noinst_HEADERS += src/ccutil/elst2.h
noinst_HEADERS += src/ccutil/elst.h
noinst_HEADERS += src/ccutil/errcode.h
-noinst_HEADERS += src/ccutil/fileerr.h
noinst_HEADERS += src/ccutil/genericheap.h
noinst_HEADERS += src/ccutil/genericvector.h
noinst_HEADERS += src/ccutil/helpers.h
diff --git a/cmake/SourceLists.cmake b/cmake/SourceLists.cmake
index 58238303..698a5196 100644
--- a/cmake/SourceLists.cmake
+++ b/cmake/SourceLists.cmake
@@ -434,7 +434,6 @@ set(TESSERACT_HDR_INTERNAL
src/ccutil/elst.h
src/ccutil/elst2.h
src/ccutil/errcode.h
- src/ccutil/fileerr.h
src/ccutil/genericvector.h
src/ccutil/genericheap.h
src/ccutil/helpers.h
diff --git a/src/ccstruct/boxread.cpp b/src/ccstruct/boxread.cpp
index 5e0d7eb9..1a208661 100644
--- a/src/ccstruct/boxread.cpp
+++ b/src/ccstruct/boxread.cpp
@@ -19,7 +19,6 @@
#include "boxread.h"
#include "errcode.h" // for ERRCODE, TESSEXIT
-#include "fileerr.h" // for CANTOPENFILE
#include "rect.h" // for TBOX
#include "tprintf.h" // for tprintf
@@ -35,6 +34,8 @@
namespace tesseract {
+constexpr ERRCODE CANTOPENFILE("Can't open file");
+
// Special char code used to identify multi-blob labels.
static const char *kMultiBlobLabelCode = "WordStr";
diff --git a/src/ccutil/fileerr.h b/src/ccutil/fileerr.h
deleted file mode 100644
index 68ed9c9f..00000000
--- a/src/ccutil/fileerr.h
+++ /dev/null
@@ -1,30 +0,0 @@
-/**********************************************************************
- * File: fileerr.h (Formerly filerr.h)
- * Description: Errors for file utilities.
- * Author: Ray Smith
- *
- * (C) Copyright 1990, Hewlett-Packard Ltd.
- ** Licensed under the Apache License, Version 2.0 (the "License");
- ** you may not use this file except in compliance with the License.
- ** You may obtain a copy of the License at
- ** http://www.apache.org/licenses/LICENSE-2.0
- ** Unless required by applicable law or agreed to in writing, software
- ** distributed under the License is distributed on an "AS IS" BASIS,
- ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- ** See the License for the specific language governing permissions and
- ** limitations under the License.
- *
- **********************************************************************/
-
-#ifndef FILEERR_H
-#define FILEERR_H
-
-#include "errcode.h"
-
-namespace tesseract {
-
-constexpr ERRCODE CANTOPENFILE("Can't open file");
-
-} // namespace tesseract
-
-#endif