Skip to content

Commit

Permalink
more recipes
Browse files Browse the repository at this point in the history
  • Loading branch information
anderslanglands committed Jun 22, 2022
1 parent 3e3a7bc commit db670cd
Show file tree
Hide file tree
Showing 45 changed files with 491 additions and 111 deletions.
4 changes: 4 additions & 0 deletions Jinja2/3.1.2/package.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
name = "Jinja2"
version = "3.1.5"

requires = ["python"]
15 changes: 15 additions & 0 deletions MarkupSafe/2.1.1/package.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name = "MarkupSafe"
version = "2.1.1"

requires = ["python"]
variants = [
["platform-windows", "arch-AMD64", "python-3.7"],
["platform-windows", "arch-AMD64", "python-3.9"],
]

build_command = """
python -m pip install --prefix {install_path}
"""

def commands():
env.PYTHONPATH.prepend("{root}/python")
14 changes: 14 additions & 0 deletions MarkupSafe/2.1.1/platform-windows/arch-AMD64/python-3.7/package.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name = "MarkupSafe"
version = "2.1.1"

requires = ["python"]
variants = [
["platform-windows", "arch-AMD64", "python-3.7"],
]

build_command = """
python -m pip install --prefix {install_path}
"""

def commands():
env.PYTHONPATH.prepend("{root}/python")
15 changes: 15 additions & 0 deletions MarkupSafe/2.1.1/platform-windows/arch-AMD64/python-3.9/package.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name = "MarkupSafe"
version = "2.1.1"

requires = ["python"]
variants = [
["platform-windows", "arch-AMD64", "python-3.9"],
]

build_command = """
python -m pip install --prefix {install_path}
"""

def commands():
env.PYTHONPATH.prepend("{root}/python")

18 changes: 3 additions & 15 deletions boost/1.70.0/platform-windows/arch-AMD64/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,23 +14,11 @@
def commands():
env.Boost_ROOT = "{root}"
env.BOOST_ROOT = "{root}"
env.CMAKE_PREFIX_PATH.append('{root}/lib/cmake/Boost-1.70.0')
env.CMAKE_PREFIX_PATH.prepend('{root}/lib/cmake/Boost-1.70.0')
env.PATH.prepend("{root}/lib")

def pre_build_commands():
import os, shutil

def download_file(url, local_dir):
import urllib.request, shutil, os

print(f"Downloading {url}...")
filename = os.path.join(local_dir, os.path.basename(url))
with urllib.request.urlopen(url) as resp, open(filename, "wb") as f:
shutil.copyfileobj(resp, f)
return filename

fn = download_file(
download_and_unpack(
f"https://boostorg.jfrog.io/artifactory/main/release/1.70.0/source/boost_1_70_0.tar.bz2",
os.getcwd(),
)
shutil.unpack_archive(fn)

1 change: 1 addition & 0 deletions boost/1.73.0/platform-windows/arch-AMD64/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ def commands():
env.Boost_ROOT = "{root}"
env.BOOST_ROOT = "{root}"
env.CMAKE_PREFIX_PATH.append('{root}/lib/cmake/Boost-1.73.0')
env.PATH.prepend("{root}/bin")

def pre_build_commands():
import os, shutil
Expand Down
1 change: 1 addition & 0 deletions boost/1.76.0/platform-windows/arch-AMD64/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ def commands():
env.Boost_ROOT = "{root}"
env.BOOST_ROOT = "{root}"
env.CMAKE_PREFIX_PATH.append('{root}/lib/cmake/Boost-1.76.0')
env.PATH.prepend("{root}/bin")

def pre_build_commands():
import os, shutil
Expand Down
1 change: 1 addition & 0 deletions boost/1.79.0/platform-windows/arch-AMD64/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
def commands():
env.Boost_ROOT = "{root}"
env.BOOST_ROOT = "{root}"
env.PATH.prepend("{root}/bin")
env.CMAKE_PREFIX_PATH.append('{root}/lib/cmake/Boost-1.79.0')

def pre_build_commands():
Expand Down
7 changes: 0 additions & 7 deletions ffmpeg/5.0.1/package.py

This file was deleted.

34 changes: 0 additions & 34 deletions ffmpeg/5.0.1/platform-linux/arch-x86_64/package.py

This file was deleted.

17 changes: 17 additions & 0 deletions gif/5.2.1/platform-windows/arch-AMD64/package.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name = "gif"
version = "5.2.1"

build_requires = ["cmake", "vs"]

variants = [["platform-windows", "arch-AMD64"]]


def commands():
env.GIF_ROOT = "{root}"
env.GIF_DIR = "{root}"
env.PATH.prepend("{root}")

build_system = "cmake"

def pre_cook():
fetch_repository("https://gitlab.com/anderslanglands/giflib.git")
5 changes: 5 additions & 0 deletions glew/2.1.0/package.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
name = "glew"
version = "2.1.0"

variants = [["platform-windows", "arch-AMD64"], ["platform-linux", "arch-x86_64"]]

23 changes: 23 additions & 0 deletions glew/2.1.0/platform-windows/arch-AMD64/package.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name = "glew"
version = "2.1.0"

build_requires = ["vs", "cmake"]

variants = [["platform-windows", "arch-AMD64"]]


def commands():
env.GLEW_ROOT = "{root}"
env.CMAKE_PREFIX_PATH.prepend("{root}")
env.PATH.prepend("{root}/bin")


build_command = """
cd {root}/build
mkdir build && cd build
cmake ../cmake -GNinja -DCMAKE_INSTALL_PREFIX={install_path} -DCMAKE_BUILD_TYPE=Release && ninja install
"""


def pre_cook():
download_and_unpack(f"https://github.com/nigels-com/glew/releases/download/glew-{version}/glew-{version}.zip")
2 changes: 1 addition & 1 deletion imath/3.0.5/platform-windows/arch-AMD64/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ def commands():
env.IMATH_HOME = "{root}"
env.IMATH_DIR = "{root}"
env.IMATH_LOCATION = "{root}"
env.PATH.prepend("{root}/bin")
env.CMAKE_PREFIX_PATH.append("{root}/lib/cmake")
env.PATH.append("{root}/bin")


def pre_cook():
Expand Down
2 changes: 1 addition & 1 deletion imath/3.1.5/platform-windows/arch-AMD64/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ def commands():
env.IMATH_HOME = "{root}"
env.IMATH_DIR = "{root}"
env.IMATH_LOCATION = "{root}"
env.PATH.prepend("{root}/bin")
env.CMAKE_PREFIX_PATH.append("{root}/lib/cmake")
env.PATH.append("{root}/bin")


def pre_cook():
Expand Down
1 change: 1 addition & 0 deletions jpegturbo/2.0.6/platform-linux/arch-x86_64/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

def commands():
env.JPEGTurbo_ROOT = "{root}"
env.PKG_CONFIG_PATH.prepend("{root}/lib/pkgconfig")

if building:
env.LDFLAGS.prepend("-L{root}/lib -Wl,-rpath,{root}/lib")
Expand Down
22 changes: 22 additions & 0 deletions jpegturbo/2.0.6/platform-windows/arch-AMD64/package.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name = "jpegturbo"
version = "2.0.6"

build_requires = ["cmake", "vs"]

variants = [["platform-windows", "arch-AMD64"]]


def commands():
env.PATH.prepend("{root}/bin")
env.JPEGTurbo_ROOT = "{root}"
env.PKG_CONFIG_PATH.prepend("{root}/lib/pkgconfig")


def pre_cook():
import os

archive = f"{version}.tar.gz"
download_and_unpack(
f"https://github.com/libjpeg-turbo/libjpeg-turbo/archive/refs/tags/{archive}"
)

7 changes: 4 additions & 3 deletions opencolorio/2.1.2/platform-linux/arch-x86_64/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,10 @@


def commands():
env.PATH.append("{root}/bin")
env.CMAKE_PREFIX_PATH.append("{root}/bin")
env.PYTHNONPATH.append("{root}/lib/site-packages")
env.PATH.prepend("{root}/bin")
env.CMAKE_PREFIX_PATH.prepend("{root}/bin")
env.PYTHNONPATH.prepend("{root}/lib/site-packages")
env.PKG_CONFIG_PATH.prepend("{root}/bin")

if building:
env.LDFLAGS.prepend("-L{root}/lib -Wl,-rpath,{root}/lib")
Expand Down
12 changes: 7 additions & 5 deletions opencolorio/2.1.2/platform-windows/arch-AMD64/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,17 @@


def commands():
env.PATH.append("{root}/bin")
env.PATH.prepend("{root}/bin")
env.CMAKE_PREFIX_PATH.append("{root}/bin")
env.PYTHNONPATH.append("{root}/lib/site-packages")
env.PYTHNONPATH.prepend("{root}/lib/site-packages")


build_args = [
"-DPython_ROOT=$env:Python_ROOT -DPython_EXECUTABLE=$env:Python_EXECUTABLE"
]
cmake_build_system = "ninja"

build_system_args = [
"-DPython_ROOT=$env:Python_ROOT",
"-DPython_EXECUTABLE=$env:Python_EXECUTABLE",
]

def pre_cook():
import os, shutil
Expand Down
2 changes: 1 addition & 1 deletion openexr/3.0.5/platform-windows/arch-AMD64/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ def commands():
env.OPENEXR_DIR = "{root}"
env.OPENEXR_LOCATION = "{root}"
env.CMAKE_PREFIX_PATH.append("{root}/lib/cmake")
env.PATH.append("{root}/bin")
env.PATH.prepend("{root}/bin")


def pre_cook():
Expand Down
4 changes: 2 additions & 2 deletions openexr/3.1.5/platform-windows/arch-AMD64/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
version = "3.1.5"

build_requires = ["cmake"]
requires = ["imath-3.1"]
requires = ["imath-3.1", "zlib-1.2"]

variants = [["platform-windows", "arch-AMD64"]]

Expand All @@ -12,7 +12,7 @@ def commands():
env.OPENEXR_DIR = "{root}"
env.OPENEXR_LOCATION = "{root}"
env.CMAKE_PREFIX_PATH.append("{root}/lib/cmake")
env.PATH.append("{root}/bin")
env.PATH.prepend("{root}/bin")


def pre_cook():
Expand Down
4 changes: 2 additions & 2 deletions openimageio/2.3.16.0/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@
"opencolorio-2.0+<2.2",
"tiff-4.3",
"openjpeg-2.4",
"ptex-2.4",
"jpegturbo-2.0",
"png-1.6",
"raw-0.20",
"raw-0.20+<0.22",
"pugixml-1.11",
"pybind11-2.8",
"webp-1.1",
"zlib-1.2",
"ptex-2.4",
"gif-5.2.1",
]

Expand Down
2 changes: 1 addition & 1 deletion openimageio/2.3.16.0/platform-linux/arch-x86_64/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@
"opencolorio-2.0+<2.2",
"tiff-4.3",
"openjpeg-2.4",
"ptex-2.4",
"jpegturbo-2.0",
"png-1.6",
"raw-0.20",
"pugixml-1.11",
"pybind11-2.8",
"webp-1.1",
"zlib-1.2",
"ptex-2.4",
"gif-5.2.1",
]

Expand Down
42 changes: 42 additions & 0 deletions openimageio/2.3.16.0/platform-windows/arch-AMD64/package.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name = "openimageio"
version = "2.3.16.0"

requires = [
"boost-1.70",
"openexr-3.0+<3.2",
"opencolorio-2.0+<2.2",
"tiff-4.3",
"openjpeg-2.4",
"jpegturbo-2.0",
"png-1.6",
"raw-0.21",
"pugixml-1.11",
"pybind11-2.8",
"webp-1.1",
"zlib-1.2",
"ptex-2.4",
"gif-5.2.1",
]

build_requires = ["cmake", "vs"]

variants = [["platform-windows", "arch-AMD64"]]


def commands():
env.OpenImageIO_ROOT = "{root}"
env.OPENIMAGEIO_HOME = "{root}"
env.OPENIMAGEIO_DIR = "{root}"
env.OPENIMAGEIO_LOCATION = "{root}"
env.CMAKE_PREFIX_PATH.append("{root}")
env.PATH.prepend("{root}/bin")


build_system = "cmake"
# cmake_build_system = "ninja"
child_build_args = ["-DBUILD_DOCS=OFF", "-DOIIO_BUILD_TESTS=OFF"]


def pre_cook():
archive = f"v{version}.tar.gz"
download_and_unpack(f"https://github.com/OpenImageIO/oiio/archive/refs/tags/{archive}")
2 changes: 2 additions & 0 deletions openjpeg/2.4.0/platform-linux/arch-x86_64/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,9 @@
variants = [["platform-linux", "arch-x86_64"]]

def commands():
env.PATH.prepend("{root}/bin")
env.OpenJPEG_ROOT = "{root}"
env.PKG_CONFIG_PATH.prepend("{root}/lib/pkgconfig")

if building:
env.LDFLAGS.prepend("-L{root}/lib -Wl,-rpath,{root}/lib")
Expand Down
Loading

0 comments on commit db670cd

Please sign in to comment.