kicad-source-mirror
This is an active mirror of the KiCad development branch, which is hosted at GitLab (updated every time something is pushed). Pull requests on GitHub are not accepted or watched.
Top Related Projects
Horizon is a free EDA package
A powerful, innovative and intuitive EDA suite for everyone!
Fritzing desktop application
Quick Overview
KiCad is an open-source Electronic Design Automation (EDA) software suite for creating schematics and printed circuit board (PCB) layouts. The kicad-source-mirror repository on GitHub contains the source code for KiCad, allowing developers to contribute to the project and build KiCad from source.
Pros
- Free and open-source, making it accessible to hobbyists, students, and professionals
- Cross-platform compatibility (Windows, macOS, Linux)
- Extensive library of components and footprints
- Active community and regular updates
Cons
- Steeper learning curve compared to some commercial EDA tools
- Limited advanced features compared to high-end commercial alternatives
- Performance can be slower for very large and complex designs
- Documentation can be inconsistent or outdated in some areas
Getting Started
To build KiCad from source:
-
Clone the repository:
git clone https://github.com/KiCad/kicad-source-mirror.git
-
Install dependencies (example for Ubuntu):
sudo apt-get install build-essential cmake libwxgtk3.0-gtk3-dev libglew-dev libglm-dev \ libcurl4-openssl-dev libssl-dev libboost-dev libboost-filesystem-dev \ libboost-system-dev libboost-test-dev python3-dev swig
-
Create a build directory and configure:
mkdir build && cd build cmake ../kicad-source-mirror
-
Build KiCad:
make -j$(nproc)
-
Install:
sudo make install
Note: Building from source requires development experience and may vary depending on your operating system and environment. For most users, it's recommended to use pre-built packages available from the official KiCad website.
Competitor Comparisons
Horizon is a free EDA package
Pros of Horizon
- Integrated library management system with version control
- Unified interface for schematic and PCB design
- Modern C++ codebase with GPU acceleration
Cons of Horizon
- Smaller user base and community support
- Less extensive component libraries
- Fewer third-party plugins and integrations
Code Comparison
Horizon (C++):
class Core {
public:
Core(const std::string &config_filename);
void run();
private:
std::unique_ptr<class CorePrivate> priv;
};
KiCad (C++):
class PCB_EDIT_FRAME : public PCB_BASE_FRAME
{
public:
PCB_EDIT_FRAME( KIWAY* aKiway, wxWindow* aParent );
~PCB_EDIT_FRAME();
void OnCloseWindow( wxCloseEvent& Event ) override;
};
Both projects use C++ for their core functionality, but Horizon's codebase appears more modern and streamlined. KiCad's code reflects its longer history and broader feature set, with more complex class hierarchies. Horizon's design philosophy emphasizes a unified approach, while KiCad maintains separate modules for different aspects of PCB design.
A powerful, innovative and intuitive EDA suite for everyone!
Pros of LibrePCB
- Modern, clean codebase written in C++
- Unified library concept for all elements
- Built-in version control for libraries and projects
Cons of LibrePCB
- Smaller community and ecosystem compared to KiCad
- Fewer advanced features and specialized tools
- Limited third-party component libraries
Code Comparison
KiCad (C++):
void SCH_EDIT_FRAME::OnOpenLibraryViewer( wxCommandEvent& event )
{
LIB_VIEW_FRAME* viewlibframe = LIB_VIEW_FRAME::ShowLibraryViewer( this );
viewlibframe->Raise();
}
LibrePCB (C++):
void SchematicEditor::openLibraryManager() noexcept
{
LibraryManager::instance().openLibraryManager(this);
}
Both projects use C++, but LibrePCB's codebase appears more modern and concise. KiCad's code shows its legacy, with longer function names and more verbose implementation. LibrePCB's code is more straightforward and follows contemporary C++ practices.
While KiCad has a larger community and more extensive features, LibrePCB offers a fresh approach with a unified library concept and built-in version control. However, LibrePCB's smaller ecosystem and fewer specialized tools may limit its appeal for complex projects.
Fritzing desktop application
Pros of Fritzing
- More beginner-friendly interface with visual representations of components
- Easier to create quick prototypes and breadboard layouts
- Includes a PCB fabrication service directly integrated into the software
Cons of Fritzing
- Less powerful and feature-rich for complex PCB design compared to KiCad
- Smaller component library and less frequent updates
- Limited schematic capture capabilities for advanced designs
Code Comparison
KiCad (C++):
void SCH_EDIT_FRAME::OnOpenPcbnew( wxCommandEvent& event )
{
PROJECT* project = &Prj();
wxFileName fn = Prj().AbsolutePath( m_CurrentSheet->GetScreen()->GetFileName() );
fn.SetExt( PCB_FILE_EXT );
wxString path = fn.GetFullPath();
Fritzing (C++/Qt):
void MainWindow::createZoomControls(SketchAreaWidget* parent) {
ZoomControls * zoomControls = new ZoomControls(parent);
connect(zoomControls, SIGNAL(zoomInSignal()), this, SLOT(zoomIn()));
connect(zoomControls, SIGNAL(zoomOutSignal()), this, SLOT(zoomOut()));
connect(zoomControls, SIGNAL(fitInWindowSignal()), this, SLOT(fitInWindow()));
Both projects use C++, with Fritzing heavily utilizing Qt framework. KiCad's codebase appears more complex, reflecting its more advanced features and capabilities.
Convert
designs to code with AI
Introducing Visual Copilot: A new AI model to turn Figma designs to high quality code using your components.
Try Visual CopilotREADME
KiCad README
For specific documentation about building KiCad, policies and guidelines, and source code documentation see the Developer Documentation website.
You may also take a look into the Wiki, the contribution guide.
For general information about KiCad and information about contributing to the documentation and libraries, see our Website and our Forum.
Build state
KiCad uses a host of CI resources.
GitLab CI pipeline status can be viewed for Linux and Windows builds of the latest commits.
Release status
Files
- AUTHORS.txt - The authors, contributors, document writers and translators list
- CMakeLists.txt - Main CMAKE build tool script
- copyright.h - A very short copy of the GNU General Public License to be included in new source files
- Doxyfile - Doxygen config file for KiCad
- INSTALL.txt - The release (binary) installation instructions
- uncrustify.cfg - Uncrustify config file for uncrustify sources formatting tool
- _clang-format - clang config file for clang-format sources formatting tool
Subdirectories
- 3d-viewer - Sourcecode of the 3D viewer
- bitmap2component - Sourcecode of the bitmap to PCB artwork converter
- cmake - Modules for the CMAKE build tool
- common - Sourcecode of the common library
- cvpcb - Sourcecode of the CvPCB tool
- demos - Some demo examples
- doxygen - Configuration for generating pretty doxygen manual of the codebase
- eeschema - Sourcecode of the schematic editor
- gerbview - Sourcecode of the gerber viewer
- include - Interfaces to the common library
- kicad - Sourcecode of the project manager
- libs - Sourcecode of KiCad utilities (geometry and others)
- pagelayout_editor - Sourcecode of the pagelayout editor
- patches - Collection of patches for external dependencies
- pcbnew - Sourcecode of the printed circuit board editor
- plugins - Sourcecode for the 3D viewer plugins
- qa - Unit testing framework for KiCad
- resources - Packaging resources such as bitmaps and operating system specific files
- bitmaps_png - Menu and program icons
- project_template - Project template
- scripting - Python integration for KiCad
- thirdparty - Sourcecode of external libraries used in KiCad but not written by the KiCad team
- tools - Helpers for developing, testing and building
- translation - Translation data files (managed through Weblate for most languages)
- utils - Small utils for KiCad, e.g. IDF, STEP, and OGL tools and converters
Top Related Projects
Horizon is a free EDA package
A powerful, innovative and intuitive EDA suite for everyone!
Fritzing desktop application
Convert
designs to code with AI
Introducing Visual Copilot: A new AI model to turn Figma designs to high quality code using your components.
Try Visual Copilot