Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 2 additions & 2 deletions .github/workflows/frequent_check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,12 +91,12 @@ jobs:
- name: Set up Python
uses: actions/setup-python@v5 # https://github.com/marketplace/actions/setup-python
with:
python-version: '3.7'
python-version: '3.9'
- name: configure
run: |
mkdir target-Release
cd target-Release
cmake .. -DCMAKE_INSTALL_PREFIX=install${{ matrix.os }}CMake-Github -DPYTHON_VERSION=3.7
cmake .. -DCMAKE_INSTALL_PREFIX=install${{ matrix.os }}CMake-Github -DPYTHON_VERSION=3.9
- name: make
run: |
cd target-Release
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -94,12 +94,12 @@ jobs:
- name: Set up Python
uses: actions/setup-python@v5 # https://github.com/marketplace/actions/setup-python
with:
python-version: '3.7'
python-version: '3.9'
- name: configure
run: |
mkdir target-Release
cd target-Release
cmake -DCMAKE_INSTALL_PREFIX=install${{ matrix.os }}CMake-Github -DPYTHON_VERSION=3.7 ..
cmake -DCMAKE_INSTALL_PREFIX=install${{ matrix.os }}CMake-Github -DPYTHON_VERSION=3.9 ..
- name: make
run: |
cd target-Release
Expand Down
4 changes: 4 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,10 @@ if (${CMAKE_PROJECT_NAME} STREQUAL nitro)
elseif (UNIX)
add_compile_options(-Werror) # warnings as errors

if (CMAKE_COMPILER_IS_GNUCC AND CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 10.0)
add_compile_options(-Wno-error=c++20-compat -Wno-error=format-truncation)
endif()

if (ENABLE_ASAN)
# https://gcc.gnu.org/onlinedocs/gcc/Instrumentation-Options.html
add_compile_options(-fsanitize=address)
Expand Down
4 changes: 2 additions & 2 deletions modules/python/nitf/samples/nitf_extract.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"""

from nitf import *
import os, sys, logging, glob
import os, sys, logging, glob, uuid

logging.basicConfig(level=logging.INFO, stream=sys.stdout,
format='%(asctime)s %(levelname)s %(message)s')
Expand All @@ -40,7 +40,7 @@ def extract_image(subheader, index, imageReader, outDir=None, baseName=None):
bandData = imageReader.read(window)

if not outDir: outDir = os.getcwd()
if not baseName: baseName = os.path.basename(os.tempnam())
if not baseName: baseName = os.path.basename(uuid.uuid4().hex)

outNames = []
for band, data in enumerate(bandData):
Expand Down
4 changes: 2 additions & 2 deletions modules/python/nitf/samples/test_image.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"""

from nitf import *
import os, sys, logging, glob
import os, sys, logging, glob, uuid
from PIL import Image

logging.basicConfig(level=logging.INFO, stream=sys.stdout,
Expand All @@ -41,7 +41,7 @@ def dump_image(subheader, index, imageReader, outDir=None, baseName=None):
bandData = imageReader.read(window)

if not outDir: outDir = os.getcwd()
if not baseName: baseName = os.path.basename(os.tempnam())
if not baseName: baseName = os.path.basename(uuid.uuid4().hex)

outNames = []
for band, data in enumerate(bandData):
Expand Down