Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
97f1a90
feat(android): Enable build and audio on Termux
TrinityUnited Aug 5, 2025
13a2ad5
docs(GEMINI): Further update GEMINI.md and submodule state
TrinityUnited Aug 5, 2025
7885a21
chore: Clean up repository and update ggsock submodule
TrinityUnited Aug 5, 2025
8227bc7
Fix Termux build and update README
TrinityUnited Aug 5, 2025
0053220
feat: Restore .clang-format and README-tmpl.md
TrinityUnited Aug 5, 2025
97818f1
feat: Restore .clang-format and README-tmpl.md; update README.md and …
TrinityUnited Aug 5, 2025
418f9f2
docs(GEMINI): Document ggsock submodule compilation error and update …
TrinityUnited Aug 5, 2025
3ff9366
build: Add submodule initialization to CMakeLists.txt
TrinityUnited Aug 5, 2025
6685736
Gemini
TrinityUnited Aug 8, 2025
d3a9ef4
Realme B side of changes
TrinityUnited Aug 29, 2025
c1f4bf3
chore: purge build artifacts and machine-generated files
May 15, 2026
14b6c1f
Merge upstream/master and resolve conflicts (keeping Termux fixes)
May 15, 2026
8bfc356
chore: successful purge of build artifacts
May 15, 2026
ca66e38
fix: restore missing imgui CMakeLists and show submodule sync progress
May 15, 2026
0b72e5a
feat: stabilize Python build and improve CLI tool usability
May 15, 2026
e5b5e75
Automated commit, probably minor changes
May 15, 2026
d696ba9
fix: use CMAKE_CURRENT_SOURCE_DIR for imgui-extra sources
May 15, 2026
7172d4c
Automated commit, probably minor changes
May 15, 2026
8efcf95
fix: apply absolute path fix to all platforms in imgui CMakeLists.txt
May 15, 2026
b8101bb
docs: add GEMINI.md to master branch
May 15, 2026
8a72a87
chore: update .gitignore and submodule
May 15, 2026
35a59b9
chore: ignore CPack config files
May 15, 2026
5d52bea
Merge master into feat/stabilize-build-and-cli and resolve conflicts
Manamama-Gemini-Cloud-AI-01 May 15, 2026
9c625a0
Automated commit, probably minor changes
Manamama-Gemini-Cloud-AI-01 May 15, 2026
ea63612
chore: update ggsock submodule to include .gitignore fix
May 15, 2026
a2926e6
docs: remove GEMINI.md from this branch as requested
May 15, 2026
28324ef
feat(ggwave-cli): wait for audio playback to finish when using piped …
May 17, 2026
02c0fdb
feat(ggwave-cli): refine piped input sync with wait loop
May 17, 2026
1a4bbe8
docs: add warning about build permissions and sudo make install
May 17, 2026
09e98c2
chore: revert ggsock submodule to upstream version
May 17, 2026
a410f72
Automated commit, probably minor changes
Manamama-Gemini-Cloud-AI-01 Jun 3, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 26 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,26 @@
build
build-*
# Common build artifacts
build/
build-*/
bin/
Makefile
cmake_install.cmake
CMakeCache.txt
CMakeFiles/
CPackConfig.cmake
CPackSourceConfig.cmake
CTestTestfile.cmake
_deps/
*.so
*.a
*.dylib
*.dll
*.exe
*.o
*.obj
*.pyc
__pycache__/

# Editor/Tools
compile_commands.json
.exrc
.clangd
Expand All @@ -8,3 +29,6 @@ compile_commands.json
.*.swp
.ycm_extra_conf.py
.DS_Store
.ipynb_checkpoints/
.vscode/
.idea/
14 changes: 13 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,16 @@
cmake_minimum_required (VERSION 3.10)
project(ggwave VERSION 0.4.3)

# Initialize and update Git submodules
message(STATUS "Synchronizing submodules...")
execute_process(COMMAND git submodule update --init --recursive
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
RESULT_VARIABLE submodule_result)

if(NOT submodule_result EQUAL 0)
message(FATAL_ERROR "Failed to initialize submodules")
endif()

set(GGWAVE_VERSION_PYTHON 0.4.3)

set(CMAKE_EXPORT_COMPILE_COMMANDS "on")
Expand All @@ -16,7 +26,9 @@ if(CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR)
configure_file(${CMAKE_SOURCE_DIR}/README-tmpl.md ${CMAKE_SOURCE_DIR}/README.md @ONLY)
configure_file(${CMAKE_SOURCE_DIR}/bindings/python/setup-tmpl.py ${CMAKE_SOURCE_DIR}/bindings/python/setup.py @ONLY)
configure_file(${CMAKE_SOURCE_DIR}/bindings/javascript/package-tmpl.json ${CMAKE_SOURCE_DIR}/bindings/javascript/package.json @ONLY)
configure_file(${CMAKE_SOURCE_DIR}/bindings/ios/Makefile-tmpl ${CMAKE_SOURCE_DIR}/bindings/ios/Makefile @ONLY)
if (GGWAVE_SUPPORT_SWIFT)
configure_file(${CMAKE_SOURCE_DIR}/bindings/ios/Makefile-tmpl ${CMAKE_SOURCE_DIR}/bindings/ios/Makefile @ONLY)
endif()
else()
set(GGWAVE_STANDALONE OFF)
endif()
Expand Down
91 changes: 61 additions & 30 deletions README-tmpl.md
Original file line number Diff line number Diff line change
Expand Up @@ -135,48 +135,87 @@ Other projects using **ggwave** or one of its prototypes:

## Building

### Dependencies for SDL-based examples
### Prerequisites

[Ubuntu]
$ sudo apt install libsdl2-dev
To build all tools and bindings, ensure you have the necessary dependencies installed:

[Mac OS with brew]
$ brew install sdl2
```bash
# [Ubuntu/Debian]
sudo apt install cmake make build-essential libsdl2-dev python3-dev python3-pip

# [Python Tools]
pip install cython cogapp --user
```

[MSYS2]
$ pacman -S git cmake make mingw-w64-x86_64-dlfcn mingw-w64-x86_64-gcc mingw-w64-x86_64-SDL2
### Standard Build & Install (Linux, Mac, Windows MSYS2)

### Linux, Mac, Windows (MSYS2)
The recommended way to build and install `ggwave` is using CMake. This will build the core library, CLI tools, and the Python bindings.

```bash
# build
# 1. Clone the repository
git clone https://github.com/ggerganov/ggwave --recursive
cd ggwave && mkdir build && cd build
cmake ..
cd ggwave

# 2. Configure (Enable Python bindings)
cmake . -DGGWAVE_SUPPORT_PYTHON=ON

# 3. Build everything
make

# running
./bin/ggwave-cli
# 4. Install to system path
sudo make install
```

> [!IMPORTANT]
> **Permissions Note:** Always run `make` as a normal user first. If you run `sudo make install` before the build is finished, it may attempt to compile the Python bindings as root, which will fail to find your local `cython` installation and may corrupt file permissions in the repository. If this happens, run `sudo chown $USER:$USER -R .` to restore ownership.

This will install the following tools to `/usr/local/bin`:
- `ggwave-cli`: Interactive or piped command line tool for sending/receiving data.
- `ggwave-to-file`: Encode text into a WAV file.
- `ggwave-from-file`: Decode text from a WAV file.
- `waver`: GUI application for data exchange.

**Example CLI usage:**
```bash
# Interactive mode
ggwave-cli

# One-off transmission via pipe (auto-exits when done)
echo "All is done" | ggwave-cli
```

#### Local Debian packages

Build reproducible `libggwave-dev` and `python3-ggwave` Debian packages:
```bash
# Fetch source
git clone https://github.com/ggerganov/ggwave --recursive
cd ggwave

# Configure
cmake . -DGGWAVE_BUILD_EXAMPLES=OFF -DCMAKE_BUILD_TYPE=Release

# Build
make deb

# Install
sudo dpkg -i dist/*.deb
```

### Python

You can install `ggwave` directly from PyPI or build it from source.

#### From PyPI (Standard User / Termux)
This is the easiest method for consumers. It works out of the box on most platforms:
```bash
pip install ggwave
```

More info: https://pypi.org/project/ggwave/

#### From Source (Developer / Git Repo)
When building from the Git repository, you must manually sync the core C++ sources and handle build-time dependencies. Use `--no-build-isolation` to ensure your local `cython` and `cogapp` installations are used:

```bash
cd bindings/python
make ggwave # Syncs core C++ headers and source files
pip install . --user --no-build-isolation
```

**Note on Cog:** If you have the Replicate `cog` CLI installed, the build system will automatically prefer `python3 -m cogapp` to avoid name collisions.

### Emscripten

```bash
Expand All @@ -187,14 +226,6 @@ emcmake cmake ..
make
```

### Python

```bash
pip install ggwave
```

More info: https://pypi.org/project/ggwave/

### Node.js

```bash
Expand Down
91 changes: 61 additions & 30 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -135,48 +135,87 @@ Other projects using **ggwave** or one of its prototypes:

## Building

### Dependencies for SDL-based examples
### Prerequisites

[Ubuntu]
$ sudo apt install libsdl2-dev
To build all tools and bindings, ensure you have the necessary dependencies installed:

[Mac OS with brew]
$ brew install sdl2
```bash
# [Ubuntu/Debian]
sudo apt install cmake make build-essential libsdl2-dev python3-dev python3-pip

# [Python Tools]
pip install cython cogapp --user
```

[MSYS2]
$ pacman -S git cmake make mingw-w64-x86_64-dlfcn mingw-w64-x86_64-gcc mingw-w64-x86_64-SDL2
### Standard Build & Install (Linux, Mac, Windows MSYS2)

### Linux, Mac, Windows (MSYS2)
The recommended way to build and install `ggwave` is using CMake. This will build the core library, CLI tools, and the Python bindings.

```bash
# build
# 1. Clone the repository
git clone https://github.com/ggerganov/ggwave --recursive
cd ggwave && mkdir build && cd build
cmake ..
cd ggwave

# 2. Configure (Enable Python bindings)
cmake . -DGGWAVE_SUPPORT_PYTHON=ON

# 3. Build everything
make

# running
./bin/ggwave-cli
# 4. Install to system path
sudo make install
```

> [!IMPORTANT]
> **Permissions Note:** Always run `make` as a normal user first. If you run `sudo make install` before the build is finished, it may attempt to compile the Python bindings as root, which will fail to find your local `cython` installation and may corrupt file permissions in the repository. If this happens, run `sudo chown $USER:$USER -R .` to restore ownership.

This will install the following tools to `/usr/local/bin`:
- `ggwave-cli`: Interactive or piped command line tool for sending/receiving data.
- `ggwave-to-file`: Encode text into a WAV file.
- `ggwave-from-file`: Decode text from a WAV file.
- `waver`: GUI application for data exchange.

**Example CLI usage:**
```bash
# Interactive mode
ggwave-cli

# One-off transmission via pipe (auto-exits when done)
echo "All is done" | ggwave-cli
```

#### Local Debian packages

Build reproducible `libggwave-dev` and `python3-ggwave` Debian packages:
```bash
# Fetch source
git clone https://github.com/ggerganov/ggwave --recursive
cd ggwave

# Configure
cmake . -DGGWAVE_BUILD_EXAMPLES=OFF -DCMAKE_BUILD_TYPE=Release

# Build
make deb

# Install
sudo dpkg -i dist/*.deb
```

### Python

You can install `ggwave` directly from PyPI or build it from source.

#### From PyPI (Standard User / Termux)
This is the easiest method for consumers. It works out of the box on most platforms:
```bash
pip install ggwave
```

More info: https://pypi.org/project/ggwave/

#### From Source (Developer / Git Repo)
When building from the Git repository, you must manually sync the core C++ sources and handle build-time dependencies. Use `--no-build-isolation` to ensure your local `cython` and `cogapp` installations are used:

```bash
cd bindings/python
make ggwave # Syncs core C++ headers and source files
pip install . --user --no-build-isolation
```

**Note on Cog:** If you have the Replicate `cog` CLI installed, the build system will automatically prefer `python3 -m cogapp` to avoid name collisions.

### Emscripten

```bash
Expand All @@ -187,14 +226,6 @@ emcmake cmake ..
make
```

### Python

```bash
pip install ggwave
```

More info: https://pypi.org/project/ggwave/

### Node.js

```bash
Expand Down
4 changes: 2 additions & 2 deletions bindings/python/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ DEB_BUILD_DIR := $(DEST)$(PKG_NAME)-$(VERSION)
DEB_VER := 0
DEB := python3-$(PKG_NAME)_$(VERSION)-$(DEB_VER)_$(ARCH).deb
SOURCE_DATE_EPOCH := $(shell git log -1 --pretty=%ct)
SOURCE_PKG_CMD := python -m build --sdist
SOURCE_PKG_CMD := python3 -m build --sdist
DEB_BUILD_CMD := dpkg-buildpackage -rfakeroot -uc -us
COGAPP ?= $(shell which cog || which cogapp)
COGAPP ?= $(shell python3 -m cogapp --help > /dev/null 2>&1 && echo "python3 -m cogapp" || which cogapp || which cog)

.PHONY:
ggwave:
Expand Down
Loading