--- CMakeLists.txt.orig	2023-11-07 15:25:19 UTC
+++ CMakeLists.txt
@@ -28,6 +28,7 @@ endif()
 
 option(BUILD_TESTS    "Build test suite" OFF)
 option(BUILD_COVERAGE "Build with coverage" OFF)
+option(BUILD_GEN      "Build gen" OFF)
 option(WITH_LUA       "Build with Lua support" ON)
 option(WITH_LUAJIT    "Build with LuaJIT support" OFF)
 
@@ -289,7 +290,6 @@ if (${POTRACE_LIBRARY} STREQUAL "POTRACE_LIBRARY-NOTFO
 else()
     if (WITH_LUA)
         message(STATUS "Found opencv and potrace library. Building osm2pgsql-gen.")
-        set(BUILD_GEN 1)
         include_directories(SYSTEM ${POTRACE_INCLUDE_DIR})
         add_executable(osm2pgsql-gen src/gen/osm2pgsql-gen.cpp
                     src/gen/canvas.cpp
