Skip to content

Commit

Permalink
Merge branch 'master' into FreeBSD-patches
Browse files Browse the repository at this point in the history
  • Loading branch information
michaeldsmith authored Jun 7, 2024
2 parents 86cc31e + 0b32a00 commit 772e162
Show file tree
Hide file tree
Showing 23 changed files with 201 additions and 98 deletions.
12 changes: 12 additions & 0 deletions .github/workflows/docker_linuxes.yml
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,18 @@ jobs:
- name: Run ctlrender within the Docker image
run: docker run ctl:latest sh -c "ctlrender -ctl /usr/src/aces-dev/transforms/ctl/utilities/ACESutil.Unity.ctl /usr/src/aces-dev/images/ACES/SonyF35.StillLife.exr /tmp/testout.exr"

ubuntu-22-04-LTO:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- name: Build the Docker image
run: docker build --no-cache --rm -f ./docker/Dockerfile_ubuntu_22.04_LTO -t ctl:latest .

- name: Run unit tests (ctest) within the Docker image
run: docker run ctl:latest sh -c "cd ./build && ctest"

ubuntu-23-10:

runs-on: ubuntu-latest
Expand Down
28 changes: 14 additions & 14 deletions .github/workflows/mac_debug.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ jobs:

steps:

- name: uninstall openexr
run: brew uninstall --ignore-dependencies openexr
# - name: uninstall openexr
# run: brew uninstall --ignore-dependencies openexr

- name: uninstall imath
run: brew uninstall --ignore-dependencies imath
# - name: uninstall imath
# run: brew uninstall --ignore-dependencies imath

- name: install dependencies - openexr v2.5
run: |
Expand All @@ -38,7 +38,7 @@ jobs:
cd build &&
cmake .. &&
make &&
make install
sudo make install
- uses: actions/checkout@v3

Expand All @@ -65,7 +65,7 @@ jobs:
cd build &&
cmake .. &&
make &&
make install
sudo make install
- name: install dependencies - openexr v3.1
run: |
Expand All @@ -77,7 +77,7 @@ jobs:
cd build &&
cmake .. &&
make &&
make install
sudo make install
- uses: actions/checkout@v3

Expand All @@ -96,11 +96,11 @@ jobs:

steps:

- name: uninstall openexr
run: brew uninstall --ignore-dependencies openexr
# - name: uninstall openexr
# run: brew uninstall --ignore-dependencies openexr

- name: uninstall imath
run: brew uninstall --ignore-dependencies imath
# - name: uninstall imath
# run: brew uninstall --ignore-dependencies imath

- name: install dependencies - openexr v2.5
run: |
Expand All @@ -112,7 +112,7 @@ jobs:
cd build &&
cmake .. &&
make &&
make install
sudo make install
- uses: actions/checkout@v3

Expand Down Expand Up @@ -145,7 +145,7 @@ jobs:
cd build &&
cmake .. &&
make &&
make install
sudo make install
- name: install dependencies - openexr v3.1
run: |
Expand All @@ -157,7 +157,7 @@ jobs:
cd build &&
cmake .. &&
make &&
make install
sudo make install
- uses: actions/checkout@v3

Expand Down
44 changes: 22 additions & 22 deletions .github/workflows/mac_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,11 @@ jobs:

steps:

- name: uninstall openexr
run: brew uninstall --ignore-dependencies openexr
# - name: uninstall openexr
# run: brew uninstall --ignore-dependencies openexr

- name: uninstall imath
run: brew uninstall --ignore-dependencies imath
# - name: uninstall imath
# run: brew uninstall --ignore-dependencies imath

- name: install dependencies - openexr v2.5
run: |
Expand All @@ -64,7 +64,7 @@ jobs:
cd build &&
cmake .. &&
make &&
make install
sudo make install
- uses: actions/checkout@v3

Expand All @@ -91,7 +91,7 @@ jobs:
cd build &&
cmake .. &&
make &&
make install
sudo make install
- name: install dependencies - openexr v3.1
run: |
Expand All @@ -103,7 +103,7 @@ jobs:
cd build &&
cmake .. &&
make &&
make install
sudo make install
- uses: actions/checkout@v3

Expand All @@ -130,7 +130,7 @@ jobs:
cd build &&
cmake -DBUILD_SHARED_LIBS=OFF .. &&
make &&
make install
sudo make install
- name: install dependencies - openexr v3.1
run: |
Expand All @@ -142,7 +142,7 @@ jobs:
cd build &&
cmake -DBUILD_SHARED_LIBS=OFF .. &&
make &&
make install
sudo make install
- uses: actions/checkout@v3

Expand All @@ -169,7 +169,7 @@ jobs:
cd build &&
cmake -DBUILD_SHARED_LIBS=ON .. &&
make &&
make install
sudo make install
- name: install dependencies - openexr v3.1
run: |
Expand All @@ -181,7 +181,7 @@ jobs:
cd build &&
cmake -DBUILD_SHARED_LIBS=ON .. &&
make &&
make install
sudo make install
- uses: actions/checkout@v3

Expand Down Expand Up @@ -232,11 +232,11 @@ jobs:

steps:

- name: uninstall openexr
run: brew uninstall --ignore-dependencies openexr
# - name: uninstall openexr
# run: brew uninstall --ignore-dependencies openexr

- name: uninstall imath
run: brew uninstall --ignore-dependencies imath
# - name: uninstall imath
# run: brew uninstall --ignore-dependencies imath

- name: install dependencies - openexr v2.5
run: |
Expand All @@ -248,7 +248,7 @@ jobs:
cd build &&
cmake .. &&
make &&
make install
sudo make install
- uses: actions/checkout@v3

Expand Down Expand Up @@ -281,7 +281,7 @@ jobs:
cd build &&
cmake .. &&
make &&
make install
sudo make install
- name: install dependencies - openexr v3.1
run: |
Expand All @@ -293,7 +293,7 @@ jobs:
cd build &&
cmake .. &&
make &&
make install
sudo make install
- uses: actions/checkout@v3

Expand Down Expand Up @@ -326,7 +326,7 @@ jobs:
cd build &&
cmake -DBUILD_SHARED_LIBS=OFF .. &&
make &&
make install
sudo make install
- name: install dependencies - openexr v3.1
run: |
Expand All @@ -338,7 +338,7 @@ jobs:
cd build &&
cmake -DBUILD_SHARED_LIBS=OFF .. &&
make &&
make install
sudo make install
- uses: actions/checkout@v3

Expand Down Expand Up @@ -371,7 +371,7 @@ jobs:
cd build &&
cmake -DBUILD_SHARED_LIBS=ON .. &&
make &&
make install
sudo make install
- name: install dependencies - openexr v3.1
run: |
Expand All @@ -383,7 +383,7 @@ jobs:
cd build &&
cmake -DBUILD_SHARED_LIBS=ON .. &&
make &&
make install
sudo make install
- uses: actions/checkout@v3

Expand Down
6 changes: 5 additions & 1 deletion .github/workflows/ubuntu_debug.yml
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,8 @@ jobs:
runs-on: ubuntu-latest

steps:
- name: run apt-get update
run: sudo apt-get -y update

- name: install test tool - valgrind
run: sudo apt-get -y install valgrind
Expand Down Expand Up @@ -237,7 +239,9 @@ jobs:
runs-on: ubuntu-latest

steps:

- name: run apt-get update
run: sudo apt-get -y update

- name: install test tool - valgrind
run: sudo apt-get -y install valgrind

Expand Down
6 changes: 5 additions & 1 deletion .github/workflows/ubuntu_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -256,6 +256,8 @@ jobs:
runs-on: ubuntu-latest

steps:
- name: run apt-get update
run: sudo apt-get -y update

- name: install test tool - valgrind
run: sudo apt-get -y install valgrind
Expand Down Expand Up @@ -306,7 +308,9 @@ jobs:
runs-on: ubuntu-latest

steps:

- name: run apt-get update
run: sudo apt-get -y update

- name: install test tool - valgrind
run: sudo apt-get -y install valgrind

Expand Down
43 changes: 3 additions & 40 deletions .github/workflows/windows_vcpkg_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,43 +52,6 @@ jobs:
run: cmake --build ${{github.workspace}}/build --target install --config ${{env.BUILD_TYPE}}
working-directory: ${{github.workspace}}

test:
# The CMake configure and build commands are platform agnostic and should work equally well on Windows or Mac.
# You can convert this to a matrix build if you need cross-platform coverage.
# See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
runs-on: windows-latest

steps:

- name: install dependencies - imath
run: vcpkg install imath:x64-windows

- name: install dependencies - openexr
run: vcpkg install openexr:x64-windows

- name: install dependencies - tiff
run: vcpkg install tiff:x64-windows

- name: check vcpkg install status
run: vcpkg list

- uses: actions/checkout@v3

- name: Configure CMake
# # Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make.
# # See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type
run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -D "CMAKE_TOOLCHAIN_FILE=C:/vcpkg/scripts/buildsystems/vcpkg.cmake"

- name: Build
# Build your program with the given configuration
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}

- name: Install
# Build your program with the given configuration
run: cmake --build ${{github.workspace}}/build --target install --config ${{env.BUILD_TYPE}}
working-directory: ${{github.workspace}}

- name: Test
working-directory: ${{github.workspace}}/build
run: ctest -V --output-on-failure -C ${{env.BUILD_TYPE}}

# - name: Test
# working-directory: ${{github.workspace}}/build
# run: ctest -V --output-on-failure -C ${{env.BUILD_TYPE}}
1 change: 1 addition & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ RUN apt-get -y install libtiff-dev
WORKDIR /usr/src/CTL
COPY . .
WORKDIR /usr/src/CTL/build
RUN rm -R * || true
RUN cmake ..
RUN make
RUN make install
Expand Down
1 change: 1 addition & 0 deletions Dockerfile_openexr3
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ RUN apt-get -y install libtiff-dev
WORKDIR /usr/src/CTL
COPY . .
WORKDIR /usr/src/CTL/build
RUN rm -R * || true
RUN cmake ..
RUN make
RUN make install
Expand Down
2 changes: 1 addition & 1 deletion ctlrender/tiff_file.cc
Original file line number Diff line number Diff line change
Expand Up @@ -486,7 +486,7 @@ void tiff_read_failsafe(TIFF *t, float scale, ctl::dpx::fb<float> *pixels) {
pixels->init(w, h, 4);

temp_buffer=(uint8_t *)alloca(w*h*4);
TIFFReadRGBAImage(t, w, h, (uint32 *)temp_buffer, 0);
TIFFReadRGBAImage(t, w, h, (uint32_t *)temp_buffer, 0);

for(i=0; i<h; i++) {
flip=temp_buffer+sizeof(uint32_t)*w*(h-i-1);
Expand Down
2 changes: 1 addition & 1 deletion ctlrender/transform.cc
Original file line number Diff line number Diff line change
Expand Up @@ -394,7 +394,7 @@ void run_ctl_transform(const ctl_operation_t &ctl_operation, CTLResults *ctl_res
}
} catch (...) {
char message_text[512] = {'\0'};
sprintf( message_text, "CTL file must contain either a main or <module_name> (%s) function", module);
snprintf( message_text, 512, "CTL file must contain either a main or <module_name> (%s) function", module);
THROW(Iex::ArgExc, message_text);
}

Expand Down
Loading

0 comments on commit 772e162

Please sign in to comment.