diff --git a/.gitignore b/.gitignore deleted file mode 100644 index 9f3ddfd..0000000 --- a/.gitignore +++ /dev/null @@ -1,6 +0,0 @@ -/fcct-0.5.0.tar.gz -/fcct-0.6.0.tar.gz -/fcct-0.7.0.tar.gz -/fcct-0.8.0.tar.gz -/fcct-0.9.0.tar.gz -/fcct-0.10.0.tar.gz diff --git a/README.md b/README.md deleted file mode 100644 index 71db9d7..0000000 --- a/README.md +++ /dev/null @@ -1,3 +0,0 @@ -# fedora-coreos-config-transpiler - -Fedora CoreOS Config Transpiler \ No newline at end of file diff --git a/dead.package b/dead.package new file mode 100644 index 0000000..67e9ad8 --- /dev/null +++ b/dead.package @@ -0,0 +1 @@ +Renamed to butane diff --git a/fedora-coreos-config-transpiler.spec b/fedora-coreos-config-transpiler.spec deleted file mode 100644 index 3e1cca5..0000000 --- a/fedora-coreos-config-transpiler.spec +++ /dev/null @@ -1,161 +0,0 @@ -# Generated by go2rpm 1 -# Manually modified for fcct 0.5.0 -%bcond_without check - -# https://github.com/coreos/fcct -%global goipath github.com/coreos/fcct -Version: 0.10.0 - -%gometa - -%global common_description %{expand:The Fedora CoreOS Config Transpiler (FCCT) translates human-readable -Fedora CoreOS Configs (FCCs) into machine-readable Ignition configs -for provisioning Fedora CoreOS machines.} - -%global golicenses LICENSE -%global godocs docs README.md NEWS - -Name: fedora-coreos-config-transpiler -Release: 1%{?dist} -Summary: Fedora CoreOS Config Transpiler (FCCT) - -# Upstream license specification: Apache-2.0 -License: ASL 2.0 -URL: %{gourl} -Source0: %{gosource} - -# Users may know FCCT by its acronym and want to `dnf install fcct` -Provides: fcct = %{version}-%{release} - -# Generated by go-mods-to-bundled-provides.py -Provides: bundled(golang(github.com/clarketm/json)) = 1.14.1 -Provides: bundled(golang(github.com/coreos/go-semver/semver)) = 0.3.0 -Provides: bundled(golang(github.com/coreos/go-systemd/unit)) = 0.0.0-20190321100706.git95778dfbb74e -Provides: bundled(golang(github.com/coreos/go-systemd/v22/unit)) = 0.0.0-20190321100706.git95778dfbb74e -Provides: bundled(golang(github.com/coreos/ignition/v2/config/merge)) = 2.8.1 -Provides: bundled(golang(github.com/coreos/ignition/v2/config/shared/errors)) = 2.8.1 -Provides: bundled(golang(github.com/coreos/ignition/v2/config/shared/validations)) = 2.8.1 -Provides: bundled(golang(github.com/coreos/ignition/v2/config/util)) = 2.8.1 -Provides: bundled(golang(github.com/coreos/ignition/v2/config/v3_0/types)) = 2.8.1 -Provides: bundled(golang(github.com/coreos/ignition/v2/config/v3_1/types)) = 2.8.1 -Provides: bundled(golang(github.com/coreos/ignition/v2/config/v3_2/types)) = 2.8.1 -Provides: bundled(golang(github.com/coreos/ignition/v2/config/v3_3_experimental/types)) = 2.8.1 -Provides: bundled(golang(github.com/coreos/ignition/v2/config/validate)) = 2.8.1 -Provides: bundled(golang(github.com/coreos/vcontext/json)) = 0.0.0-20201120045928.gitb0e13dab675c -Provides: bundled(golang(github.com/coreos/vcontext/path)) = 0.0.0-20201120045928.gitb0e13dab675c -Provides: bundled(golang(github.com/coreos/vcontext/report)) = 0.0.0-20201120045928.gitb0e13dab675c -Provides: bundled(golang(github.com/coreos/vcontext/tree)) = 0.0.0-20201120045928.gitb0e13dab675c -Provides: bundled(golang(github.com/coreos/vcontext/validate)) = 0.0.0-20201120045928.gitb0e13dab675c -Provides: bundled(golang(github.com/coreos/vcontext/yaml)) = 0.0.0-20201120045928.gitb0e13dab675c -Provides: bundled(golang(github.com/davecgh/go-spew/spew)) = 1.1.1 -Provides: bundled(golang(github.com/spf13/pflag)) = 1.0.5 -Provides: bundled(golang(github.com/stretchr/testify/assert)) = 1.5.1 -Provides: bundled(golang(github.com/vincent-petithory/dataurl)) = 0.0.0-20160330182126.git9a301d65acbb -Provides: bundled(golang(gopkg.in/yaml.v3)) = 3.0.0-20191010095647.gitfc94e3f71652 - -%description -%{common_description} - -%gopkg - -%package nonlinux -Summary: Fedora CoreOS Config Transpiler for macOS and Windows -License: ASL 2.0 -BuildArch: noarch - -%description nonlinux -%{common_description} - -This package contains macOS and Windows fcct binaries built through -cross-compilation. Do not install it. It is only used for building release -binaries to be signed by Fedora release engineering and uploaded to the -FCCT GitHub releases page. - -%prep -%goprep -k -# With GO111MODULE=off, as set by %%gobuild, `go build` can't find the pflag -# package in the vendor directory. strace shows that it doesn't even look -# in vendor/. This doesn't happen with other dependencies, and I have no -# explanation. Hack around it by explicitly including pflag in the GOPATH. -mkdir -p %gobuilddir/src/github.com/spf13 -ln -s ../../../../vendor/github.com/spf13/pflag %gobuilddir/src/github.com/spf13/pflag - -%build -export LDFLAGS="-X github.com/coreos/fcct/internal/version.Raw=%{version} " -export GOFLAGS="-mod=vendor" - -echo "Building fcct..." -%gobuild -o ./fcct internal/main.go - -%global gocrossbuild go build -ldflags "${LDFLAGS:-} -B 0x$(head -c20 /dev/urandom|od -An -tx1|tr -d ' \\n')" -a -v -x - -echo "Building macOS fcct..." -GOARCH=amd64 GOOS=darwin %gocrossbuild -o fcct-x86_64-apple-darwin internal/main.go - -echo "Building Windows fcct..." -GOARCH=amd64 GOOS=windows %gocrossbuild -o fcct-x86_64-pc-windows-gnu.exe internal/main.go - -%install -install -d -p %{buildroot}%{_bindir} -install -p -m 0755 ./fcct %{buildroot}%{_bindir} -install -d -p %{buildroot}%{_datadir}/fcct -install -p -m 0644 ./fcct-x86_64-apple-darwin %{buildroot}%{_datadir}/fcct -install -p -m 0644 ./fcct-x86_64-pc-windows-gnu.exe %{buildroot}%{_datadir}/fcct - -%if %{with check} -%check -%gocheck -%endif - -%files -%license %{golicenses} -%doc %{godocs} -%{_bindir}/fcct - -%files nonlinux -%license %{golicenses} -%dir %{_datadir}/fcct -%{_datadir}/fcct/fcct-x86_64-apple-darwin -%{_datadir}/fcct/fcct-x86_64-pc-windows-gnu.exe - -%changelog -* Mon Feb 01 2021 Benjamin Gilbert - 0.10.0-1 -- New release - -* Tue Jan 26 2021 Fedora Release Engineering - 0.9.0-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild - -* Wed Jan 06 2021 Sohan Kunkerkar - 0.9.0-1 -- New release - -* Fri Dec 04 2020 Sohan Kunkerkar - 0.8.0-1 -- New release - -* Fri Oct 23 2020 Stephen Lowrie - 0.7.0-1 -- New release - -* Mon Jul 27 2020 Fedora Release Engineering - 0.6.0-2 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild - -* Fri May 29 2020 Benjamin Gilbert - 0.6.0-1 -- New release - -* Mon Mar 23 2020 Benjamin Gilbert - 0.5.0-1 -- New release - -* Wed Feb 05 2020 James Cassell - 0.4.0-5 -- Include "FCCT" in the Summary to enable discovery by 'dnf search' - -* Tue Feb 04 2020 Benjamin Gilbert - 0.4.0-4 -- Provide "fcct" to aid installation -- Minor improvement to -nonlinux description - -* Sat Feb 01 2020 Benjamin Gilbert - 0.4.0-3 -- Avoid incorrect separate noarch build in koji -- Re-enable noarch package check; it was the wrong fix - -* Fri Jan 31 2020 Benjamin Gilbert - 0.4.0-2 -- Disable noarch package check that was failing the build - -* Thu Jan 30 2020 Benjamin Gilbert - 0.4.0-1 -- Initial package diff --git a/go-mods-to-bundled-provides.py b/go-mods-to-bundled-provides.py deleted file mode 100755 index 3de621a..0000000 --- a/go-mods-to-bundled-provides.py +++ /dev/null @@ -1,84 +0,0 @@ -#!/usr/bin/env python3 - -''' - Tiny dumb script that generates virtual bundled `Provides` from a repo that - uses go modules and vendoring. -''' - -import sys -import re - - -def main(): - repos = get_repos_from_go_mod() - print_provides_from_modules_txt(repos) - - -def get_repos_from_go_mod(): - repos = {} - in_reqs = False - for line in open('go.mod'): - line = line.strip() - if in_reqs and line.startswith(')'): - break - if not in_reqs: - if line.startswith('require ('): - in_reqs = True - continue - req = line.split() - - repo = req[0] - tag = req[1] - - repos[repo] = go_mod_tag_to_rpm_provides_version(tag) - - return repos - - -def go_mod_tag_to_rpm_provides_version(tag): - - # go.mod tags are either exact git tags, or may be "pseudo-versions". We - # want to convert these tags to something resembling a version string that - # RPM won't fail on. For more information, see - # https://golang.org/cmd/go/#hdr-Pseudo_versions and following sections. - - # trim off any +incompatible - if tag.endswith('+incompatible'): - tag = tag[:-len('+incompatible')] - - # git tags are normally of the form v$VERSION - if tag.startswith('v'): - tag = tag[1:] - - # is this a pseudo-version? e.g. v0.0.0-20181031085051-9002847aa142 - m = re.match("(.*)-([0-9]{14})-([a-f0-9]{12})", tag) - if m: - # rpm doesn't like multiple dashes in the version, so just merge the - # timestamp and the commit checksum into the "release" field - tag = f"{m.group(1)}-{m.group(2)}.git{m.group(3)}" - - return tag - - -def print_provides_from_modules_txt(repos): - - for line in open('vendor/modules.txt'): - if line.startswith('#'): - continue - gopkg = line.strip() - repo = lookup_repo_for_pkg(repos, gopkg) - if not repo: - # must be a pkg for tests only; ignore - continue - tag = repos[repo] - print(f"Provides: bundled(golang({gopkg})) = {tag}") - - -def lookup_repo_for_pkg(repos, gopkg): - for repo in repos: - if gopkg.startswith(repo): - return repo - - -if __name__ == '__main__': - sys.exit(main()) diff --git a/sources b/sources deleted file mode 100644 index 089a303..0000000 --- a/sources +++ /dev/null @@ -1 +0,0 @@ -SHA512 (fcct-0.10.0.tar.gz) = 3f2461b254cc8acaf5e13112027dbda062fe19d1ad512c5f8ac38c2c0a0951bf5b8604003433bd9b32e833e88ad2c7124b16e8f3c3f8ac1a1027aa18ae2feb75