** Development Ethereum in Linux
As a developer working on Ethereum projects, building and maintaining blockchain can be a difficult task. One of the common problems encountered by many programmers is to encounter errors related to missing header files, in particular DB_CXX.H
. In this article, we will delve into the causes of these mistakes and provide tips on how to overcome them while building Ethereum on Linux based in Debian.
Why do I get the error “no such file or directory”?
The error message “heders.h: 36: 20: Fatal error: DB_CXX.H: No such file or directory” indicates that the compiler is not able to find the header file DB_CXX.H
. This file is part of the Ethereum C ++ libraries that are used by the Ethereum programmers team. To solve this problem, you need to make sure that the necessary dependencies are installed in the system.
Installation of the required packages
To build and start Ethereum in Linux from Debian, you need to install several packages:
Libdb4
(PostgresQL database library)
DBCPP
Libssl-dev
(for encryption SSL/TLS)
You can install these packages using a packaging manager:
`Bash
sudo apt-get install Libdb4-dev DBCPP
overcoming errors with missing header files
To solve the error, you need to make sure that the necessary dependencies are correctly installed and configured. Here is a step by step guide:
1.
`Bash
sudo apt-get remove libdb4-*
- Follow the installation instructions to install
DBCPP
.
- Update compiler settings : Make sure the compiler is correctly configured to use C ++ packaging for the PostgresQL database. You can do this by adding the following flags to your compiler’s command:
`Bash
-Std = C ++ 11 -Wall -Wextra -I -I/USR/Include/PostgresQL/10 -L/USR/LIB/PostgresQL/10 -LDBC
Replace /USR/Include/Postgresql/10
/USR/LIB/Postgresql/10Factive paths in the system.
- Rebuild Ethereum
: After updating the compiler's settings, rebuildEthereum
using:
Bash
Clear and do
This should solve all problems related to missing header files.
problem solving
If you encounter difficulties during the reconstruction of Ethereum or starting tests, make sure:
- Your system is current with the latest packages.
- The dependencies
Libdb4
iDBCPP
are properly installed.
- You updated the compiler settings in accordance with the above instructions.
- You rebuilt “Ethereum” using the correct commands.
By following these steps, you should be able to solve the “headers. H: 36: 20: Fatal error: DB_CXX.H: No such file or directory “and successfully build and start Ethereum in Linux from Debian.