Merge pull request #9 from msys2/master

rebase to master
This commit is contained in:
Andy Tao
2020-08-20 08:12:57 +08:00
committed by GitHub
122 changed files with 3044 additions and 592 deletions

48
.github/workflows/generate-srcinfo.yml vendored Normal file
View File

@@ -0,0 +1,48 @@
name: generate-srcinfo
on:
push:
branches:
- master
workflow_dispatch:
jobs:
update-srcinfo:
runs-on: windows-latest
defaults:
run:
shell: msys2 {0}
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- uses: msys2/setup-msys2@v2
with:
msystem: MSYS
install: python git mingw-w64-x86_64-toolchain mingw-w64-i686-toolchain
update: true
- run: |
curl --fail -L --retry 5 -o srcinfo.json "https://github.com/$GITHUB_REPOSITORY/releases/download/srcinfo-cache/srcinfo.json"
python ci-generate-srcinfo.py --time-limit 19800 mingw . srcinfo.json
- uses: actions/upload-artifact@v2
with:
name: result
path: srcinfo.json
upload-srcinfo:
needs: update-srcinfo
runs-on: ubuntu-latest
steps:
- uses: actions/download-artifact@v2
with:
name: result
- uses: eine/tip@master
with:
token: ${{ secrets.GITHUB_TOKEN }}
tag: srcinfo-cache
rm: true
files: srcinfo.json

View File

@@ -8,6 +8,7 @@ jobs:
build:
runs-on: windows-latest
strategy:
fail-fast: false
matrix:
include: [
{ msystem: MINGW64, arch: x86_64 },
@@ -30,3 +31,15 @@ jobs:
- name: CI-Build
run: MINGW_INSTALLS=${{ matrix.msystem }} ./ci-build.sh
- name: "Upload binaries"
uses: actions/upload-artifact@v2
with:
name: ${{ matrix.msystem }}-packages
path: artifacts/*.pkg.tar.*
- name: "Upload sources"
uses: actions/upload-artifact@v2
with:
name: sources
path: artifacts/*.src.tar.*

View File

@@ -1,5 +1,7 @@
#!/bin/bash
set -e
# AppVeyor and Drone Continuous Integration for MSYS2
# Author: Renato Silva <br.renatosilva@gmail.com>
# Author: Qian Hong <fracting@gmail.com>
@@ -7,11 +9,13 @@
# Configure
cd "$(dirname "$0")"
source 'ci-library.sh'
deploy_enabled && mkdir artifacts
mkdir artifacts
git_config user.email 'ci@msys2.org'
git_config user.name 'MSYS2 Continuous Integration'
git remote add upstream 'https://github.com/MSYS2/MINGW-packages'
git fetch --quiet upstream
# So that makepkg auto-fetches keys from validpgpkeys
mkdir -p ~/.gnupg && echo -e "keyserver keyserver.ubuntu.com\nkeyserver-options auto-key-retrieve" > ~/.gnupg/gpg.conf
# reduce time required to install packages by disabling pacman's disk space checking
sed -i 's/^CheckSpace/#CheckSpace/g' /etc/pacman.conf
@@ -27,11 +31,11 @@ message 'Building packages' "${packages[@]}"
execute 'Updating system' update_system
execute 'Approving recipe quality' check_recipe_quality
for package in "${packages[@]}"; do
execute 'Building binary' makepkg-mingw --noconfirm --noprogressbar --skippgpcheck --nocheck --syncdeps --rmdeps --cleanbuild
execute 'Building source' makepkg --noconfirm --noprogressbar --skippgpcheck --allsource --config '/etc/makepkg_mingw64.conf'
execute 'Building binary' makepkg-mingw --noconfirm --noprogressbar --nocheck --syncdeps --rmdeps --cleanbuild
execute 'Building source' makepkg --noconfirm --noprogressbar --allsource --config '/etc/makepkg_mingw64.conf'
execute 'Installing' yes:pacman --noprogressbar --upgrade *"${PKGEXT}"
deploy_enabled && mv "${package}"/*"${PKGEXT}" artifacts
deploy_enabled && mv "${package}"/*"${SRCEXT}" artifacts
mv "${package}"/*"${PKGEXT}" artifacts
mv "${package}"/*"${SRCEXT}" artifacts
unset package
done

203
ci-generate-srcinfo.py Normal file
View File

@@ -0,0 +1,203 @@
#!/usr/bin/env python3
# Copyright 2017 Christoph Reiter
#
# Permission is hereby granted, free of charge, to any person obtaining
# a copy of this software and associated documentation files (the
# "Software"), to deal in the Software without restriction, including
# without limitation the rights to use, copy, modify, merge, publish,
# distribute, sublicense, and/or sell copies of the Software, and to
# permit persons to whom the Software is furnished to do so, subject to
# the following conditions:
#
# The above copyright notice and this permission notice shall be included
# in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
# IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
# CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
# TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
# SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE
import sys
import argparse
import os
import json
import shutil
from collections import OrderedDict
import hashlib
import time
import subprocess
from concurrent.futures import ThreadPoolExecutor
from typing import List, Iterator, Tuple, Dict, Optional, Union, Collection
CacheEntry = Dict[str, Union[str, Collection[str]]]
CacheTuple = Tuple[str, CacheEntry]
Cache = Dict[str, CacheEntry]
def normalize_repo(repo: str) -> str:
if repo.endswith(".git"):
repo = repo.rsplit(".", 1)[0]
return repo
def normalize_path(path: str) -> str:
return path.replace("\\", "/")
def get_cache_key(pkgbuild_path: str) -> str:
pkgbuild_path = os.path.abspath(pkgbuild_path)
git_cwd = os.path.dirname(pkgbuild_path)
git_path = os.path.relpath(pkgbuild_path, git_cwd)
h = hashlib.new("SHA1")
with open(pkgbuild_path, "rb") as f:
h.update(f.read())
fileinfo = subprocess.check_output(
["git", "ls-files", "-s", "--full-name", git_path],
cwd=git_cwd).decode("utf-8").strip()
h.update(normalize_path(fileinfo).encode("utf-8"))
repo = subprocess.check_output(
["git", "ls-remote", "--get-url", "origin"],
cwd=git_cwd).decode("utf-8").strip()
repo = normalize_repo(repo)
h.update(repo.encode("utf-8"))
return h.hexdigest()
def get_srcinfo_for_pkgbuild(args: Tuple[str, str]) -> Optional[CacheTuple]:
pkgbuild_path, mode = args
pkgbuild_path = os.path.abspath(pkgbuild_path)
git_cwd = os.path.dirname(pkgbuild_path)
git_path = os.path.relpath(pkgbuild_path, git_cwd)
key = get_cache_key(pkgbuild_path)
bash = shutil.which("bash")
if bash is None:
print("ERROR: bash not found")
return None
print("Parsing %r" % pkgbuild_path)
try:
srcinfos = {}
if mode == "mingw":
for name in ["mingw32", "mingw64"]:
env = os.environ.copy()
env["MINGW_INSTALLS"] = name
srcinfos[name] = subprocess.check_output(
[bash, "/usr/bin/makepkg-mingw",
"--printsrcinfo", "-p", git_path],
cwd=git_cwd,
env=env).decode("utf-8")
else:
srcinfos["msys"] = subprocess.check_output(
[bash, "/usr/bin/makepkg",
"--printsrcinfo", "-p", git_path],
cwd=git_cwd).decode("utf-8")
repo = subprocess.check_output(
["git", "ls-remote", "--get-url", "origin"],
cwd=git_cwd).decode("utf-8").strip()
repo = normalize_repo(repo)
relpath = subprocess.check_output(
["git", "ls-files", "--full-name", git_path],
cwd=git_cwd).decode("utf-8").strip()
relpath = normalize_path(os.path.dirname(relpath))
date = subprocess.check_output(
["git", "log", "-1", "--format=%aI", git_path],
cwd=git_cwd).decode("utf-8").strip()
meta = {"repo": repo, "path": relpath, "date": date, "srcinfo": srcinfos}
except subprocess.CalledProcessError as e:
print("ERROR: %s %s" % (pkgbuild_path, e.output.splitlines()))
return None
return (key, meta)
def iter_pkgbuild_paths(repo_path: str) -> Iterator[str]:
repo_path = os.path.abspath(repo_path)
print("Searching for PKGBUILD files in %s" % repo_path)
for base, dirs, files in os.walk(repo_path):
for f in files:
if f == "PKGBUILD":
# in case we find a PKGBUILD, don't go deeper
del dirs[:]
path = os.path.join(base, f)
yield path
def get_srcinfo_from_cache(args: Tuple[str, Cache]) -> Tuple[str, Optional[CacheTuple]]:
pkgbuild_path, cache = args
key = get_cache_key(pkgbuild_path)
if key in cache:
return (pkgbuild_path, (key, cache[key]))
else:
return (pkgbuild_path, None)
def iter_srcinfo(repo_path: str, mode: str, cache: Cache) -> Iterator[Optional[CacheTuple]]:
with ThreadPoolExecutor() as executor:
to_parse: List[Tuple[str, str]] = []
pool_iter = executor.map(
get_srcinfo_from_cache, ((p, cache) for p in iter_pkgbuild_paths(repo_path)))
for pkgbuild_path, srcinfo in pool_iter:
if srcinfo is not None:
yield srcinfo
else:
to_parse.append((pkgbuild_path, mode))
print("Parsing PKGBUILD files...")
for srcinfo in executor.map(get_srcinfo_for_pkgbuild, to_parse):
yield srcinfo
def main(argv: List[str]) -> Optional[Union[int, str]]:
parser = argparse.ArgumentParser(description="Create SRCINFOs for all packages in a repo", allow_abbrev=False)
parser.add_argument('mode', choices=['msys', 'mingw'], help="The type of the repo")
parser.add_argument("repo_path", help="The path to GIT repo")
parser.add_argument("json_cache", help="The path to the json file used to fetch/store the results")
parser.add_argument("--time-limit", action="store",
type=int, dest="time_limit", default=0,
help='time after which it will stop and save, 0 means no limit')
args = parser.parse_args(argv[1:])
t = time.monotonic()
srcinfo_path = os.path.abspath(args.json_cache)
cache: Cache = {}
try:
with open(srcinfo_path, "rb") as h:
cache = json.loads(h.read())
except FileNotFoundError:
pass
srcinfos = []
for entry in iter_srcinfo(args.repo_path, args.mode, cache):
if entry is None:
continue
srcinfos.append(entry)
# So we stop before CI times out
if args.time_limit and time.monotonic() - t > args.time_limit:
print("time limit reached, stopping")
break
srcinfos_dict = OrderedDict(sorted(srcinfos))
with open(srcinfo_path, "wb") as h:
h.write(json.dumps(srcinfos_dict, indent=2).encode("utf-8"))
return None
if __name__ == "__main__":
sys.exit(main(sys.argv))

View File

@@ -1,7 +1,7 @@
From bacedeb21cd30101b787838d003d686ae3036838 Mon Sep 17 00:00:00 2001
From: Ray Donnelly <mingw.android@gmail.com>
Date: Mon, 23 Feb 2015 21:46:45 +0000
Subject: [PATCH 1/7] lang: Allow both extensions and full filenames
Subject: [PATCH 1/9] lang: Allow both extensions and full filenames
Because many filetypes (e.g. make) are not indicated by the
file extension but instead by the full filename (Makefile).

View File

@@ -1,7 +1,7 @@
From d7dfee733c29dae96984be373db934298d4ac53f Mon Sep 17 00:00:00 2001
From: "K.Takata" <kentkt@csc.jp>
Date: Thu, 1 Jun 2017 22:19:25 +0900
Subject: [PATCH 2/7] win32: Detect Cygwin/MSYS PTY
Subject: [PATCH 2/9] win32: Detect Cygwin/MSYS PTY
When running Win32 version of Ag on mintty or other Cygwin/MSYS terminal
emulators, Ag cannot detect Cygwin/MSYS pty and it causes some problems.

View File

@@ -1,7 +1,7 @@
From ff4e9c3db5b42541494764ad921c80250733e84a Mon Sep 17 00:00:00 2001
From: Ray Donnelly <mingw.android@gmail.com>
Date: Mon, 23 Feb 2015 22:12:15 +0000
Subject: [PATCH 3/7] options: Fix ordering problems with --color
Subject: [PATCH 3/9] options: Fix ordering problems with --color
Moved around the logic of setting opts.color so that:

View File

@@ -1,7 +1,7 @@
From b266b48b70a736927a8ee585fc888f270005973b Mon Sep 17 00:00:00 2001
From: Ray Donnelly <mingw.android@gmail.com>
Date: Mon, 23 Feb 2015 22:16:54 +0000
Subject: [PATCH 4/7] lang: Add autotools (ac, am, in, m4, pc)
Subject: [PATCH 4/9] lang: Add autotools (ac, am, in, m4, pc)
---
src/lang.c | 1 +

View File

@@ -1,7 +1,7 @@
From 1ce3c7f6347a86f210cfa2578444fcb09a5aaa6c Mon Sep 17 00:00:00 2001
From: Ray Donnelly <mingw.android@gmail.com>
Date: Mon, 23 Feb 2015 22:18:27 +0000
Subject: [PATCH 5/7] lang: Add to make (^Makefile, ^Makefile.Debug,
Subject: [PATCH 5/9] lang: Add to make (^Makefile, ^Makefile.Debug,
^Makefile.Release, *.make)
All but one addition are full filename patterns. The

View File

@@ -1,7 +1,7 @@
From add99f2fab7f6015e5a414c33248c3a8b3b20fe6 Mon Sep 17 00:00:00 2001
From: Ray Donnelly <mingw.android@gmail.com>
Date: Mon, 23 Feb 2015 22:21:26 +0000
Subject: [PATCH 6/7] lang: Add makepkg (^PKGBUILD, diff, patch, in, install)
Subject: [PATCH 6/9] lang: Add makepkg (^PKGBUILD, diff, patch, in, install)
Used by the makepkg build system of ArchLinux and MSYS2
---

View File

@@ -1,7 +1,7 @@
From e7ff323818bfd2bbf7d00a885e5a28da9b36f64b Mon Sep 17 00:00:00 2001
From: Ray Donnelly <mingw.android@gmail.com>
Date: Sat, 12 Dec 2015 19:55:47 +0000
Subject: [PATCH 7/7] lang: Add cmake (^CMakeLists.txt, ^CMakeCache.txt ..
Subject: [PATCH 7/9] lang: Add cmake (^CMakeLists.txt, ^CMakeCache.txt ..
.. ^CMakeError.log, ^CMakeOutput.log, cmake)
---

View File

@@ -0,0 +1,211 @@
From 127b82d81ff41cc4ab26695f6c42af2d7443909f Mon Sep 17 00:00:00 2001
From: Shlomi Fish <shlomif@shlomifish.org>
Date: Wed, 15 Apr 2020 20:23:52 +0300
Subject: [PATCH 8/9] Subject: [PATCH 8/9] Fix multiple global symbols
definitions.
See the use of extern here:
* https://www.geeksforgeeks.org/understanding-extern-keyword-in-c/
* https://en.wikipedia.org/wiki/External_variable
*
https://stackoverflow.com/questions/496448/how-to-correctly-use-the-extern-keyword-in-c
---
src/ignore.c | 2 ++
src/ignore.h | 2 +-
src/log.c | 1 +
src/log.h | 2 +-
src/options.c | 2 ++
src/options.h | 2 +-
src/search.c | 13 +++++++++++++
src/search.h | 20 ++++++++++----------
src/util.c | 2 ++
src/util.h | 4 ++--
10 files changed, 35 insertions(+), 15 deletions(-)
diff --git a/src/ignore.c b/src/ignore.c
index fa41889..32464d7 100644
--- a/src/ignore.c
+++ b/src/ignore.c
@@ -20,6 +20,8 @@
const int fnmatch_flags = FNM_PATHNAME;
#endif
+ignores *root_ignores;
+
/* TODO: build a huge-ass list of files we want to ignore by default (build cache stuff, pyc files, etc) */
const char *evil_hardcoded_ignore_files[] = {
diff --git a/src/ignore.h b/src/ignore.h
index 20d5a6a..8db0f37 100644
--- a/src/ignore.h
+++ b/src/ignore.h
@@ -29,7 +29,7 @@ struct ignores {
};
typedef struct ignores ignores;
-ignores *root_ignores;
+extern ignores *root_ignores;
extern const char *evil_hardcoded_ignore_files[];
extern const char *ignore_pattern_files[];
diff --git a/src/log.c b/src/log.c
index 1481b6d..f6f4e9a 100644
--- a/src/log.c
+++ b/src/log.c
@@ -4,6 +4,7 @@
#include "log.h"
#include "util.h"
+pthread_mutex_t print_mtx = PTHREAD_MUTEX_INITIALIZER;
static enum log_level log_threshold = LOG_LEVEL_ERR;
void set_log_level(enum log_level threshold) {
diff --git a/src/log.h b/src/log.h
index 85847ee..318622c 100644
--- a/src/log.h
+++ b/src/log.h
@@ -9,7 +9,7 @@
#include <pthread.h>
#endif
-pthread_mutex_t print_mtx;
+extern pthread_mutex_t print_mtx;
enum log_level {
LOG_LEVEL_DEBUG = 10,
diff --git a/src/options.c b/src/options.c
index a469845..0ff5526 100644
--- a/src/options.c
+++ b/src/options.c
@@ -21,6 +21,8 @@ const char *color_line_number = "\033[1;33m"; /* bold yellow */
const char *color_match = "\033[30;43m"; /* black with yellow background */
const char *color_path = "\033[1;32m"; /* bold green */
+cli_options opts;
+
/* TODO: try to obey out_fd? */
void usage(void) {
printf("\n");
diff --git a/src/options.h b/src/options.h
index 990ce6a..09cd058 100644
--- a/src/options.h
+++ b/src/options.h
@@ -101,7 +101,7 @@ typedef struct {
} cli_options;
/* global options. parse_options gives it sane values, everything else reads from it */
-cli_options opts;
+extern cli_options opts;
typedef struct option option_t;
diff --git a/src/search.c b/src/search.c
index ff5e386..8539bac 100644
--- a/src/search.c
+++ b/src/search.c
@@ -2,6 +2,19 @@
#include "print.h"
#include "scandir.h"
+size_t alpha_skip_lookup[256];
+size_t *find_skip_lookup;
+uint8_t h_table[H_SIZE] __attribute__((aligned(64)));
+
+work_queue_t *work_queue = NULL;
+work_queue_t *work_queue_tail = NULL;
+int done_adding_files = 0;
+pthread_cond_t files_ready = PTHREAD_COND_INITIALIZER;
+pthread_mutex_t stats_mtx = PTHREAD_MUTEX_INITIALIZER;
+pthread_mutex_t work_queue_mtx = PTHREAD_MUTEX_INITIALIZER;
+
+symdir_t *symhash = NULL;
+
void search_buf(const char *buf, const size_t buf_len,
const char *dir_full_path) {
int binary = -1; /* 1 = yes, 0 = no, -1 = don't know */
diff --git a/src/search.h b/src/search.h
index 1071114..a1bc5d7 100644
--- a/src/search.h
+++ b/src/search.h
@@ -31,9 +31,9 @@
#include "uthash.h"
#include "util.h"
-size_t alpha_skip_lookup[256];
-size_t *find_skip_lookup;
-uint8_t h_table[H_SIZE] __attribute__((aligned(64)));
+extern size_t alpha_skip_lookup[256];
+extern size_t *find_skip_lookup;
+extern uint8_t h_table[H_SIZE] __attribute__((aligned(64)));
struct work_queue_t {
char *path;
@@ -41,12 +41,12 @@ struct work_queue_t {
};
typedef struct work_queue_t work_queue_t;
-work_queue_t *work_queue;
-work_queue_t *work_queue_tail;
-int done_adding_files;
-pthread_cond_t files_ready;
-pthread_mutex_t stats_mtx;
-pthread_mutex_t work_queue_mtx;
+extern work_queue_t *work_queue;
+extern work_queue_t *work_queue_tail;
+extern int done_adding_files;
+extern pthread_cond_t files_ready;
+extern pthread_mutex_t stats_mtx;
+extern pthread_mutex_t work_queue_mtx;
/* For symlink loop detection */
@@ -64,7 +64,7 @@ typedef struct {
UT_hash_handle hh;
} symdir_t;
-symdir_t *symhash;
+extern symdir_t *symhash;
void search_buf(const char *buf, const size_t buf_len,
const char *dir_full_path);
diff --git a/src/util.c b/src/util.c
index cb23914..0431148 100644
--- a/src/util.c
+++ b/src/util.c
@@ -21,6 +21,8 @@
} \
return ptr;
+FILE *out_fd = NULL;
+ag_stats stats;
void *ag_malloc(size_t size) {
void *ptr = malloc(size);
CHECK_AND_RETURN(ptr)
diff --git a/src/util.h b/src/util.h
index 0c9b9b1..338b05f 100644
--- a/src/util.h
+++ b/src/util.h
@@ -12,7 +12,7 @@
#include "log.h"
#include "options.h"
-FILE *out_fd;
+extern FILE *out_fd;
#ifndef TRUE
#define TRUE 1
@@ -51,7 +51,7 @@ typedef struct {
} ag_stats;
-ag_stats stats;
+extern ag_stats stats;
/* Union to translate between chars and words without violating strict aliasing */
typedef union {
--
2.27.0

View File

@@ -0,0 +1,26 @@
From 9ded9f120b3961580ea7b08de54d6ee7dcd7b603 Mon Sep 17 00:00:00 2001
From: Yasuhiro Matsumoto <mattn.jp@gmail.com>
Date: Tue, 18 Aug 2020 12:42:13 +0900
Subject: [PATCH 9/9] win32: Use "<NUL" for "git config"
Git for Windows break terminal sequence after git-config.
---
src/options.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/options.c b/src/options.c
index 2145b33..c38f8d3 100644
--- a/src/options.c
+++ b/src/options.c
@@ -698,7 +698,7 @@ void parse_options(int argc, char **argv, char **base_paths[], char **paths[]) {
char *gitconfig_res = NULL;
#ifdef _WIN32
- gitconfig_file = popen("git config -z --path --get core.excludesfile 2>NUL", "r");
+ gitconfig_file = popen("git config -z --path --get core.excludesfile 2>NUL <NUL", "r");
#else
gitconfig_file = popen("git config -z --path --get core.excludesfile 2>/dev/null", "r");
#endif
--
2.27.0

View File

@@ -6,7 +6,7 @@ _longname=the_silver_searcher
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=2.2.0
pkgrel=1
pkgrel=2
pkgdesc="The Silver Searcher: An attempt to make something better than ack, which itself is better than grep (mingw-w64)"
arch=('any')
url="https://geoff.greer.fm/ag"
@@ -24,15 +24,19 @@ source=("${_realname}-${pkgver}.tar.gz"::"https://github.com/ggreer/the_silver_s
"0004-lang-Add-autotools-ac-am-in-m4-pc.patch"
"0005-lang-Add-to-make-Makefile-Makefile.Debug-Makefile.Re.patch"
"0006-lang-Add-makepkg-PKGBUILD-diff-patch-in-install.patch"
"0007-lang-Add-cmake-CMakeLists.txt-CMakeCache.txt.patch")
"0007-lang-Add-cmake-CMakeLists.txt-CMakeCache.txt.patch"
"0008-Fix-multiple-global-symbols-definitions.patch"
"0009-win32-Use-NUL-for-git-config.patch")
sha256sums=('6a0a19ca5e73b2bef9481c29a508d2413ca1a0a9a5a6b1bd9bbd695a7626cbf9'
'9a3c1cc11547219f699e953e05c53b779f396b3d54d1410ae78a62f7550ca7c7'
'45b75b164cb283c4324e27a46c744e0f2df86e4860506e9a4f2c1e98e848f51e'
'63ded2c4bf859faa8dc33cbda89c4bbdb047b014d7b3b4d3f77f9dfb5d1a0ee4'
'3a42e02928f7ae288de69f91c198c6111216f0af23d2de1bc65d8f5e5a28a401'
'fada103d58911e876af36e76675793764c4019e009351d615dede9c3ba7618d1'
'b80e3efd854425e0e5df29cdf585b5132b5ab19e93c06713a4f4f0653bed5f84'
'0659935f2f5e6c38260a603ef696de7e3e5d8dd7f62ec7711b58bd657ab5b511')
'dd33d804a654073acbb78cde1caf7b7c6feea13965f1cfa68588f84f4adcc8ef'
'247a0008a00cbd6c045c6872d61ded1fa455e31faff74ef6932fd4f921681f0d'
'da69609723c4f019f822af81163914f924998575c009836cd2d4ea887acd4977'
'1972392e4762bff91d4e542d478c0a01ddd4dbd507543867aa3b2dd3f159084b'
'a16340cc33cdf95300f353ae87d3af2a0c667987ea9ce9b8c77d3e5c9a8a1007'
'f38d5807ba0486e5004ff86d76a222221a390ac58475c464bc446d4154da8d75'
'88fc3742a0bea4a1f1d533ad4f0b841423930e40639d4a9ea16312eadf21415a'
'ae8cc32f94432b6482a379b0fdfc4095c836f3a947363a101ca69362b5a7f0a1'
'6d98aedccb3c380fe2069373e8b45ddcc8d6c4936cb37da7967a7d5d29557164')
# Helper macros to help make tasks easier #
apply_patch_with_msg() {
@@ -53,7 +57,9 @@ prepare() {
0004-lang-Add-autotools-ac-am-in-m4-pc.patch \
0005-lang-Add-to-make-Makefile-Makefile.Debug-Makefile.Re.patch \
0006-lang-Add-makepkg-PKGBUILD-diff-patch-in-install.patch \
0007-lang-Add-cmake-CMakeLists.txt-CMakeCache.txt.patch
0007-lang-Add-cmake-CMakeLists.txt-CMakeCache.txt.patch \
0008-Fix-multiple-global-symbols-definitions.patch \
0009-win32-Use-NUL-for-git-config.patch
# configure.ac forces -O2, so force it to -O0 if debugging.
if check_option "debug" "y"; then

View File

@@ -0,0 +1,435 @@
diff --git a/binutils/size.c b/binutils/size.c
index 3697087714..f99d45a6bf 100644
--- a/binutils/size.c
+++ b/binutils/size.c
@@ -51,7 +51,8 @@ enum output_format
{
FORMAT_BERKLEY,
FORMAT_SYSV,
- FORMAT_GNU
+ FORMAT_GNU,
+ FORMAT_AVR
};
static enum output_format selected_output_format =
#if BSD_DEFAULT
@@ -74,6 +75,246 @@ static bfd_size_type total_textsize;
/* Program exit status. */
static int return_code = 0;
+
+/* AVR Size specific stuff */
+
+#define AVR64 64UL
+#define AVR128 128UL
+#define AVR256 256UL
+#define AVR512 512UL
+#define AVR1K 1024UL
+#define AVR2K 2048UL
+#define AVR4K 4096UL
+#define AVR8K 8192UL
+#define AVR16K 16384UL
+#define AVR20K 20480UL
+#define AVR24K 24576UL
+#define AVR32K 32768UL
+#define AVR36K 36864UL
+#define AVR40K 40960UL
+#define AVR64K 65536UL
+#define AVR68K 69632UL
+#define AVR128K 131072UL
+#define AVR136K 139264UL
+#define AVR200K 204800UL
+#define AVR256K 262144UL
+#define AVR264K 270336UL
+
+typedef struct
+{
+ char *name;
+ long flash;
+ long ram;
+ long eeprom;
+} avr_device_t;
+
+avr_device_t avr[] =
+{
+ {"atxmega256a3", AVR264K, AVR16K, AVR4K},
+ {"atxmega256a3b", AVR264K, AVR16K, AVR4K},
+ {"atxmega256d3", AVR264K, AVR16K, AVR4K},
+
+ {"atmega2560", AVR256K, AVR8K, AVR4K},
+ {"atmega2561", AVR256K, AVR8K, AVR4K},
+
+ {"atxmega192a3", AVR200K, AVR16K, AVR2K},
+ {"atxmega192d3", AVR200K, AVR16K, AVR2K},
+
+ {"atxmega128a1", AVR136K, AVR8K, AVR2K},
+ {"atxmega128a1u", AVR136K, AVR8K, AVR2K},
+ {"atxmega128a3", AVR136K, AVR8K, AVR2K},
+ {"atxmega128d3", AVR136K, AVR8K, AVR2K},
+
+ {"at43usb320", AVR128K, 608UL, 0UL},
+ {"at90can128", AVR128K, AVR4K, AVR4K},
+ {"at90usb1286", AVR128K, AVR8K, AVR4K},
+ {"at90usb1287", AVR128K, AVR8K, AVR4K},
+ {"atmega128", AVR128K, AVR4K, AVR4K},
+ {"atmega1280", AVR128K, AVR8K, AVR4K},
+ {"atmega1281", AVR128K, AVR8K, AVR4K},
+ {"atmega1284p", AVR128K, AVR16K, AVR4K},
+ {"atmega128rfa1", AVR128K, AVR16K, AVR4K},
+ {"atmega103", AVR128K, 4000UL, AVR4K},
+
+ {"atxmega64a1", AVR68K, AVR4K, AVR2K},
+ {"atxmega64a1u", AVR68K, AVR4K, AVR2K},
+ {"atxmega64a3", AVR68K, AVR4K, AVR2K},
+ {"atxmega64d3", AVR68K, AVR4K, AVR2K},
+
+ {"at90can64", AVR64K, AVR4K, AVR2K},
+ {"at90scr100", AVR64K, AVR4K, AVR2K},
+ {"at90usb646", AVR64K, AVR4K, AVR2K},
+ {"at90usb647", AVR64K, AVR4K, AVR2K},
+ {"atmega64", AVR64K, AVR4K, AVR2K},
+ {"atmega640", AVR64K, AVR8K, AVR4K},
+ {"atmega644", AVR64K, AVR4K, AVR2K},
+ {"atmega644a", AVR64K, AVR4K, AVR2K},
+ {"atmega644p", AVR64K, AVR4K, AVR2K},
+ {"atmega644pa", AVR64K, AVR4K, AVR2K},
+ {"atmega645", AVR64K, AVR4K, AVR2K},
+ {"atmega645a", AVR64K, AVR4K, AVR2K},
+ {"atmega645p", AVR64K, AVR4K, AVR2K},
+ {"atmega6450", AVR64K, AVR4K, AVR2K},
+ {"atmega6450a", AVR64K, AVR4K, AVR2K},
+ {"atmega6450p", AVR64K, AVR4K, AVR2K},
+ {"atmega649", AVR64K, AVR4K, AVR2K},
+ {"atmega649a", AVR64K, AVR4K, AVR2K},
+ {"atmega649p", AVR64K, AVR4K, AVR2K},
+ {"atmega6490", AVR64K, AVR4K, AVR2K},
+ {"atmega6490a", AVR64K, AVR4K, AVR2K},
+ {"atmega6490p", AVR64K, AVR4K, AVR2K},
+ {"atmega64c1", AVR64K, AVR4K, AVR2K},
+ {"atmega64hve", AVR64K, AVR4K, AVR1K},
+ {"atmega64m1", AVR64K, AVR4K, AVR2K},
+ {"m3000", AVR64K, AVR4K, 0UL},
+
+ {"atmega406", AVR40K, AVR2K, AVR512},
+
+ {"atxmega32a4", AVR36K, AVR4K, AVR1K},
+ {"atxmega32d4", AVR36K, AVR4K, AVR1K},
+
+ {"at90can32", AVR32K, AVR2K, AVR1K},
+ {"at94k", AVR32K, AVR4K, 0UL},
+ {"atmega32", AVR32K, AVR2K, AVR1K},
+ {"atmega323", AVR32K, AVR2K, AVR1K},
+ {"atmega324a", AVR32K, AVR2K, AVR1K},
+ {"atmega324p", AVR32K, AVR2K, AVR1K},
+ {"atmega324pa", AVR32K, AVR2K, AVR1K},
+ {"atmega325", AVR32K, AVR2K, AVR1K},
+ {"atmega325a", AVR32K, AVR2K, AVR1K},
+ {"atmega325p", AVR32K, AVR2K, AVR1K},
+ {"atmega3250", AVR32K, AVR2K, AVR1K},
+ {"atmega3250a", AVR32K, AVR2K, AVR1K},
+ {"atmega3250p", AVR32K, AVR2K, AVR1K},
+ {"atmega328", AVR32K, AVR2K, AVR1K},
+ {"atmega328p", AVR32K, AVR2K, AVR1K},
+ {"atmega329", AVR32K, AVR2K, AVR1K},
+ {"atmega329a", AVR32K, AVR2K, AVR1K},
+ {"atmega329p", AVR32K, AVR2K, AVR1K},
+ {"atmega329pa", AVR32K, AVR2K, AVR1K},
+ {"atmega3290", AVR32K, AVR2K, AVR1K},
+ {"atmega3290a", AVR32K, AVR2K, AVR1K},
+ {"atmega3290p", AVR32K, AVR2K, AVR1K},
+ {"atmega32hvb", AVR32K, AVR2K, AVR1K},
+ {"atmega32c1", AVR32K, AVR2K, AVR1K},
+ {"atmega32hvb", AVR32K, AVR2K, AVR1K},
+ {"atmega32m1", AVR32K, AVR2K, AVR1K},
+ {"atmega32u2", AVR32K, AVR1K, AVR1K},
+ {"atmega32u4", AVR32K, 2560UL, AVR1K},
+ {"atmega32u6", AVR32K, 2560UL, AVR1K},
+
+ {"at43usb355", AVR24K, 1120UL, 0UL},
+
+ {"atxmega16a4", AVR20K, AVR2K, AVR1K},
+ {"atxmega16d4", AVR20K, AVR2K, AVR1K},
+
+ {"at76c711", AVR16K, AVR2K, 0UL},
+ {"at90pwm216", AVR16K, AVR1K, AVR512},
+ {"at90pwm316", AVR16K, AVR1K, AVR512},
+ {"at90usb162", AVR16K, AVR512, AVR512},
+ {"atmega16", AVR16K, AVR1K, AVR512},
+ {"atmega16a", AVR16K, AVR1K, AVR512},
+ {"atmega161", AVR16K, AVR1K, AVR512},
+ {"atmega162", AVR16K, AVR1K, AVR512},
+ {"atmega163", AVR16K, AVR1K, AVR512},
+ {"atmega164", AVR16K, AVR1K, AVR512},
+ {"atmega164a", AVR16K, AVR1K, AVR512},
+ {"atmega164p", AVR16K, AVR1K, AVR512},
+ {"atmega165a", AVR16K, AVR1K, AVR512},
+ {"atmega165", AVR16K, AVR1K, AVR512},
+ {"atmega165p", AVR16K, AVR1K, AVR512},
+ {"atmega168", AVR16K, AVR1K, AVR512},
+ {"atmega168a", AVR16K, AVR1K, AVR512},
+ {"atmega168p", AVR16K, AVR1K, AVR512},
+ {"atmega169", AVR16K, AVR1K, AVR512},
+ {"atmega169a", AVR16K, AVR1K, AVR512},
+ {"atmega169p", AVR16K, AVR1K, AVR512},
+ {"atmega169pa", AVR16K, AVR1K, AVR512},
+ {"atmega16hva", AVR16K, 768UL, AVR256},
+ {"atmega16hva2", AVR16K, AVR1K, AVR256},
+ {"atmega16hvb", AVR16K, AVR1K, AVR512},
+ {"atmega16m1", AVR16K, AVR1K, AVR512},
+ {"atmega16u2", AVR16K, AVR512, AVR512},
+ {"atmega16u4", AVR16K, 1280UL, AVR512},
+ {"attiny167", AVR16K, AVR512, AVR512},
+
+ {"at90c8534", AVR8K, 352UL, AVR512},
+ {"at90pwm1", AVR8K, AVR512, AVR512},
+ {"at90pwm2", AVR8K, AVR512, AVR512},
+ {"at90pwm2b", AVR8K, AVR512, AVR512},
+ {"at90pwm3", AVR8K, AVR512, AVR512},
+ {"at90pwm3b", AVR8K, AVR512, AVR512},
+ {"at90pwm81", AVR8K, AVR256, AVR512},
+ {"at90s8515", AVR8K, AVR512, AVR512},
+ {"at90s8535", AVR8K, AVR512, AVR512},
+ {"at90usb82", AVR8K, AVR512, AVR512},
+ {"ata6289", AVR8K, AVR512, 320UL},
+ {"atmega8", AVR8K, AVR1K, AVR512},
+ {"atmega8515", AVR8K, AVR512, AVR512},
+ {"atmega8535", AVR8K, AVR512, AVR512},
+ {"atmega88", AVR8K, AVR1K, AVR512},
+ {"atmega88a", AVR8K, AVR1K, AVR512},
+ {"atmega88p", AVR8K, AVR1K, AVR512},
+ {"atmega88pa", AVR8K, AVR1K, AVR512},
+ {"atmega8hva", AVR8K, 768UL, AVR256},
+ {"atmega8u2", AVR8K, AVR512, AVR512},
+ {"attiny84", AVR8K, AVR512, AVR512},
+ {"attiny84a", AVR8K, AVR512, AVR512},
+ {"attiny85", AVR8K, AVR512, AVR512},
+ {"attiny861", AVR8K, AVR512, AVR512},
+ {"attiny861a", AVR8K, AVR512, AVR512},
+ {"attiny87", AVR8K, AVR512, AVR512},
+ {"attiny88", AVR8K, AVR512, AVR64},
+
+ {"at90s4414", AVR4K, 352UL, AVR256},
+ {"at90s4433", AVR4K, AVR128, AVR256},
+ {"at90s4434", AVR4K, 352UL, AVR256},
+ {"atmega48", AVR4K, AVR512, AVR256},
+ {"atmega48a", AVR4K, AVR512, AVR256},
+ {"atmega48p", AVR4K, AVR512, AVR256},
+ {"attiny4313", AVR4K, AVR256, AVR256},
+ {"attiny43u", AVR4K, AVR256, AVR64},
+ {"attiny44", AVR4K, AVR256, AVR256},
+ {"attiny44a", AVR4K, AVR256, AVR256},
+ {"attiny45", AVR4K, AVR256, AVR256},
+ {"attiny461", AVR4K, AVR256, AVR256},
+ {"attiny461a", AVR4K, AVR256, AVR256},
+ {"attiny48", AVR4K, AVR256, AVR64},
+
+ {"at86rf401", AVR2K, 224UL, AVR128},
+ {"at90s2313", AVR2K, AVR128, AVR128},
+ {"at90s2323", AVR2K, AVR128, AVR128},
+ {"at90s2333", AVR2K, 224UL, AVR128},
+ {"at90s2343", AVR2K, AVR128, AVR128},
+ {"attiny20", AVR2K, AVR128, 0UL},
+ {"attiny22", AVR2K, 224UL, AVR128},
+ {"attiny2313", AVR2K, AVR128, AVR128},
+ {"attiny2313a", AVR2K, AVR128, AVR128},
+ {"attiny24", AVR2K, AVR128, AVR128},
+ {"attiny24a", AVR2K, AVR128, AVR128},
+ {"attiny25", AVR2K, AVR128, AVR128},
+ {"attiny26", AVR2K, AVR128, AVR128},
+ {"attiny261", AVR2K, AVR128, AVR128},
+ {"attiny261a", AVR2K, AVR128, AVR128},
+ {"attiny28", AVR2K, 0UL, 0UL},
+ {"attiny40", AVR2K, AVR256, 0UL},
+
+ {"at90s1200", AVR1K, 0UL, AVR64},
+ {"attiny9", AVR1K, 32UL, 0UL},
+ {"attiny10", AVR1K, 32UL, 0UL},
+ {"attiny11", AVR1K, 0UL, AVR64},
+ {"attiny12", AVR1K, 0UL, AVR64},
+ {"attiny13", AVR1K, AVR64, AVR64},
+ {"attiny13a", AVR1K, AVR64, AVR64},
+ {"attiny15", AVR1K, 0UL, AVR64},
+
+ {"attiny4", AVR512, 32UL, 0UL},
+ {"attiny5", AVR512, 32UL, 0UL},
+};
+
+static char *avrmcu = NULL;
+
+
static char *target = NULL;
/* Forward declarations. */
@@ -89,7 +330,8 @@ usage (FILE *stream, int status)
fprintf (stream, _(" Displays the sizes of sections inside binary files\n"));
fprintf (stream, _(" If no input file(s) are specified, a.out is assumed\n"));
fprintf (stream, _(" The options are:\n\
- -A|-B|-G --format={sysv|berkeley|gnu} Select output style (default is %s)\n\
+ -A|-B|-G|-C --format={sysv|berkeley|gnu|avr} Select output style (default is %s)\n\
+ --mcu=<avrmcu> MCU name for AVR format only\n\
-o|-d|-x --radix={8|10|16} Display numbers in octal, decimal or hex\n\
-t --totals Display the total sizes (Berkeley only)\n\
--common Display total size for *COM* syms\n\
@@ -113,6 +355,7 @@ usage (FILE *stream, int status)
#define OPTION_FORMAT (200)
#define OPTION_RADIX (OPTION_FORMAT + 1)
#define OPTION_TARGET (OPTION_RADIX + 1)
+#define OPTION_MCU (OPTION_TARGET + 1)
static struct option long_options[] =
{
@@ -120,6 +363,7 @@ static struct option long_options[] =
{"format", required_argument, 0, OPTION_FORMAT},
{"radix", required_argument, 0, OPTION_RADIX},
{"target", required_argument, 0, OPTION_TARGET},
+ {"mcu", required_argument, 0, 203},
{"totals", no_argument, &show_totals, 1},
{"version", no_argument, &show_version, 1},
{"help", no_argument, &show_help, 1},
@@ -153,7 +397,7 @@ main (int argc, char **argv)
fatal (_("fatal error: libbfd ABI mismatch"));
set_default_bfd_target ();
- while ((c = getopt_long (argc, argv, "ABGHhVvdfotx", long_options,
+ while ((c = getopt_long (argc, argv, "ABCGHhVvdfotx", long_options,
(int *) 0)) != EOF)
switch (c)
{
@@ -172,12 +416,20 @@ main (int argc, char **argv)
case 'g':
selected_output_format = FORMAT_GNU;
break;
+ case 'A':
+ case 'a':
+ selected_output_format = FORMAT_AVR;
+ break;
default:
non_fatal (_("invalid argument to --format: %s"), optarg);
usage (stderr, 1);
}
break;
+ case OPTION_MCU:
+ avrmcu = optarg;
+ break;
+
case OPTION_TARGET:
target = optarg;
break;
@@ -214,6 +466,9 @@ main (int argc, char **argv)
case 'G':
selected_output_format = FORMAT_GNU;
break;
+ case 'C':
+ selected_output_format = FORMAT_AVR;
+ break;
case 'v':
case 'V':
show_version = 1;
@@ -656,6 +911,98 @@ print_sysv_format (bfd *file)
printf ("\n\n");
}
+static avr_device_t *
+avr_find_device (void)
+{
+ unsigned int i;
+ if (avrmcu != NULL)
+ {
+ for (i = 0; i < sizeof(avr) / sizeof(avr[0]); i++)
+ {
+ if (strcmp(avr[i].name, avrmcu) == 0)
+ {
+ /* Match found */
+ return (&avr[i]);
+ }
+ }
+ }
+ return (NULL);
+}
+
+static void
+print_avr_format (bfd *file)
+{
+ char *avr_name = "Unknown";
+ int flashmax = 0;
+ int rammax = 0;
+ int eeprommax = 0;
+ asection *section;
+ bfd_size_type my_datasize = 0;
+ bfd_size_type my_textsize = 0;
+ bfd_size_type my_bsssize = 0;
+ bfd_size_type bootloadersize = 0;
+ bfd_size_type noinitsize = 0;
+ bfd_size_type eepromsize = 0;
+
+ avr_device_t *avrdevice = avr_find_device();
+ if (avrdevice != NULL)
+ {
+ avr_name = avrdevice->name;
+ flashmax = avrdevice->flash;
+ rammax = avrdevice->ram;
+ eeprommax = avrdevice->eeprom;
+ }
+
+ if ((section = bfd_get_section_by_name (file, ".data")) != NULL)
+ my_datasize = bfd_section_size (section);
+ if ((section = bfd_get_section_by_name (file, ".text")) != NULL)
+ my_textsize = bfd_section_size (section);
+ if ((section = bfd_get_section_by_name (file, ".bss")) != NULL)
+ my_bsssize = bfd_section_size (section);
+ if ((section = bfd_get_section_by_name (file, ".bootloader")) != NULL)
+ bootloadersize = bfd_section_size (section);
+ if ((section = bfd_get_section_by_name (file, ".noinit")) != NULL)
+ noinitsize = bfd_section_size (section);
+ if ((section = bfd_get_section_by_name (file, ".eeprom")) != NULL)
+ eepromsize = bfd_section_size (section);
+
+ bfd_size_type text = my_textsize + my_datasize + bootloadersize;
+ bfd_size_type data = my_datasize + my_bsssize + noinitsize;
+ bfd_size_type eeprom = eepromsize;
+
+ printf ("AVR Memory Usage\n"
+ "----------------\n"
+ "Device: %s\n\n", avr_name);
+
+ /* Text size */
+ printf ("Program:%8ld bytes", text);
+ if (flashmax > 0)
+ {
+ printf (" (%2.1f%% Full)", ((float)text / flashmax) * 100);
+ }
+ printf ("\n(.text + .data + .bootloader)\n\n");
+
+ /* Data size */
+ printf ("Data: %8ld bytes", data);
+ if (rammax > 0)
+ {
+ printf (" (%2.1f%% Full)", ((float)data / rammax) * 100);
+ }
+ printf ("\n(.data + .bss + .noinit)\n\n");
+
+ /* EEPROM size */
+ if (eeprom > 0)
+ {
+ printf ("EEPROM: %8ld bytes", eeprom);
+ if (eeprommax > 0)
+ {
+ printf (" (%2.1f%% Full)", ((float)eeprom / eeprommax) * 100);
+ }
+ printf ("\n(.eeprom)\n\n");
+ }
+}
+
+
static void
print_sizes (bfd *file)
{
@@ -663,6 +1010,8 @@ print_sizes (bfd *file)
calculate_common_size (file);
if (selected_output_format == FORMAT_SYSV)
print_sysv_format (file);
+ else if (selected_output_format == FORMAT_AVR)
+ print_avr_format (file);
else
print_berkeley_or_gnu_format (file);
}

View File

@@ -0,0 +1,54 @@
# Maintainer: fauxpark <fauxpark@gmail.com>
_realname=avr-binutils
pkgbase=mingw-w64-${_realname}
pkgname=${MINGW_PACKAGE_PREFIX}-${_realname}
pkgver=2.35
pkgrel=1
pkgdesc='GNU Binutils for the AVR target (mingw-w64)'
arch=('any')
license=('GPL')
url='https://www.gnu.org/software/binutils/binutils.html'
source=(
"https://ftp.gnu.org/gnu/binutils/binutils-${pkgver}.tar.xz"
"01-avr-size.patch"
)
sha256sums=(
'1b11659fb49e20e18db460d44485f09442c8c56d5df165de9461eb09c8302f85'
'7aed303887a8541feba008943d0331dc95dd90a309575f81b7a195650e4cba1e'
)
prepare() {
cd ${srcdir}/binutils-${pkgver}
mkdir binutils-build
# https://github.com/archlinux/svntogit-community/blob/packages/avr-binutils/trunk/avr-size.patch
patch -p1 < ../01-avr-size.patch
}
build() {
cd ${srcdir}/binutils-${pkgver}/binutils-build
../configure \
--build=${MINGW_CHOST} \
--prefix=${MINGW_PREFIX} \
--target=avr \
--disable-nls \
--disable-debug \
--disable-dependency-tracking \
--disable-werror
make
}
package() {
cd ${srcdir}/binutils-${pkgver}/binutils-build
make DESTDIR="$pkgdir" install
cd ${pkgdir}${MINGW_PREFIX}
for info in as bfd binutils gprof ld; do
mv share/info/${info}.info share/info/avr-${info}.info
done
}

View File

@@ -0,0 +1,60 @@
# Maintainer: fauxpark <fauxpark@gmail.com>
_realname=avr-gcc
pkgbase=mingw-w64-${_realname}
pkgname=${MINGW_PACKAGE_PREFIX}-${_realname}
pkgver=8.4.0
pkgrel=1
pkgdesc='GNU compiler collection for AVR 8-bit and 32-bit microcontrollers (mingw-w64)'
arch=('any')
license=('GPL')
options=(!strip)
url='https://www.gnu.org/software/gcc/gcc.html'
depends=(
"${MINGW_PACKAGE_PREFIX}-avr-binutils"
"${MINGW_PACKAGE_PREFIX}-gmp"
"${MINGW_PACKAGE_PREFIX}-isl"
"${MINGW_PACKAGE_PREFIX}-mpc"
"${MINGW_PACKAGE_PREFIX}-mpfr"
)
source=("https://ftp.gnu.org/gnu/gcc/gcc-${pkgver}/gcc-${pkgver}.tar.xz")
sha256sums=('e30a6e52d10e1f27ed55104ad233c30bd1e99cfb5ff98ab022dc941edd1b2dd4')
prepare() {
cd ${srcdir}/gcc-${pkgver}
mkdir gcc-build
}
build() {
cd ${srcdir}/gcc-${pkgver}/gcc-build
../configure \
--build=${MINGW_CHOST} \
--prefix=${MINGW_PREFIX} \
--target=avr \
--enable-languages=c,c++ \
--disable-nls \
--disable-libssp \
--disable-shared \
--disable-threads \
--disable-libgomp \
--disable-libada \
--with-dwarf2 \
--enable-mingw-wildcard
make
}
package() {
cd ${srcdir}/gcc-${pkgver}/gcc-build
make DESTDIR="$pkgdir" install
cd ${pkgdir}${MINGW_PREFIX}
# strip debug symbols from libraries
find lib -type f -name "*.a" -exec ${MINGW_PREFIX}/bin/avr-strip --strip-debug '{}' \;
# info and man7 files conflict with native gcc
rm -rf share/info share/man/man7
}

View File

@@ -0,0 +1,48 @@
# Maintainer: fauxpark <fauxpark@gmail.com>
_realname=avr-gdb
pkgbase=mingw-w64-${_realname}
pkgname=${MINGW_PACKAGE_PREFIX}-${_realname}
pkgver=9.2
pkgrel=1
pkgdesc='The GNU Debugger for AVR (mingw-w64)'
arch=('any')
license=('GPL')
url='https://www.gnu.org/software/gdb/'
source=("https://ftp.gnu.org/gnu/gdb/gdb-${pkgver}.tar.xz")
sha256sums=('360cd7ae79b776988e89d8f9a01c985d0b1fa21c767a4295e5f88cb49175c555')
prepare() {
cd ${srcdir}/gdb-${pkgver}
mkdir gdb-build
}
build() {
cd ${srcdir}/gdb-${pkgver}/gdb-build
../configure \
--build=${MINGW_CHOST} \
--prefix=${MINGW_PREFIX} \
--target=avr \
--disable-nls \
--disable-debug \
--disable-dependency-tracking \
--disable-binutils \
--disable-libssp \
--disable-install-libbfd \
--disable-install-libiberty \
--with-system-readline
make
}
package() {
cd ${srcdir}/gdb-${pkgver}/gdb-build
make DESTDIR="$pkgdir" install-gdb
cd ${pkgdir}${MINGW_PREFIX}
# Remove files that conflict with native gdb
rm -rf include share/gdb share/info
}

View File

@@ -0,0 +1,37 @@
# Maintainer: fauxpark <fauxpark@gmail.com>
_realname=avr-libc
pkgbase=mingw-w64-${_realname}
pkgname=${MINGW_PACKAGE_PREFIX}-${_realname}
pkgver=2.0.0
pkgrel=1
pkgdesc='The C runtime library for the AVR family of microcontrollers (mingw-w64)'
arch=('any')
license=('BSD')
url='https://savannah.nongnu.org/projects/avr-libc/'
options=(!strip)
depends=("${MINGW_PACKAGE_PREFIX}-avr-gcc")
source=("https://download.savannah.gnu.org/releases/avr-libc/avr-libc-${pkgver}.tar.bz2")
sha256sums=('b2dd7fd2eefd8d8646ef6a325f6f0665537e2f604ed02828ced748d49dc85b97')
prepare() {
cd ${srcdir}/avr-libc-${pkgver}
mkdir avr-libc-build
}
build() {
cd ${srcdir}/avr-libc-${pkgver}/avr-libc-build
../configure \
--build=${MINGW_CHOST} \
--host=avr \
--prefix=${MINGW_PREFIX}
make
}
package() {
cd ${srcdir}/${_realname}-${pkgver}/avr-libc-build
make DESTDIR="$pkgdir" install
}

View File

@@ -0,0 +1,188 @@
diff --git a/cmake/AwsCFlags.cmake b/cmake/AwsCFlags.cmake
index 42d146e82..cb9d7f36b 100644
--- a/cmake/AwsCFlags.cmake
+++ b/cmake/AwsCFlags.cmake
@@ -68,6 +68,10 @@ function(aws_set_common_properties target)
if (LEGACY_COMPILER_SUPPORT)
list(APPEND AWS_C_FLAGS -Wno-strict-aliasing)
endif()
+
+ if(CMAKE_C_IMPLICIT_LINK_LIBRARIES MATCHES "mingw32")
+ list(APPEND AWS_C_FLAGS -D__USE_MINGW_ANSI_STDIO=1 -Wno-unused-local-typedefs)
+ endif()
endif()
check_include_file(stdint.h HAS_STDINT)
diff --git a/include/aws/common/byte_order.inl b/include/aws/common/byte_order.inl
index 69ee56792..847e726af 100644
--- a/include/aws/common/byte_order.inl
+++ b/include/aws/common/byte_order.inl
@@ -19,11 +19,11 @@
#include <aws/common/byte_order.h>
#include <aws/common/common.h>
-#ifdef _MSC_VER
+#ifdef _WIN32
# include <stdlib.h>
#else
# include <netinet/in.h>
-#endif /* _MSC_VER */
+#endif /* _WIN32 */
AWS_EXTERN_C_BEGIN
@@ -49,7 +49,7 @@ AWS_STATIC_IMPL uint64_t aws_hton64(uint64_t x) {
uint64_t v;
__asm__("bswap %q0" : "=r"(v) : "0"(x));
return v;
-#elif defined(_MSC_VER)
+#elif defined(_WIN32)
return _byteswap_uint64(x);
#else
uint32_t low = (uint32_t)x;
@@ -69,7 +69,7 @@ AWS_STATIC_IMPL uint64_t aws_ntoh64(uint64_t x) {
* Convert 32 bit integer from host to network byte order.
*/
AWS_STATIC_IMPL uint32_t aws_hton32(uint32_t x) {
-#ifdef _MSC_VER
+#ifdef _WIN32
return aws_is_big_endian() ? x : _byteswap_ulong(x);
#else
return htonl(x);
@@ -126,7 +126,7 @@ AWS_STATIC_IMPL double aws_htonf64(double x) {
* Convert 32 bit integer from network to host byte order.
*/
AWS_STATIC_IMPL uint32_t aws_ntoh32(uint32_t x) {
-#ifdef _MSC_VER
+#ifdef _WIN32
return aws_is_big_endian() ? x : _byteswap_ulong(x);
#else
return ntohl(x);
@@ -151,7 +151,7 @@ AWS_STATIC_IMPL double aws_ntohf64(double x) {
* Convert 16 bit integer from host to network byte order.
*/
AWS_STATIC_IMPL uint16_t aws_hton16(uint16_t x) {
-#ifdef _MSC_VER
+#ifdef _WIN32
return aws_is_big_endian() ? x : _byteswap_ushort(x);
#else
return htons(x);
@@ -162,7 +162,7 @@ AWS_STATIC_IMPL uint16_t aws_hton16(uint16_t x) {
* Convert 16 bit integer from network to host byte order.
*/
AWS_STATIC_IMPL uint16_t aws_ntoh16(uint16_t x) {
-#ifdef _MSC_VER
+#ifdef _WIN32
return aws_is_big_endian() ? x : _byteswap_ushort(x);
#else
return ntohs(x);
diff --git a/include/aws/common/logging.h b/include/aws/common/logging.h
index 8ef813c75..bfef7cfad 100644
--- a/include/aws/common/logging.h
+++ b/include/aws/common/logging.h
@@ -111,7 +111,9 @@ struct aws_logger_vtable {
aws_log_subject_t subject,
const char *format,
...)
-#if defined(__clang__) || defined(__GNUC__) || defined(__GNUG__)
+#if defined(__MINGW32__)
+ __attribute__((format(gnu_printf, 4, 5)))
+#elif defined(__clang__) || defined(__GNUC__) || defined(__GNUG__)
__attribute__((format(printf, 4, 5)))
#endif /* non-ms compilers: TODO - find out what versions format support was added in */
;
diff --git a/include/aws/testing/aws_test_harness.h b/include/aws/testing/aws_test_harness.h
index 88ef03e21..d598e2f97 100644
--- a/include/aws/testing/aws_test_harness.h
+++ b/include/aws/testing/aws_test_harness.h
@@ -365,6 +365,9 @@ struct aws_test_harness {
};
#if defined(_WIN32)
+# ifdef __MINGW32__
+# include <winsock2.h>
+# endif
# include <windows.h>
static LONG WINAPI s_test_print_stack_trace(struct _EXCEPTION_POINTERS *exception_pointers) {
# if !defined(AWS_HEADER_CHECKER)
diff --git a/source/windows/environment.c b/source/windows/environment.c
index 8c042ddc5..ae50d0a59 100644
--- a/source/windows/environment.c
+++ b/source/windows/environment.c
@@ -23,12 +23,16 @@ int aws_get_environment_value(
const struct aws_string *variable_name,
struct aws_string **value_out) {
-#pragma warning(push)
-#pragma warning(disable : 4996)
+#ifdef _MSC_VER
+# pragma warning(push)
+# pragma warning(disable : 4996)
+#endif
const char *value = getenv(aws_string_c_str(variable_name));
-#pragma warning(pop)
+#ifdef _MSC_VER
+# pragma warning(pop)
+#endif
if (value == NULL) {
*value_out = NULL;
diff --git a/source/windows/system_info.c b/source/windows/system_info.c
index acbfd97ce..927a81b4a 100644
--- a/source/windows/system_info.c
+++ b/source/windows/system_info.c
@@ -40,7 +40,9 @@ void aws_debug_break(void) {
}
/* If I meet the engineer that wrote the dbghelp.h file for the windows 8.1 SDK we're gonna have words! */
-#pragma warning(disable : 4091)
+#ifdef _MSC_VER
+# pragma warning(disable : 4091)
+#endif
#include <dbghelp.h>
struct win_symbol_data {
@@ -124,7 +126,7 @@ static void s_init_dbghelp_impl(void *user_data) {
return;
}
-static bool s_init_dbghelp() {
+static bool s_init_dbghelp(void) {
if (AWS_LIKELY(s_SymInitialize)) {
return true;
}
@@ -188,7 +190,7 @@ char **aws_backtrace_symbols(void *const *stack, size_t num_frames) {
/* no luck, record the address and last error */
DWORD last_error = GetLastError();
int len = snprintf(
- sym_buf, AWS_ARRAY_SIZE(sym_buf), "at 0x%p: Failed to lookup symbol: error %u", stack[i], last_error);
+ sym_buf, AWS_ARRAY_SIZE(sym_buf), "at 0x%p: Failed to lookup symbol: error %lu", stack[i], last_error);
if (len > 0) {
struct aws_byte_cursor sym_cur = aws_byte_cursor_from_array(sym_buf, len);
aws_byte_buf_append_dynamic(&symbols, &sym_cur);
@@ -209,7 +211,7 @@ char **aws_backtrace_addr2line(void *const *frames, size_t stack_depth) {
void aws_backtrace_print(FILE *fp, void *call_site_data) {
struct _EXCEPTION_POINTERS *exception_pointers = call_site_data;
if (exception_pointers) {
- fprintf(fp, "** Exception 0x%x occured **\n", exception_pointers->ExceptionRecord->ExceptionCode);
+ fprintf(fp, "** Exception 0x%lx occured **\n", exception_pointers->ExceptionRecord->ExceptionCode);
}
if (!s_init_dbghelp()) {
diff --git a/tests/atomics_test.c b/tests/atomics_test.c
index 36dbbd1a5..90f0497e2 100644
--- a/tests/atomics_test.c
+++ b/tests/atomics_test.c
@@ -23,7 +23,9 @@
#ifdef _WIN32
# include <malloc.h>
-# define alloca _alloca
+# ifdef _MSC_VER
+# define alloca _alloca
+# endif
#elif defined(__FreeBSD__) || defined(__NetBSD__)
# include <stdlib.h>
#else

View File

@@ -0,0 +1,11 @@
diff -aurp AwsChecksums/source/intel/cpuid.c AwsChecksums-orig/source/intel/cpuid.c
--- AwsChecksums/source/intel/cpuid.c 2020-08-08 21:25:59.314437100 +0000
+++ AwsChecksums-orig/source/intel/cpuid.c 2020-08-08 21:25:44.210636300 +0000
@@ -40,4 +40,9 @@ int aws_checksums_do_cpu_id(int32_t *cpu
+#else
+int aws_checksums_do_cpu_id(int32_t *cpuid) {
+ (void)cpuid;
+ return 0;
+}
#endif /* defined(__x86_64__) && !(defined(__GNUC__) && defined(DEBUG_BUILD)) */

View File

@@ -0,0 +1,52 @@
# Maintainer: Jeroen Ooms <jeroen@berkeley.edu>
_realname=aws-sdk-cpp
pkgbase=mingw-w64-${_realname}
pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}")
pkgver=1.7.365
pkgrel=1
pkgdesc="AWS SDK for C++ (mingw-w64)"
arch=('any')
url="https://github.com/aws/aws-sdk-cpp"
license=('Apache-2.0')
makedepends=("${MINGW_PACKAGE_PREFIX}-cmake"
"${MINGW_PACKAGE_PREFIX}-ninja")
options=('strip' 'staticlibs')
source=("${_realname}-${pkgver}.tar.gz::https://github.com/aws/aws-sdk-cpp/archive/${pkgver}.tar.gz"
"aws-sdk-cpp-pr-1333.patch"
"Patch-cmake-submodules.patch"
"BuildAwsCCommon.patch"
"BuildAwsChecksums.patch")
sha256sums=('95e3f40efaea7b232741bfb76c54c9507c02631edfc198720b0e84be0ebb5e9d'
'14abbdb71e615d93d5aa1e83f94f994b7fbe05edc63477e37325a6f5148c7278'
'edb6ef4ac7d3e48dfc1fa4b0b02a6a191bb405ae69c19d9f7bcf3856269bc6fb'
'957eb1cc68b151622b7667e6a13506c96fdef8f566a227ac1608c9e02d3826d3'
'20359b6e79430d1deb69bb05214a2f18258cb54ca56e15cd24605ad0c0094df1')
prepare() {
cd "${_realname}-${pkgver}"
patch -p1 -i "${srcdir}/aws-sdk-cpp-pr-1333.patch"
patch -p1 -i "${srcdir}/Patch-cmake-submodules.patch"
}
build() {
[[ -d "${srcdir}"/build-${CARCH}-static ]] && rm -rf "${srcdir}"/build-${CARCH}-static
mkdir -p "${srcdir}"/build-${CARCH}-static && cd "${srcdir}"/build-${CARCH}-static
MSYS2_ARG_CONV_EXCL="-DCMAKE_INSTALL_PREFIX=" \
${MINGW_PREFIX}/bin/cmake \
-GNinja \
-DCMAKE_BUILD_TYPE=Release \
-DBUILD_SHARED_LIBS=OFF \
-DCMAKE_INSTALL_PREFIX="${MINGW_PREFIX}" \
-DBUILD_ONLY="config;s3;transfer" \
-DENABLE_UNITY_BUILD=ON \
-DAUTORUN_UNIT_TESTS=OFF \
../${_realname}-${pkgver}
${MINGW_PREFIX}/bin/cmake --build .
}
package() {
cd "${srcdir}"/build-${CARCH}-static
DESTDIR="${pkgdir}" ${MINGW_PREFIX}/bin/cmake --build . --target install
}

View File

@@ -0,0 +1,23 @@
diff -aurp aws-sdk-cpp-1.7.288-orig/third-party/cmake/BuildAwsCCommon.cmake aws-sdk-cpp-1.7.288/third-party/cmake/BuildAwsCCommon.cmake
--- aws-sdk-cpp-1.7.288-orig/third-party/cmake/BuildAwsCCommon.cmake 2020-08-08 14:05:06.174688800 +0000
+++ aws-sdk-cpp-1.7.288/third-party/cmake/BuildAwsCCommon.cmake 2020-08-08 14:03:44.967180800 +0000
@@ -42,6 +42,7 @@ else()
GIT_TAG ${AWS_C_COMMON_TAG}
BUILD_IN_SOURCE 0
UPDATE_COMMAND ""
+ PATCH_COMMAND patch -p1 < ${CMAKE_SOURCE_DIR}/../../../BuildAwsCCommon.patch
CMAKE_ARGS
-DCMAKE_INSTALL_PREFIX=${AWS_DEPS_INSTALL_DIR}
-DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE}
diff -aurp aws-sdk-cpp-1.7.288-orig/third-party/cmake/BuildAwsChecksums.cmake aws-sdk-cpp-1.7.288/third-party/cmake/BuildAwsChecksums.cmake
--- aws-sdk-cpp-1.7.288-orig/third-party/cmake/BuildAwsChecksums.cmake 2020-08-08 14:05:06.174688800 +0000
+++ aws-sdk-cpp-1.7.288/third-party/cmake/BuildAwsChecksums.cmake 2020-08-08 14:03:44.967180800 +0000
@@ -42,6 +42,7 @@ else()
GIT_TAG ${AWS_CHECKSUMS_TAG}
BUILD_IN_SOURCE 0
UPDATE_COMMAND ""
+ PATCH_COMMAND patch -p1 < ${CMAKE_SOURCE_DIR}/../../../BuildAwsChecksums.patch
CMAKE_ARGS
-DCMAKE_INSTALL_PREFIX=${AWS_DEPS_INSTALL_DIR}
-DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE}

View File

@@ -0,0 +1,291 @@
From f9b4499ccb63ef02d8c9de462fbbcf301eb1907a Mon Sep 17 00:00:00 2001
From: Daniel Schulte <daniel.schulte@picture-instruments.com>
Date: Tue, 3 Mar 2020 11:09:15 +0100
Subject: [PATCH] Add support for building with MinGW
---
aws-cpp-sdk-core/include/aws/core/utils/Array.h | 8 ++++----
.../include/aws/core/utils/crypto/bcrypt/CryptoImpl.h | 7 +++++++
.../include/aws/core/utils/event/EventHeader.h | 10 ++++++++++
.../source/http/windows/WinHttpSyncHttpClient.cpp | 4 ++--
.../source/http/windows/WinINetSyncHttpClient.cpp | 2 +-
.../source/http/windows/WinSyncHttpClient.cpp | 2 +-
.../source/platform/windows/Environment.cpp | 5 +++++
.../source/platform/windows/FileSystem.cpp | 7 ++++++-
.../source/platform/windows/OSVersionInfo.cpp | 2 ++
.../source/utils/crypto/factory/Factories.cpp | 4 ++--
.../BucketAndObjectOperationTest.cpp | 4 ++--
cmake/compiler_settings.cmake | 6 ++++++
.../source/platform/windows/PlatformTesting.cpp | 2 ++
13 files changed, 50 insertions(+), 13 deletions(-)
diff --git a/aws-cpp-sdk-core/include/aws/core/utils/Array.h b/aws-cpp-sdk-core/include/aws/core/utils/Array.h
index 1dbb9020f4..6768b6b850 100644
--- a/aws-cpp-sdk-core/include/aws/core/utils/Array.h
+++ b/aws-cpp-sdk-core/include/aws/core/utils/Array.h
@@ -64,7 +64,7 @@ namespace Aws
{
m_data.reset(Aws::NewArray<T>(m_size, ARRAY_ALLOCATION_TAG));
-#ifdef _WIN32
+#ifdef _MSC_VER
std::copy(arrayToCopy, arrayToCopy + arraySize, stdext::checked_array_iterator< T * >(m_data.get(), m_size));
#else
std::copy(arrayToCopy, arrayToCopy + arraySize, m_data.get());
@@ -92,7 +92,7 @@ namespace Aws
if(arr->m_size > 0 && arr->m_data)
{
size_t arraySize = arr->m_size;
-#ifdef _WIN32
+#ifdef _MSC_VER
std::copy(arr->m_data.get(), arr->m_data.get() + arraySize, stdext::checked_array_iterator< T * >(m_data.get() + location, m_size));
#else
std::copy(arr->m_data.get(), arr->m_data.get() + arraySize, m_data.get() + location);
@@ -111,7 +111,7 @@ namespace Aws
{
m_data.reset(Aws::NewArray<T>(m_size, ARRAY_ALLOCATION_TAG));
-#ifdef _WIN32
+#ifdef _MSC_VER
std::copy(other.m_data.get(), other.m_data.get() + other.m_size, stdext::checked_array_iterator< T * >(m_data.get(), m_size));
#else
std::copy(other.m_data.get(), other.m_data.get() + other.m_size, m_data.get());
@@ -144,7 +144,7 @@ namespace Aws
{
m_data.reset(Aws::NewArray<T>(m_size, ARRAY_ALLOCATION_TAG));
-#ifdef _WIN32
+#ifdef _MSC_VER
std::copy(other.m_data.get(), other.m_data.get() + other.m_size, stdext::checked_array_iterator< T * >(m_data.get(), m_size));
#else
std::copy(other.m_data.get(), other.m_data.get() + other.m_size, m_data.get());
diff --git a/aws-cpp-sdk-core/include/aws/core/utils/crypto/bcrypt/CryptoImpl.h b/aws-cpp-sdk-core/include/aws/core/utils/crypto/bcrypt/CryptoImpl.h
index 992efab47c..406380033a 100644
--- a/aws-cpp-sdk-core/include/aws/core/utils/crypto/bcrypt/CryptoImpl.h
+++ b/aws-cpp-sdk-core/include/aws/core/utils/crypto/bcrypt/CryptoImpl.h
@@ -39,7 +39,14 @@ namespace Aws
{
namespace Crypto
{
+ #ifdef __MINGW32__
+ #pragma GCC diagnostic push
+ #pragma GCC diagnostic ignored "-Wunused-variable"
+ #endif
static const char* SecureRandom_BCrypt_Tag = "SecureRandom_BCrypt";
+ #ifdef __MINGW32__
+ #pragma GCC diagnostic pop
+ #endif
class SecureRandomBytes_BCrypt : public SecureRandomBytes
{
diff --git a/aws-cpp-sdk-core/include/aws/core/utils/event/EventHeader.h b/aws-cpp-sdk-core/include/aws/core/utils/event/EventHeader.h
index 2041b208da..6fb333bff7 100644
--- a/aws-cpp-sdk-core/include/aws/core/utils/event/EventHeader.h
+++ b/aws-cpp-sdk-core/include/aws/core/utils/event/EventHeader.h
@@ -24,6 +24,12 @@
#include <aws/event-stream/event_stream.h>
#include <cassert>
+#ifdef __MINGW32__
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wmaybe-uninitialized"
+#pragma GCC diagnostic ignored "-Wuninitialized"
+#endif
+
namespace Aws
{
namespace Utils
@@ -319,3 +325,7 @@ namespace Aws
}
}
}
+
+#ifdef __MINGW32__
+#pragma GCC diagnostic pop
+#endif
diff --git a/aws-cpp-sdk-core/source/http/windows/WinHttpSyncHttpClient.cpp b/aws-cpp-sdk-core/source/http/windows/WinHttpSyncHttpClient.cpp
index 4a0f80a161..a98635f706 100644
--- a/aws-cpp-sdk-core/source/http/windows/WinHttpSyncHttpClient.cpp
+++ b/aws-cpp-sdk-core/source/http/windows/WinHttpSyncHttpClient.cpp
@@ -267,7 +267,7 @@ bool WinHttpSyncHttpClient::DoQueryHeaders(void* hHttpRequest, std::shared_ptr<H
wmemset(contentTypeStr, 0, static_cast<size_t>(dwSize / sizeof(wchar_t)));
WinHttpQueryHeaders(hHttpRequest, WINHTTP_QUERY_CONTENT_TYPE, nullptr, &contentTypeStr, &dwSize, 0);
- if (contentTypeStr[0] != NULL)
+ if (contentTypeStr[0])
{
Aws::String contentStr = StringUtils::FromWString(contentTypeStr);
response->SetContentType(contentStr);
@@ -298,7 +298,7 @@ bool WinHttpSyncHttpClient::DoQueryHeaders(void* hHttpRequest, std::shared_ptr<H
bool WinHttpSyncHttpClient::DoSendRequest(void* hHttpRequest) const
{
- return (WinHttpSendRequest(hHttpRequest, NULL, NULL, 0, 0, 0, NULL) != 0);
+ return (WinHttpSendRequest(hHttpRequest, NULL, 0, 0, 0, 0, 0) != 0);
}
bool WinHttpSyncHttpClient::DoReadData(void* hHttpRequest, char* body, uint64_t size, uint64_t& read) const
diff --git a/aws-cpp-sdk-core/source/http/windows/WinINetSyncHttpClient.cpp b/aws-cpp-sdk-core/source/http/windows/WinINetSyncHttpClient.cpp
index 8b42c64dab..ef1fd99975 100644
--- a/aws-cpp-sdk-core/source/http/windows/WinINetSyncHttpClient.cpp
+++ b/aws-cpp-sdk-core/source/http/windows/WinINetSyncHttpClient.cpp
@@ -228,7 +228,7 @@ bool WinINetSyncHttpClient::DoQueryHeaders(void* hHttpRequest, std::shared_ptr<H
char contentTypeStr[1024];
dwSize = sizeof(contentTypeStr);
HttpQueryInfoA(hHttpRequest, HTTP_QUERY_CONTENT_TYPE, &contentTypeStr, &dwSize, 0);
- if (contentTypeStr[0] != NULL)
+ if (contentTypeStr[0])
{
response->SetContentType(contentTypeStr);
AWS_LOGSTREAM_DEBUG(GetLogTag(), "Received content type " << contentTypeStr);
diff --git a/aws-cpp-sdk-core/source/http/windows/WinSyncHttpClient.cpp b/aws-cpp-sdk-core/source/http/windows/WinSyncHttpClient.cpp
index 3758006a53..2b4ce940b7 100644
--- a/aws-cpp-sdk-core/source/http/windows/WinSyncHttpClient.cpp
+++ b/aws-cpp-sdk-core/source/http/windows/WinSyncHttpClient.cpp
@@ -322,7 +322,7 @@ void WinSyncHttpClient::MakeRequestInternal(HttpRequest& request,
}
}
- if (!success && !IsRequestProcessingEnabled() || !ContinueRequest(request))
+ if (!success && (!IsRequestProcessingEnabled() || !ContinueRequest(request)))
{
response->SetClientErrorType(CoreErrors::USER_CANCELLED);
response->SetClientErrorMessage("Request processing disabled or continuation cancelled by user's continuation handler.");
diff --git a/aws-cpp-sdk-core/source/platform/windows/Environment.cpp b/aws-cpp-sdk-core/source/platform/windows/Environment.cpp
index fd8d58f291..097274a56b 100644
--- a/aws-cpp-sdk-core/source/platform/windows/Environment.cpp
+++ b/aws-cpp-sdk-core/source/platform/windows/Environment.cpp
@@ -29,6 +29,7 @@ that would need to be manually freed in all the client functions, just copy it i
*/
Aws::String GetEnv(const char *variableName)
{
+#ifdef _MSC_VER
char* variableValue = nullptr;
std::size_t valueSize = 0;
auto queryResult = _dupenv_s(&variableValue, &valueSize, variableName);
@@ -41,6 +42,10 @@ Aws::String GetEnv(const char *variableName)
}
return result;
+#else // __MINGW32__
+ auto variableValue = std::getenv(variableName);
+ return Aws::String( variableValue ? variableValue : "" );
+#endif
}
} // namespace Environment
diff --git a/aws-cpp-sdk-core/source/platform/windows/FileSystem.cpp b/aws-cpp-sdk-core/source/platform/windows/FileSystem.cpp
index 49af3c1f79..f427fa9233 100644
--- a/aws-cpp-sdk-core/source/platform/windows/FileSystem.cpp
+++ b/aws-cpp-sdk-core/source/platform/windows/FileSystem.cpp
@@ -21,7 +21,9 @@
#include <iostream>
#include <Userenv.h>
-#pragma warning( disable : 4996)
+#ifdef _MSC_VER
+# pragma warning( disable : 4996)
+#endif
using namespace Aws::Utils;
namespace Aws
@@ -314,6 +316,9 @@ Aws::String CreateTempFilePath()
{
#ifdef _MSC_VER
#pragma warning(disable: 4996) // _CRT_SECURE_NO_WARNINGS
+#elif !defined(L_tmpnam_s)
+ // Definition from the MSVC stdio.h
+ #define L_tmpnam_s (sizeof("\\") + 16)
#endif
char s_tempName[L_tmpnam_s+1];
diff --git a/aws-cpp-sdk-core/source/platform/windows/OSVersionInfo.cpp b/aws-cpp-sdk-core/source/platform/windows/OSVersionInfo.cpp
index 23f395f6bb..18bd5836da 100644
--- a/aws-cpp-sdk-core/source/platform/windows/OSVersionInfo.cpp
+++ b/aws-cpp-sdk-core/source/platform/windows/OSVersionInfo.cpp
@@ -19,7 +19,9 @@
#include <iomanip>
+#ifdef _MSC_VER
#pragma warning(disable: 4996)
+#endif
#include <windows.h>
#include <stdio.h>
namespace Aws
diff --git a/aws-cpp-sdk-core/source/utils/crypto/factory/Factories.cpp b/aws-cpp-sdk-core/source/utils/crypto/factory/Factories.cpp
index d7cb481d5c..3b34d7fc62 100644
--- a/aws-cpp-sdk-core/source/utils/crypto/factory/Factories.cpp
+++ b/aws-cpp-sdk-core/source/utils/crypto/factory/Factories.cpp
@@ -755,7 +755,7 @@ std::shared_ptr<Aws::Utils::Crypto::HMAC> Aws::Utils::Crypto::CreateSha256HMACIm
return s_Sha256HMACFactory->CreateImplementation();
}
-#ifdef _WIN32
+#ifdef _MSC_VER
#pragma warning( push )
#pragma warning( disable : 4702 )
#endif
@@ -840,7 +840,7 @@ std::shared_ptr<SymmetricCipher> Aws::Utils::Crypto::CreateAES_KeyWrapImplementa
return s_AES_KeyWrapFactory->CreateImplementation(key);
}
-#ifdef _WIN32
+#ifdef _MSC_VER
#pragma warning(pop)
#endif
diff --git a/aws-cpp-sdk-s3-integration-tests/BucketAndObjectOperationTest.cpp b/aws-cpp-sdk-s3-integration-tests/BucketAndObjectOperationTest.cpp
index 0f31fcd061..586303e044 100644
--- a/aws-cpp-sdk-s3-integration-tests/BucketAndObjectOperationTest.cpp
+++ b/aws-cpp-sdk-s3-integration-tests/BucketAndObjectOperationTest.cpp
@@ -54,9 +54,9 @@
#include <aws/testing/TestingEnvironment.h>
#include <fstream>
-#ifdef _WIN32
+#ifdef _MSC_VER
#pragma warning(disable: 4127)
-#endif //_WIN32
+#endif //_MSC_VER
#include <aws/core/http/standard/StandardHttpRequest.h>
diff --git a/cmake/compiler_settings.cmake b/cmake/compiler_settings.cmake
index db054b2c1b..e1d6dce55e 100644
--- a/cmake/compiler_settings.cmake
+++ b/cmake/compiler_settings.cmake
@@ -11,6 +11,9 @@ else()
set(COMPILER_CLANG 1)
else()
set(COMPILER_GCC 1)
+ if(MINGW)
+ set(COMPILER_MINGW 1)
+ endif()
endif()
set(USE_GCC_FLAGS 1)
endif()
@@ -34,6 +37,9 @@ endfunction()
macro(set_gcc_flags)
list(APPEND AWS_COMPILER_FLAGS "-fno-exceptions" "-std=c++${CPP_STANDARD}")
+ if(COMPILER_IS_MINGW)
+ list(APPEND AWS_COMPILER_FLAGS -D__USE_MINGW_ANSI_STDIO=1)
+ endif()
if(NOT BUILD_SHARED_LIBS)
list(APPEND AWS_COMPILER_FLAGS "-fPIC")
diff --git a/testing-resources/source/platform/windows/PlatformTesting.cpp b/testing-resources/source/platform/windows/PlatformTesting.cpp
index 2b0a04c0b4..2a27710557 100644
--- a/testing-resources/source/platform/windows/PlatformTesting.cpp
+++ b/testing-resources/source/platform/windows/PlatformTesting.cpp
@@ -15,7 +15,9 @@
#include <aws/testing/platform/PlatformTesting.h>
+#ifdef _MSC_VER
#pragma warning(disable: 4996)
+#endif
#include <windows.h>
#include <aws/core/utils/memory/stl/AWSStringStream.h>

View File

@@ -1,9 +1,10 @@
# Maintainer: Diego Sogari <diego.sogari@gmail.com>
# Contributor: Konstantin Podsvirov <konstantin@podsvirov.pro>
_realname=binaryen
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=94
pkgver=96
pkgrel=1
pkgdesc="Compiler infrastructure and toolchain library for WebAssembly, in C++ (mingw-w64)"
arch=('any')
@@ -11,7 +12,7 @@ url="https://github.com/WebAssembly/binaryen"
license=('Apache')
makedepends=("${MINGW_PACKAGE_PREFIX}-cmake")
source=("${_realname}-${pkgver}.tar.gz::https://github.com/WebAssembly/binaryen/archive/version_${pkgver}.tar.gz")
sha256sums=('af7d9d66cb3d8667ee8b3f92927cf94599ce4fcf308fc919853c11197f28b03d')
sha256sums=('fe140191607c76f02bd0f1cc641715cefcb48e723409418c2a39a50905a4514c')
build() {
declare -a extra_config

View File

@@ -9,14 +9,21 @@ index a6bf9a2..fa50e79 100644
+sys/MSYS.mk
sys/NetBSD.mk
diff --git a/mk/sys/MINGW32.mk b/mk/sys/MINGW32.mk
index 10da919..5ba0424 100644
index 10da919..9d04333 100644
--- a/mk/sys/MINGW32.mk
+++ b/mk/sys/MINGW32.mk
@@ -1,2 +1,2 @@
-# $Id: Linux.mk,v 1.9 2017/05/05 18:02:16 sjg Exp $
+# $Id: MINGW32.mk,v 1.9 2017/05/05 18:02:16 sjg Exp $
# $NetBSD: sys.mk,v 1.19.2.1 1994/07/26 19:58:31 cgd Exp $
@@ -16,3 +16,7 @@ NEED_SOLINKS=yes
@@ -14,5 +14,14 @@ NEED_SOLINKS=yes
+LD_X=
+LD_x=
+SHLIB_LD = ${CC}
+SHLIB_LDADD?= ${LDADD}
+
.SUFFIXES: .out .a .ln .o .c ${CXX_SUFFIXES} .F .f .r .y .l .s .S .cl .p .h .sh .m4
-.LIBS: .a
+.LIBS: .a .dll
@@ -25,21 +32,28 @@ index 10da919..5ba0424 100644
+HOST_LIBEXT = .dll
+DSHLIBEXT = .dll
@@ -21,2 +25,5 @@ ARFLAGS= rl
@@ -21,2 +30,5 @@ ARFLAGS= rl
RANLIB= ranlib
+LD_shared= -Bshareable
+LD_shared= -Bshareable -shared
+LD_so= dll.${SHLIB_FULLVERSION}
+LD_solink= dll
diff --git a/mk/sys/MINGW64.mk b/mk/sys/MINGW64.mk
index 10da919..f7a1fe7 100644
index 10da919..793b169 100644
--- a/mk/sys/MINGW64.mk
+++ b/mk/sys/MINGW64.mk
@@ -1,2 +1,2 @@
-# $Id: Linux.mk,v 1.9 2017/05/05 18:02:16 sjg Exp $
+# $Id: MINGW64.mk,v 1.9 2017/05/05 18:02:16 sjg Exp $
# $NetBSD: sys.mk,v 1.19.2.1 1994/07/26 19:58:31 cgd Exp $
@@ -16,3 +16,7 @@ NEED_SOLINKS=yes
@@ -14,5 +14,14 @@ NEED_SOLINKS=yes
+LD_X=
+LD_x=
+SHLIB_LD = ${CC}
+SHLIB_LDADD?= ${LDADD}
+
.SUFFIXES: .out .a .ln .o .c ${CXX_SUFFIXES} .F .f .r .y .l .s .S .cl .p .h .sh .m4
-.LIBS: .a
+.LIBS: .a .dll
@@ -48,21 +62,28 @@ index 10da919..f7a1fe7 100644
+HOST_LIBEXT = .dll
+DSHLIBEXT = .dll
@@ -21,2 +25,5 @@ ARFLAGS= rl
@@ -21,2 +30,5 @@ ARFLAGS= rl
RANLIB= ranlib
+LD_shared= -Bshareable
+LD_shared= -Bshareable -shared
+LD_so= dll.${SHLIB_FULLVERSION}
+LD_solink= dll
diff --git a/mk/sys/MSYS.mk b/mk/sys/MSYS.mk
index 10da919..2454fd1 100644
index 10da919..16b3b53 100644
--- a/mk/sys/MSYS.mk
+++ b/mk/sys/MSYS.mk
@@ -1,2 +1,2 @@
-# $Id: Linux.mk,v 1.9 2017/05/05 18:02:16 sjg Exp $
+# $Id: MSYS.mk,v 1.9 2017/05/05 18:02:16 sjg Exp $
# $NetBSD: sys.mk,v 1.19.2.1 1994/07/26 19:58:31 cgd Exp $
@@ -16,3 +16,7 @@ NEED_SOLINKS=yes
@@ -14,5 +14,14 @@ NEED_SOLINKS=yes
+LD_X=
+LD_x=
+SHLIB_LD = ${CC}
+SHLIB_LDADD?= ${LDADD}
+
.SUFFIXES: .out .a .ln .o .c ${CXX_SUFFIXES} .F .f .r .y .l .s .S .cl .p .h .sh .m4
-.LIBS: .a
+.LIBS: .a .dll
@@ -71,9 +92,9 @@ index 10da919..2454fd1 100644
+HOST_LIBEXT = .dll
+DSHLIBEXT = .dll
@@ -21,2 +25,5 @@ ARFLAGS= rl
@@ -21,2 +30,5 @@ ARFLAGS= rl
RANLIB= ranlib
+LD_shared= -Bshareable
+LD_shared= -Bshareable -shared
+LD_so= dll.${SHLIB_FULLVERSION}
+LD_solink= dll

View File

@@ -8,7 +8,7 @@ _realname=bmake
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=20181221
pkgrel=2
pkgrel=5
pkgdesc='Portable version of the NetBSD make build tool'
arch=('any')
url='http://www.crufty.net/help/sjg/bmake.html'
@@ -72,6 +72,6 @@ package() {
# install profile script
mkdir -p "${pkgdir}${MINGW_PREFIX}"/etc/profile.d
echo "export SYSROOTWINDOWSPATH=$(cygpath -w /)" > "${pkgdir}${MINGW_PREFIX}"/etc/profile.d/bmake.sh
echo "export SYSROOTWINDOWSPATH=$(cygpath -w /); export MAKESYSPATH=${MINGW_PREFIX}/share/mk" > "${pkgdir}${MINGW_PREFIX}"/etc/profile.d/bmake.sh
cp "${pkgdir}${MINGW_PREFIX}"/etc/profile.d/bmake.{sh,zsh}
}

View File

@@ -3,7 +3,7 @@
_realname=cargo-c
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=0.6.9
pkgver=0.6.10
pkgrel=1
pkgdesc='A cargo subcommand to build and install C-ABI compatibile dynamic and static libraries (mingw-w64)'
arch=('any')
@@ -18,8 +18,8 @@ makedepends=(
"${MINGW_PACKAGE_PREFIX}-rust")
source=("${_realname}-${pkgver}.tar.gz"::"https://github.com/lu-zero/cargo-c/archive/v${pkgver}.tar.gz"
"${_realname}-${pkgver}.Cargo.lock"::"https://github.com/lu-zero/cargo-c/releases/download/v${pkgver}/Cargo.lock")
sha256sums=('d88bad2ada3432b15d2a871a5071f2bd7554beec5ecc4807c91599533de76cb4'
'a12f2a572848fa18c502dc33f114307959554fe3311ee1dd7da0a2787e444912')
sha256sums=('3e0f6c70291e48b09f936a5918656159b1d840d7a3b010316d0fc61e9b048bca'
'3959b780a22afa6d9ac2a620fce6c1601957bfec465afd204e0db40b5693bc09')
prepare() {
cp "${srcdir}/${_realname}-${pkgver}.Cargo.lock" "${_realname}-${pkgver}/Cargo.lock"

View File

@@ -4,7 +4,7 @@ _realname=cfitsio
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=3.450
pkgrel=1
pkgrel=2
pkgdesc="A library of C and Fortran subroutines for reading and writing data files in FITS (Flexible Image Transport System) data format (mingw-w64)"
arch=('any')
url="https://heasarc.gsfc.nasa.gov/fitsio/"
@@ -35,7 +35,8 @@ build() {
mkdir ${srcdir}/static-${MINGW_CHOST} && cd "${srcdir}/static-${MINGW_CHOST}"
MSYS2_ARG_CONV_EXCL="-DCMAKE_INSTALL_PREFIX" \
${MINGW_PREFIX}/bin/cmake.exe \
CFLAGS+=" -D_LARGEFILE_SOURCE=ON -D_FILE_OFFSET_BITS=64" \
${MINGW_PREFIX}/bin/cmake.exe \
-G"MSYS Makefiles" \
-DCMAKE_INSTALL_PREFIX=${MINGW_PREFIX} \
-DBUILD_SHARED_LIBS=OFF \
@@ -48,7 +49,8 @@ build() {
mkdir ${srcdir}/shared-${MINGW_CHOST} && cd "${srcdir}/shared-${MINGW_CHOST}"
MSYS2_ARG_CONV_EXCL="-DCMAKE_INSTALL_PREFIX" \
${MINGW_PREFIX}/bin/cmake.exe \
CFLAGS+=" -D_LARGEFILE_SOURCE=ON -D_FILE_OFFSET_BITS=64" \
${MINGW_PREFIX}/bin/cmake.exe \
-G"MSYS Makefiles" \
-DCMAKE_INSTALL_PREFIX=${MINGW_PREFIX} \
-DBUILD_SHARED_LIBS=ON \

View File

@@ -3,7 +3,7 @@
_realname=cglm
pkgbase=mingw-w64-${_realname}
pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}")
pkgver=0.7.6
pkgver=0.7.7
pkgrel=1
pkgdesc="OpenGL Mathematics (glm) for C (mingw-w64)"
arch=('any')
@@ -14,7 +14,7 @@ makedepends=("${MINGW_PACKAGE_PREFIX}-gcc"
"${MINGW_PACKAGE_PREFIX}-python-sphinx_rtd_theme")
options=(!strip staticlibs !buildflags)
source=("${_realname}-${pkgver}.tar.gz::https://github.com/recp/cglm/archive/v${pkgver}.tar.gz")
sha256sums=('29ff8af4edc03697e36d3e6f99a80b884a80ee09d46055ce45765e5d6b2456d9')
sha256sums=('2614a61cafc5d2e908364795943b9eebc8be3231128e4c77498e9c3448d365cc')
prepare() {
cd "${srcdir}/${_realname}-${pkgver}"

View File

@@ -31,12 +31,12 @@ pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}"
"${MINGW_PACKAGE_PREFIX}-llvm"
"${MINGW_PACKAGE_PREFIX}-openmp"
"${MINGW_PACKAGE_PREFIX}-polly")
pkgver=10.0.0
pkgrel=3
pkgver=10.0.1
pkgrel=1
pkgdesc="C language family frontend for LLVM (mingw-w64)"
arch=('any')
url="https://llvm.org/"
license=("custom:University of Illinois/NCSA Open Source License")
license=("custom:Apache 2.0 with LLVM Exception")
makedepends=("${MINGW_PACKAGE_PREFIX}-cmake>=3.4.3"
"${MINGW_PACKAGE_PREFIX}-z3"
"${MINGW_PACKAGE_PREFIX}-libffi"
@@ -44,6 +44,7 @@ makedepends=("${MINGW_PACKAGE_PREFIX}-cmake>=3.4.3"
"${MINGW_PACKAGE_PREFIX}-python-sphinx"
"${MINGW_PACKAGE_PREFIX}-python"
"${MINGW_PACKAGE_PREFIX}-swig"
"${MINGW_PACKAGE_PREFIX}-uasm"
"tar"
"groff"
$([[ "$_compiler" == "clang" ]] && echo \
@@ -51,8 +52,7 @@ makedepends=("${MINGW_PACKAGE_PREFIX}-cmake>=3.4.3"
$([[ "$_generator" == "Ninja" ]] && echo \
"${MINGW_PACKAGE_PREFIX}-ninja")
)
depends=("${MINGW_PACKAGE_PREFIX}-gcc"
"${MINGW_PACKAGE_PREFIX}-uasm")
depends=("${MINGW_PACKAGE_PREFIX}-gcc")
options=('!debug' 'strip')
#_url=https://releases.llvm.org
_url=https://github.com/llvm/llvm-project/releases/download/llvmorg-${pkgver}
@@ -103,29 +103,29 @@ source=(${_url}/llvm-${pkgver}.src.tar.xz{,.sig}
#0701-0799 -> libc++abi
#0801-0899 -> polly
#0901-0999 -> openmp
sha256sums=('df83a44b3a9a71029049ec101fb0077ecbbdf5fe41e395215025779099a98fdf'
sha256sums=('c5d8e30b57cbded7128d78e5e8dad811bff97a8d471896812f57fa99ee82cdf3'
'SKIP'
'3b9ff29a45d0509a1e9667a0feb43538ef402ea8cfc7df3758a01f20df08adfa'
'd19f728c8e04fb1e94566c8d76aef50ec926cd2f95ef3bf1e0a5de4909b28b44'
'SKIP'
'885b062b00e903df72631c5f98b9579ed1ed2790f74e5646b4234fa084eacb21'
'f99afc382b88e622c689b6d96cadfa6241ef55dca90e87fc170352e12ddb2b24'
'SKIP'
'6a7da64d3a0a7320577b68b9ca4933bdcab676e898b759850e827333c3282c75'
'd90dc8e121ca0271f0fd3d639d135bfaa4b6ed41e67bd6eb77808f72629658fa'
'SKIP'
'2bcf0f76263572bf45bf7c552e3eae886ec2f315bbc529f3a68603bfc1d13b33'
'3418a2d6fd32f4fa2901e740c4a90b512675a941639cdbb9becfbbdc8981f5f1'
'SKIP'
'270f8a3f176f1981b0f6ab8aa556720988872ec2b48ed3b605d0ced8d09156c7'
'def674535f22f83131353b3c382ccebfef4ba6a35c488bdb76f10b68b25be86c'
'SKIP'
'e71bac75a88c9dde455ad3f2a2b449bf745eafd41d2d8432253b2964e0ca14e1'
'a97ef810b2e9fb70e8f7e317b74e646ed4944f488b02ac5ddd9c99e385381a7b'
'SKIP'
'acdf8cf6574b40e6b1dabc93e76debb84a9feb6f22970126b04d4ba18b92911c'
'd093782bcfcd0c3f496b67a5c2c997ab4b85816b62a7dd5b27026634ccf5c11a'
'SKIP'
'b9a0d7c576eeef05bc06d6e954938a01c5396cee1d1e985891e0b1cf16e3d708'
'591449e0aa623a6318d5ce2371860401653c48bb540982ccdd933992cb88df7a'
'SKIP'
'dd1ffcb42ed033f5167089ec4c6ebe84fbca1db4a9eaebf5c614af09d89eb135'
'07abe87c25876aa306e73127330f5f37d270b6b082d50cc679e31b4fc02a3714'
'SKIP'
'09dc5ecc4714809ecf62908ae8fe8635ab476880455287036a2730966833c626'
'741903ec1ebff2253ff19d803629d88dc7612598758b6e48bea2da168de95e27'
'SKIP'
'35fba6ed628896fe529be4c10407f1b1c8a7264d40c76bced212180e701b4d97'
'd2fb0bb86b21db1f52402ba231da7c119c35c21dfb843c9496fe901f2d6aa25a'
'SKIP'
'9b6d3ecb0ef4a38d34aefaefff8c6257ff22d366d84630020d7f079dc8065d97'
'1f318c0370357fdf9c54ae6d31bad761b0caa58ac099998937b636309ecb6590'

View File

@@ -0,0 +1,53 @@
# Maintainer: Biswapriyo Nath <nathbappai@gmail.com>
_realname=cpputest
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=4.0
pkgrel=1
pkgdesc="Unit testing and mocking framework for C and C++ (mingw-w64)"
url="https://cpputest.github.io/"
arch=('any')
license=('BSD-3-Clause')
makedepends=("${MINGW_PACKAGE_PREFIX}-cmake"
"${MINGW_PACKAGE_PREFIX}-ninja")
options=('staticlibs' 'strip')
source=("https://github.com/cpputest/cpputest/releases/download/v${pkgver}/${_realname}-${pkgver}.tar.gz")
sha512sums=('69f39fffdcd965c871e598118db38ddb74a3e75fd7a7965f8d236029fa891f6fcb6b671147c166ad08482bbd0737537fafe90aa8439a0ab62389f19150cc39d7')
build() {
[[ -d ${srcdir}/build-${MINGW_CHOST} ]] && rm -rf ${srcdir}/build-${MINGW_CHOST}
mkdir -p build-${MINGW_CHOST} && cd build-${MINGW_CHOST}
declare -a extra_config
if check_option "debug" "n"; then
extra_config+=("-DCMAKE_BUILD_TYPE=Release")
else
extra_config+=("-DCMAKE_BUILD_TYPE=Debug")
fi
MSYS2_ARG_CONV_EXCL="-DCMAKE_INSTALL_PREFIX=" \
${MINGW_PREFIX}/bin/cmake \
-G Ninja \
-DCMAKE_INSTALL_PREFIX=${MINGW_PREFIX} \
"${extra_config[@]}" \
-DC++11=ON \
-DTESTS=ON \
-DEXAMPLES=ON \
../${_realname}-${pkgver}
${MINGW_PREFIX}/bin/cmake --build ./
}
check() {
cd ${srcdir}/build-${MINGW_CHOST}
${MINGW_PREFIX}/bin/ctest ./ || true
}
package() {
cd ${srcdir}/build-${MINGW_CHOST}
DESTDIR="${pkgdir}" ${MINGW_PREFIX}/bin/cmake --build ./ --target install
install -Dm644 ${srcdir}/${_realname}-${pkgver}/README.md ${pkgdir}${MINGW_PREFIX}/share/doc/${_realname}/README.md
install -Dm644 ${srcdir}/${_realname}-${pkgver}/COPYING ${pkgdir}${MINGW_PREFIX}/share/licenses/${_realname}/COPYING
}

View File

@@ -0,0 +1,60 @@
--- a/configure.ac
+++ b/configure.ac
@@ -41,9 +41,9 @@
dnl Fallback to the old libusb
dnl libusb >= 0.1.8 is required, as we need usb_interrupt_read()
AS_ECHO("using libusb");
- AC_CHECK_HEADER(usb.h,
- AC_CHECK_LIB(usb, usb_interrupt_read,
- [LIBS="$LIBS -lusb"
+ AC_CHECK_HEADER(lusb0_usb.h,
+ AC_CHECK_LIB(usb0, usb_interrupt_read,
+ [LIBS="$LIBS -lusb0"
HAVE_USB=yes]))
fi
--- a/src/dfu-device.h
+++ b/src/dfu-device.h
@@ -8,7 +8,7 @@
#ifdef HAVE_LIBUSB_1_0
#include <libusb.h>
#else
-#include <usb.h>
+#include <lusb0_usb.h>
#endif
// Atmel device classes are now defined with one bit per class.
--- a/src/dfu.c
+++ b/src/dfu.c
@@ -29,7 +29,7 @@
#ifdef HAVE_LIBUSB_1_0
#include <libusb.h>
#else
-#include <usb.h>
+#include <lusb0_usb.h>
#endif
#include <errno.h>
#include "dfu.h"
--- a/src/dfu.h
+++ b/src/dfu.h
@@ -27,7 +27,7 @@
#ifdef HAVE_LIBUSB_1_0
#include <libusb.h>
#else
-#include <usb.h>
+#include <lusb0_usb.h>
#endif
#include <stdint.h>
#include <stddef.h>
--- a/src/main.c
+++ b/src/main.c
@@ -26,7 +26,7 @@
#ifdef HAVE_LIBUSB_1_0
#include <libusb.h>
#else
-#include <usb.h>
+#include <lusb0_usb.h>
#endif
#include "config.h"

View File

@@ -0,0 +1,41 @@
# Maintainer: fauxpark <fauxpark@gmail.com>
_realname=dfu-programmer
pkgbase=mingw-w64-${_realname}
pkgname=${MINGW_PACKAGE_PREFIX}-${_realname}
pkgver=0.7.2
pkgrel=2
pkgdesc='Device firmware update based USB programmer for Atmel chips (mingw-w64)'
arch=('any')
license=('GPL')
url='https://github.com/dfu-programmer/dfu-programmer'
depends=("${MINGW_PACKAGE_PREFIX}-libusb-win32")
source=(
"https://downloads.sourceforge.net/project/dfu-programmer/dfu-programmer/${pkgver}/dfu-programmer-${pkgver}.tar.gz"
01-use-libusb-win32.patch
)
sha256sums=(
'1db4d36b1aedab2adc976e8faa5495df3cf82dc4bf883633dc6ba71f7c4af995'
'7c8d27dbc8b24aefa54514594711301852741021623b25af136271d767a0fdc8'
)
prepare() {
cd ${srcdir}/${_realname}-${pkgver}
patch -p1 -i ../01-use-libusb-win32.patch
}
build() {
cd ${srcdir}/${_realname}-${pkgver}
./bootstrap.sh
./configure \
--prefix=${MINGW_PREFIX} \
--disable-libusb_1_0
}
package() {
cd ${srcdir}/${_realname}-${pkgver}
make DESTDIR="$pkgdir" install
}

View File

@@ -0,0 +1,26 @@
# Maintainer: fauxpark <fauxpark@gmail.com>
_realname=dfu-util
pkgbase=mingw-w64-${_realname}
pkgname=${MINGW_PACKAGE_PREFIX}-${_realname}
pkgver=0.9
pkgrel=1
pkgdesc='Device firmware upgrade utilities (mingw-w64)'
arch=('any')
license=('GPL2')
url='http://dfu-util.sourceforge.net/'
depends=("${MINGW_PACKAGE_PREFIX}-libusb")
source=("https://downloads.sourceforge.net/project/dfu-util/dfu-util-${pkgver}.tar.gz")
sha256sums=('36428c6a6cb3088cad5a3592933385253da5f29f2effa61518ee5991ea38f833')
build() {
cd ${srcdir}/${_realname}-${pkgver}
./configure --prefix=${MINGW_PREFIX}
}
package() {
cd ${srcdir}/${_realname}-${pkgver}
make DESTDIR="$pkgdir" install
}

View File

@@ -4,15 +4,16 @@
_realname=emacs
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=26.3
pkgrel=3
pkgver=27.1
pkgrel=1
pkgdesc="The extensible, customizable, self-documenting, real-time display editor (mingw-w64)"
url="https://www.gnu.org/software/${_realname}/"
license=('GPL3')
arch=('any')
depends=("${MINGW_PACKAGE_PREFIX}-ctags"
depends=("${MINGW_PACKAGE_PREFIX}-universal-ctags-git"
"${MINGW_PACKAGE_PREFIX}-zlib"
"${MINGW_PACKAGE_PREFIX}-xpm-nox"
"${MINGW_PACKAGE_PREFIX}-harfbuzz"
"${MINGW_PACKAGE_PREFIX}-gnutls"
"${MINGW_PACKAGE_PREFIX}-libwinpthread")
optdepends=("${MINGW_PACKAGE_PREFIX}-giflib"
@@ -20,7 +21,11 @@ optdepends=("${MINGW_PACKAGE_PREFIX}-giflib"
"${MINGW_PACKAGE_PREFIX}-libpng"
"${MINGW_PACKAGE_PREFIX}-librsvg"
"${MINGW_PACKAGE_PREFIX}-libtiff"
"${MINGW_PACKAGE_PREFIX}-imagemagick"
# ImageMagick is considered unsafe and unstable. See
# INSTALL file on Emacs top source directory. If
# ImageMagick support is restored, check if the patch in
# image.c.diff is still necessary:
# "${MINGW_PACKAGE_PREFIX}-imagemagick"
"${MINGW_PACKAGE_PREFIX}-libxml2")
makedepends=("${MINGW_PACKAGE_PREFIX}-gcc"
"${MINGW_PACKAGE_PREFIX}-pkg-config"
@@ -32,18 +37,13 @@ makedepends=("${MINGW_PACKAGE_PREFIX}-gcc"
# Don't zip info files because the built-in info reader uses gzip to
# decompress them. gzip is not available as a mingw binary.
options=('strip' '!zipman')
source=("https://ftp.gnu.org/gnu/${_realname}/${_realname}-${pkgver}.tar.xz"{,.sig}
'image.c.diff'
'lread.c.diff')
sha256sums=('4D90E6751AD8967822C6E092DB07466B9D383EF1653FEB2F95C93E7DE66D3485'
'SKIP'
'4571d45ec26fd556e73a70bb0ab0a2a8fa1efc5e3b3c5b472ab68bb7dc9bf52c'
'24b2201aa2e965c759cfc9539aa4b610d97f1d0240d9888e335da490b87b84b5')
source=("https://ftp.gnu.org/gnu/${_realname}/${_realname}-${pkgver}.tar.xz"{,.sig})
sha256sums=('4a4c128f915fc937d61edfc273c98106711b540c9be3cd5d2e2b9b5b2f172e41'
'SKIP')
validpgpkeys=('28D3BED851FDF3AB57FEF93C233587A47C207910')
prepare() {
cd "${_realname}-${pkgver}"
patch --binary --forward -p0 < "${srcdir}/image.c.diff"
patch --binary --forward -p0 < "${srcdir}/lread.c.diff"
./autogen.sh
}
@@ -52,8 +52,6 @@ build() {
mkdir -p "${srcdir}/build-${MINGW_CHOST}"
cd "build-${MINGW_CHOST}"
LDFLAGS+=" -fstack-protector"
../${_realname}-${pkgver}/configure \
--prefix="${MINGW_PREFIX}" \
--build="${MINGW_CHOST}" \

View File

@@ -1,15 +0,0 @@
--- src/lread.c.orig 2014-11-04 20:29:22.129549000 +0100
+++ src/lread.c 2014-11-04 22:33:07.346414100 +0100
@@ -4323,6 +4323,12 @@
} /* Vinstallation_directory != Vsource_directory */
} /* if Vinstallation_directory */
+ else
+ {
+ Vsource_directory
+ = Fexpand_file_name (build_string ("../"),
+ Fcar (decode_env_path (0, PATH_DATA, 0)));
+ }
}
else /* !initialized */
{

View File

@@ -3,18 +3,20 @@
_realname=FAudio
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=20.06
pkgver=20.08
pkgrel=1
pkgdesc="FAudio - Accuracy-focused XAudio reimplementation for open platforms (mingw-w64)"
arch=('any')
url="https://github.com/FNA-XNA/FAudio"
license=('custom')
makedepends=("${MINGW_PACKAGE_PREFIX}-cmake"
"${MINGW_PACKAGE_PREFIX}-ffmpeg"
"${MINGW_PACKAGE_PREFIX}-SDL2")
depends=("${MINGW_PACKAGE_PREFIX}-SDL2"
"${MINGW_PACKAGE_PREFIX}-glib2"
"${MINGW_PACKAGE_PREFIX}-gstreamer"
"${MINGW_PACKAGE_PREFIX}-gst-plugins-base")
makedepends=("${MINGW_PACKAGE_PREFIX}-cmake")
options=('strip' 'staticlibs')
source=(${_realname}-${pkgver}.tar.gz::"https://github.com/FNA-XNA/FAudio/archive/${pkgver}.tar.gz")
sha256sums=('d6e89e1d5d2a95e2c2759318c6dba6ecd922c452668996e6e7e40294c3875725')
sha256sums=('5c3409fa0e532591f0ab4de1ae57d07cc345efa5cbe83ec25e9f5ba180f920f4')
build() {
[[ -d "${srcdir}"/build-${CARCH} ]] && rm -rf "${srcdir}"/build-${CARCH}
@@ -30,7 +32,7 @@ build() {
MSYS2_ARG_CONV_EXCL="-DCMAKE_INSTALL_PREFIX=" \
${MINGW_PREFIX}/bin/cmake \
-G'MSYS Makefiles' \
-DFFMPEG=ON \
-DGSTREAMER=ON \
-DCMAKE_INSTALL_PREFIX=${MINGW_PREFIX} \
"${extra_config[@]}" \
../${_realname}-${pkgver}

View File

@@ -5,7 +5,7 @@
_realname=fmt
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=7.0.2
pkgver=7.0.3
pkgrel=1
pkgdesc="A small, safe and fast formatting library for C++ (mingw-w64)"
arch=('any')
@@ -16,7 +16,7 @@ makedepends=("${MINGW_PACKAGE_PREFIX}-gcc"
depends=("${MINGW_PACKAGE_PREFIX}-gcc-libs")
options=('staticlibs')
source=("${_realname}-${pkgver}.tar.gz::https://github.com/fmtlib/${_realname}/archive/${pkgver}.tar.gz")
sha256sums=('7697e022f9cdc4f90b5e0a409643faa2cde0a6312f85e575c8388a1913374de5')
sha256sums=('b4b51bc16288e2281cddc59c28f0b4f84fed58d016fb038273a09f05f8473297')
build() {
# Shared Build

View File

@@ -0,0 +1,122 @@
From fcada522913e5e07efa6367eff87ace9f06d24c8 Mon Sep 17 00:00:00 2001
From: Akira TAGOH <akira@tagoh.org>
Date: Wed, 28 Aug 2019 17:46:03 +0900
Subject: [PATCH] Do not return FcFalse from FcConfigParseAndLoad*() if
complain is set to false
https://bugzilla.redhat.com/show_bug.cgi?id=1744377
---
src/fcxml.c | 8 ++++---
test/Makefile.am | 4 ++++
test/test-bz1744377.c | 51 +++++++++++++++++++++++++++++++++++++++++++
3 files changed, 60 insertions(+), 3 deletions(-)
create mode 100644 test/test-bz1744377.c
diff --git a/src/fcxml.c b/src/fcxml.c
index 2e26e77a..076fa301 100644
--- a/src/fcxml.c
+++ b/src/fcxml.c
@@ -3526,7 +3526,7 @@ _FcConfigParse (FcConfig *config,
int len;
FcStrBuf sbuf;
char buf[BUFSIZ];
- FcBool ret = FcFalse;
+ FcBool ret = FcFalse, complain_again = complain;
#ifdef _WIN32
if (!pGetSystemWindowsDirectory)
@@ -3605,7 +3605,7 @@ _FcConfigParse (FcConfig *config,
close (fd);
ret = FcConfigParseAndLoadFromMemoryInternal (config, filename, FcStrBufDoneStatic (&sbuf), complain, load);
- complain = FcFalse; /* no need to reclaim here */
+ complain_again = FcFalse; /* no need to reclaim here */
bail1:
FcStrBufDestroy (&sbuf);
bail0:
@@ -3613,7 +3613,9 @@ bail0:
FcStrFree (filename);
if (realfilename)
FcStrFree (realfilename);
- if (!ret && complain)
+ if (!complain)
+ return FcTrue;
+ if (!ret && complain_again)
{
if (name)
FcConfigMessage (0, FcSevereError, "Cannot %s config file \"%s\"", load ? "load" : "scan", name);
diff --git a/test/Makefile.am b/test/Makefile.am
index f9c21581..a9fa089a 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -131,6 +131,10 @@ TESTS += test-d1f48f11
endif
endif
+check_PROGRAMS += test-bz1744377
+test_bz1744377_LDADD = $(top_builddir)/src/libfontconfig.la
+TESTS += test-bz1744377
+
EXTRA_DIST=run-test.sh run-test-conf.sh $(LOG_COMPILER) $(TESTDATA) out.expected-long-family-names out.expected-no-long-family-names
CLEANFILES=out out1 out2 fonts.conf out.expected
diff --git a/test/test-bz1744377.c b/test/test-bz1744377.c
new file mode 100644
index 00000000..d7f10535
--- /dev/null
+++ b/test/test-bz1744377.c
@@ -0,0 +1,51 @@
+/*
+ * fontconfig/test/test-bz1744377.c
+ *
+ * Copyright © 2000 Keith Packard
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation, and that the name of the author(s) not be used in
+ * advertising or publicity pertaining to distribution of the software without
+ * specific, written prior permission. The authors make no
+ * representations about the suitability of this software for any purpose. It
+ * is provided "as is" without express or implied warranty.
+ *
+ * THE AUTHOR(S) DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
+ * EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY SPECIAL, INDIRECT OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
+ * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
+ * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
+ * PERFORMANCE OF THIS SOFTWARE.
+ */
+#include <fontconfig/fontconfig.h>
+
+int
+main (void)
+{
+ const FcChar8 *doc = ""
+ "<fontconfig>\n"
+ " <include ignore_missing=\"yes\">blahblahblah</include>\n"
+ "</fontconfig>\n"
+ "";
+ const FcChar8 *doc2 = ""
+ "<fontconfig>\n"
+ " <include ignore_missing=\"no\">blahblahblah</include>\n"
+ "</fontconfig>\n"
+ "";
+ FcConfig *cfg = FcConfigCreate ();
+
+ if (!FcConfigParseAndLoadFromMemory (cfg, doc, FcTrue))
+ return 1;
+ if (FcConfigParseAndLoadFromMemory (cfg, doc2, FcTrue))
+ return 1;
+ if (!FcConfigParseAndLoadFromMemory (cfg, doc2, FcFalse))
+ return 1;
+
+ FcConfigDestroy (cfg);
+
+ return 0;
+}
--
GitLab

View File

@@ -5,7 +5,7 @@ _realname=fontconfig
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=2.13.92
pkgrel=1
pkgrel=2
pkgdesc="A library for configuring and customizing font access (mingw-w64)"
arch=('any')
url="https://wiki.freedesktop.org/www/Software/fontconfig/"
@@ -26,13 +26,15 @@ source=("https://www.freedesktop.org/software/fontconfig/release/fontconfig-${pk
0002-fix-mkdir.mingw.patch
0004-fix-mkdtemp.mingw.patch
0005-fix-setenv.mingw.patch
0007-pkgconfig.mingw.patch)
0007-pkgconfig.mingw.patch
0008-fix-font-search.patch)
sha256sums=('506e61283878c1726550bc94f2af26168f1e9f2106eac77eaaf0b2cdfad66e4e'
'1266d4bbd8270f013fee2401c890f0251babf50a175a69d681d3a6af5003c899'
'0d950eb8a19858bff1f0b26e4a560f589e79e7eb7f22f723267748dfe55e0b63'
'57ff8420dbf62873b6fcb38b52fb7b37e0e278425a9125e15dccba54668c8ab9'
'552b54010f9fe4097f332cf2397bbd3e78489542d3bbf07792ed1cfe9381796e'
'af373531873da46d0356305da5444c1ec74f443cd2635ea2db6b7dadd1561f5b')
'af373531873da46d0356305da5444c1ec74f443cd2635ea2db6b7dadd1561f5b'
'557bfa2c83746da9d3d2be956c3c6906e80625c324d64eb7504d8c5164c2eca3')
prepare() {
cd "${srcdir}"/${_realname}-${pkgver}
@@ -42,6 +44,8 @@ prepare() {
patch -p1 -i ${srcdir}/0004-fix-mkdtemp.mingw.patch
patch -p1 -i ${srcdir}/0005-fix-setenv.mingw.patch
patch -p1 -i ${srcdir}/0007-pkgconfig.mingw.patch
# https://github.com/msys2/MINGW-packages/issues/6661#issuecomment-674536893
patch -p1 -i ${srcdir}/0008-fix-font-search.patch
autoreconf -fiv
}

View File

@@ -19,6 +19,7 @@ source=(https://ftp.gnu.org/gnu/gdbm/${_realname}-${pkgver}.tar.gz{,.sig}
sha256sums=('86e613527e5dba544e73208f42b78b7c022d4fa5a6d5498bf18c8d6f745b91dc'
'SKIP'
'f6398a1a00839bed53565b6fae857a94ee6d12aaccd2a1e87b35203994a6ecd0')
validpgpkeys=('325F650C4C2B6AD58807327A3602B07F55D0C732')
prepare() {
cd ${srcdir}/${_realname}-${pkgver}

View File

@@ -6,11 +6,11 @@
_realname=glib2
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=2.64.3
pkgver=2.64.4
pkgrel=1
url="https://www.gtk.org/"
arch=('any')
pkgdesc="Common C routines used by GTK+ 2.4 and other libs (mingw-w64)"
pkgdesc="Common C routines used by GTK+ 3 and other libs (mingw-w64)"
license=(LGPL2)
install=glib2-${CARCH}.install
depends=("${MINGW_PACKAGE_PREFIX}-gcc-libs"
@@ -31,7 +31,7 @@ source=("https://download.gnome.org/sources/glib/${pkgver%.*}/glib-${pkgver}.tar
gio-querymodules.hook.in
0002-disable_glib_compile_schemas_warning.patch
pyscript2exe.py)
sha256sums=('fe9cbc97925d14c804935f067a3ad77ef55c0bbe9befe68962318f5a767ceb22'
sha256sums=('f7e0b325b272281f0462e0f7fff25a833820cac19911ff677251daf6d87bce50'
'51d02360a1ee978fd45e77b84bca9cfbcf080d91986b5c0efe0732779c6a54ec'
'1e3ac7cfd4644f3849704e54fcfbb12d15440a33cd5c2d014d4a479c6aaab185'
'0f44135a139e3951c4b5fa7d4628d75226e0666d891faf524777e1d1ec3b440b'

View File

@@ -4,7 +4,7 @@ _realname=gmic
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=2.9.0
pkgrel=2
pkgrel=3
pkgdesc="A Full-Featured Open-Source Framework for Image Processing (mingw-w64)"
arch=(any)
url="https://gmic.eu"

View File

@@ -8,6 +8,12 @@ pkgbase=mingw-w64-${_realname}-git
pkgname=${MINGW_PACKAGE_PREFIX}-${_realname}-git
pkgver=r3576.43e55df6
pkgrel=1
_gprbuild_commit="43e55df6c26e2bd48ab6c2f4214f497c4ddbc943"
_gprbuild_extract_dir="AdaCore-gprbuild-43e55df"
_xmlada_commit="c16f24ebf752b7d75dfdd0eaa7dd501a08a31256"
_xmlada_extract_dir="AdaCore-xmlada-c16f24e"
pkgdesc="Static GPRbuild to bootstrap XML/Ada and GPRbuild itself (mingw-w64)"
arch=('any')
url='https://github.com/AdaCore/gprbuild/'
@@ -19,18 +25,18 @@ provides=("${MINGW_PACKAGE_PREFIX}-gprbuild-bootstrap")
conflicts=("${MINGW_PACKAGE_PREFIX}-gprbuild"
"${MINGW_PACKAGE_PREFIX}-gprbuild-gpl"
"${MINGW_PACKAGE_PREFIX}-gprbuild-bootstrap")
source=('git+https://github.com/AdaCore/gprbuild.git'
'git+https://github.com/AdaCore/xmlada.git')
sha256sums=('SKIP'
'SKIP')
source=("gprbuild.tar.gz::https://api.github.com/repos/AdaCore/gprbuild/tarball/${_gprbuild_commit}"
"xmlada.tar.gz::https://api.github.com/repos/AdaCore/xmlada/tarball/${_xmlada_commit}")
sha256sums=('d4491ae831ce3ab89ea930cc58280372325476046054cf64691bda867a52b028'
'12139d8c3d511b516f9dcf68ee76a70f2dc52031d379e9e4942aa84346974751')
pkgver() {
cd "${srcdir}/gprbuild"
cd "${srcdir}/${_gprbuild_extract_dir}"
printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}
prepare() {
cd "${srcdir}/gprbuild"
cd "${srcdir}/${_gprbuild_extract_dir}"
# GPRbuild hard-codes references to ${MINGW_PREFIX}/libexec, but MINGW packages
# must use ${MINGW_PREFIX}/lib instead.
@@ -41,14 +47,14 @@ prepare() {
}
build() {
cd "${srcdir}/gprbuild"
cd "${srcdir}/${_gprbuild_extract_dir}"
export GNATMAKEFLAGS="-j$(nproc)"
export DESTDIR="${srcdir}/bootstrap"
./bootstrap.sh \
--prefix=${MINGW_PREFIX} \
--libexecdir=/lib \
--with-xmlada="${srcdir}/xmlada"
--with-xmlada="${srcdir}/${_xmlada_extract_dir}"
}
package() {

View File

@@ -1,14 +1,18 @@
# Maintainer: Jürgen Pfeifer <juergen@familiepfeifer.de>
# Contributor: Tim S <stahta01@gmail.com>
_realname=gprbuild-gpl
_realname=gprbuild
pkgbase=mingw-w64-${_realname}
pkgname=${MINGW_PACKAGE_PREFIX}-${_realname}
pkgver=2020.0.43e55df
pkgrel=1
_gprbuild_commit="43e55df6c26e2bd48ab6c2f4214f497c4ddbc943"
_gprbuild_extract_dir="AdaCore-gprbuild-43e55df"
pkgdesc="Software tool designed to help automate the construction of multi-language systems (mingw-w64)"
arch=('any')
provides=("${MINGW_PACKAGE_PREFIX}-${_realname%-*}")
replaces=("${MINGW_PACKAGE_PREFIX}-gprbuild-gpl")
license=('GPL3')
url="https://www.adacore.com/gnatpro/toolsuite/gprbuild/"
makedepends=("${MINGW_PACKAGE_PREFIX}-gcc-ada"
@@ -17,25 +21,25 @@ makedepends=("${MINGW_PACKAGE_PREFIX}-gcc-ada"
depends=("${MINGW_PACKAGE_PREFIX}-gcc-ada"
"${MINGW_PACKAGE_PREFIX}-xmlada")
conflicts=("${MINGW_PACKAGE_PREFIX}-gprbuild-bootstrap")
source=("${_realname}"::"git+https://github.com/AdaCore/gprbuild.git#commit=43e55df6c26e2bd48ab6c2f4214f497c4ddbc943")
sha256sums=('SKIP')
source=("gprbuild.tar.gz::https://api.github.com/repos/AdaCore/gprbuild/tarball/${_gprbuild_commit}")
sha256sums=('d4491ae831ce3ab89ea930cc58280372325476046054cf64691bda867a52b028')
prepare() {
cd ${srcdir}/gprbuild-gpl
cd "${srcdir}/${_gprbuild_extract_dir}"
#./bootstrap.sh
}
build() {
cd ${srcdir}/gprbuild-gpl
cd "${srcdir}/${_gprbuild_extract_dir}"
make SOURCE_DIR="$PWD" prefix=${MINGW_PREFIX} setup
make
make
}
package() {
cd ${srcdir}/gprbuild-gpl
cd "${srcdir}/${_gprbuild_extract_dir}"
make prefix="${pkgdir}${MINGW_PREFIX}" INSTALL=cp install
# Copy License Files

View File

@@ -3,7 +3,7 @@
_realname=gr
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=0.50.0
pkgver=0.51.2
pkgrel=1
pkgdesc="A graphics library for visualisation applications (mingw-w64)"
arch=("any")
@@ -24,11 +24,9 @@ makedepends=("git"
"${MINGW_PACKAGE_PREFIX}-cmake"
"${MINGW_PACKAGE_PREFIX}-gcc")
options=("staticlibs" "strip" "!buildflags")
source=("${_realname}-${pkgver}.tar.gz::https://github.com/sciapp/gr/archive/v${pkgver}.tar.gz"
"https://github.com/kou/gr/commit/20204e37d8411b19b69a7ee5c776035c07f7175d.patch")
source=("${_realname}-${pkgver}.tar.gz::https://github.com/sciapp/gr/archive/v${pkgver}.tar.gz")
noextract=("${_realname}-${pkgver}.tar.gz")
sha256sums=("59947975c364b8ce98940eee4cf98a665ede66083362e60f3e3520d9c7d8bc1e"
"db6fc6d88700bb918cf548e897a609c78ffa3f52abfa21a31e67316500d1393e")
sha256sums=("E6A3D0ED911F6E59CC2293B5694EE18A0620849E666143870A9EDA71C02BB833")
prepare() {
# We can't use bsdtar to extract the archive because the archive includes
@@ -36,9 +34,6 @@ prepare() {
cd "${srcdir}/"
rm -rf "${_realname}-${pkgver}"
tar -xf "${_realname}-${pkgver}.tar.gz"
cd "${srcdir}/${_realname}-${pkgver}/"
patch -p1 -i "${srcdir}/20204e37d8411b19b69a7ee5c776035c07f7175d.patch"
}
build() {

View File

@@ -4,7 +4,8 @@ _realname=graphviz
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=2.40.1
pkgrel=11
_commit='67cd2e5121379a38e0801cc05cce503' # stable_release_2.40.1
pkgrel=13
pkgdesc="Graph Visualization Software (mingw-w64)"
arch=('any')
url='https://www.graphviz.org/'
@@ -31,14 +32,14 @@ depends=("${MINGW_PACKAGE_PREFIX}-cairo"
makedepends=(#"${MINGW_PACKAGE_PREFIX}-ocaml"
#"${MINGW_PACKAGE_PREFIX}-lua"
"${MINGW_PACKAGE_PREFIX}-pkg-config"
"${MINGW_PACKAGE_PREFIX}-python2"
#"${MINGW_PACKAGE_PREFIX}-python"
#"${MINGW_PACKAGE_PREFIX}-ruby"
#"${MINGW_PACKAGE_PREFIX}-tcl"
"${MINGW_PACKAGE_PREFIX}-zlib"
"git")
options=(libtool)
install=${_realname}-${CARCH}.install
source=(${_realname}-${pkgver}::git+https://gitlab.com/graphviz/graphviz.git#tag=stable_release_${pkgver}
source=(${_realname}-${pkgver}::git+https://gitlab.com/graphviz/graphviz.git#commit=${_commit}
#https://graphviz.gitlab.io/pub/graphviz/stable/SOURCES/graphviz.tar.gz
#"https://www.graphviz.org/pub/${_realname}/stable/SOURCES/${_realname}-${pkgver}.tar.gz"
001-msvc-pragma.patch.patch
@@ -83,6 +84,7 @@ build() {
local gd_incdir=$(pkg-config --variable=includedir gdlib)
CFLAGS+=" -Wno-sign-conversion -Wno-sign-compare -Wno-conversion"
CXXFLAGS+=" -Wno-sign-conversion -Wno-sign-compare -Wno-conversion"
CFLAGS+=" -fcommon" # GCC10 is stricter, change to the previous default
[[ -d "${srcdir}"/build-${CARCH} ]] && rm -rf "${srcdir}"/build-${CARCH}
mkdir -p "${srcdir}"/build-${CARCH} && cd "${srcdir}"/build-${CARCH}
../${_realname}-${pkgver}/configure \

View File

@@ -4,7 +4,7 @@
_realname=grep
pkgbase=mingw-w64-${_realname}
pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}")
pkgver=2.24
pkgver=3.4
pkgrel=1
pkgdesc="Grep searches one or more input files for lines containing a match to a specified pattern (mingw-w64)"
arch=('any')
@@ -13,7 +13,7 @@ license=('GPL3')
depends=("${MINGW_PACKAGE_PREFIX}-pcre")
options=('strip' '!libtool' 'staticlibs')
source=("https://ftp.gnu.org/gnu/${_realname}/${_realname}-${pkgver}.tar.xz")
sha256sums=('f248beb9098c5aab94d2fdd03b5a21d705e5ba8a3ce4d8c9f607a670498eec14')
sha256sums=('58e6751c41a7c25bfc6e9363a41786cff3ba5709cf11d5ad903cf7cce31cc3fb')
prepare() {
cd ${srcdir}/${_realname}-${pkgver}

View File

@@ -3,7 +3,7 @@
_realname=groonga
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=10.0.4
pkgver=10.0.5
pkgrel=1
pkgdesc="An opensource fulltext search engine (mingw-w64)"
arch=('any')
@@ -26,7 +26,7 @@ depends=("${MINGW_PACKAGE_PREFIX}-arrow"
"${MINGW_PACKAGE_PREFIX}-zlib"
"${MINGW_PACKAGE_PREFIX}-zstd")
makedepends=("${MINGW_PACKAGE_PREFIX}-gcc")
sha256sums=('32d3c98978030b165aa7ff0e8d8e44635775fe6afc8264712f2e210c25dec9bd')
sha256sums=('e0d60ecbf441f86fe8a7e2448ec2e5b1e0a9f26405a71258abb2940d69c53213')
build() {
[[ -d ${srcdir}/build-${CARCH} ]] && rm -rf ${srcdir}/build-${CARCH}

View File

@@ -1,25 +0,0 @@
From 2c67d0d2f05a1dd6f3c9b6c0c7a387d738117052 Mon Sep 17 00:00:00 2001
From: Nicola Murino <nicola.murino@gmail.com>
Date: Thu, 26 Dec 2019 22:43:35 +0100
Subject: [PATCH] opencv: allow compilation against 4.2.x
---
ext/opencv/meson.build | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/ext/opencv/meson.build b/ext/opencv/meson.build
index f38b55dfe..2e1380313 100644
--- a/ext/opencv/meson.build
+++ b/ext/opencv/meson.build
@@ -65,7 +65,7 @@ if opencv_found
endif
endforeach
else
- opencv_dep = dependency('opencv4', version : ['>= 4.0.0', '< 4.2.0'], required : false)
+ opencv_dep = dependency('opencv4', version : ['>= 4.0.0', '< 4.3.0'], required : false)
opencv_found = opencv_dep.found()
if opencv_found
foreach h : libopencv4_headers
--
2.24.1

View File

@@ -1,25 +1,23 @@
From 4cf362e2df0fb809ea0f21dd4a6fbb8b46ca54ef Mon Sep 17 00:00:00 2001
From: Luka Blaskovic <lblasc@znode.net>
Date: Fri, 1 May 2020 07:46:56 +0200
Subject: [PATCH] opencv: allow compilation against 4.3.x
From 8544f3928ea46d2da3f27dc65576e8baf42a46d0 Mon Sep 17 00:00:00 2001
From: Nicola Murino <nicola.murino@gmail.com>
Date: Fri, 31 Jul 2020 23:38:56 +0200
Subject: [PATCH] opencv: allow compilation against 4.4.x
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1235>
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/1482>
---
ext/opencv/meson.build | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/ext/opencv/meson.build b/ext/opencv/meson.build
index d9bc871126..8434628e5f 100644
index 9ee306501a..730a1345fb 100644
--- a/ext/opencv/meson.build
+++ b/ext/opencv/meson.build
@@ -65,7 +65,7 @@ if opencv_found
endif
endforeach
else
- opencv_dep = dependency('opencv4', version : ['>= 4.0.0', '< 4.3.0'], required : false)
+ opencv_dep = dependency('opencv4', version : ['>= 4.0.0', '< 4.4.0'], required : false)
- opencv_dep = dependency('opencv4', version : ['>= 4.0.0', '< 4.2.0'], required : false)
+ opencv_dep = dependency('opencv4', version : ['>= 4.0.0', '< 4.5.0'], required : false)
opencv_found = opencv_dep.found()
if opencv_found
foreach h : libopencv4_headers
--
2.26.2

View File

@@ -6,7 +6,7 @@ _realname=gst-plugins-bad
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=1.16.2
pkgrel=6
pkgrel=8
pkgdesc="GStreamer Multimedia Framework Bad Plugins (mingw-w64)"
arch=('any')
url="https://gstreamer.freedesktop.org/"
@@ -64,18 +64,15 @@ depends=("${MINGW_PACKAGE_PREFIX}-aom"
"${MINGW_PACKAGE_PREFIX}-zbar")
options=(!libtool strip staticlibs)
source=(${url}/src/${_realname}/${_realname}-${pkgver}.tar.xz
0001-opencv-42.patch
0003-meson-lrdf-optional.patch
0004-opencv-version-require.patch)
sha256sums=('f1cb7aa2389569a5343661aae473f0a940a90b872001824bc47fa8072a041e74'
'3201b6b24b426c7f959d491bae0a7151719818ecaa9a891cdd4cb7b3676fd2cc'
'a992cf5fe1d159cf2cfe74556b5fe4018f9bcf421112f07e0e7571aa5bc912a0'
'50455ccf422405fedb3e23f320de3d77452596421e4b7b24f0ac05775e59fb57')
'b664a3291cd62dcfb7ce047c11c2a493e5740b0deedc7cfe03552ceea78bad7f')
prepare() {
cd "${srcdir}"/${_realname}-${pkgver}
patch -p1 -i "${srcdir}"/0001-opencv-42.patch
patch -p1 -i "${srcdir}"/0003-meson-lrdf-optional.patch
patch -p1 -i "${srcdir}"/0004-opencv-version-require.patch
}

View File

@@ -4,7 +4,7 @@
_realname=harfbuzz
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=2.6.8
pkgver=2.7.1
pkgrel=1
pkgdesc="OpenType text shaping engine (mingw-w64)"
arch=('any')
@@ -14,12 +14,12 @@ makedepends=("${MINGW_PACKAGE_PREFIX}-gcc"
"${MINGW_PACKAGE_PREFIX}-icu"
"${MINGW_PACKAGE_PREFIX}-gobject-introspection"
"${MINGW_PACKAGE_PREFIX}-pkg-config"
"${MINGW_PACKAGE_PREFIX}-cairo"
"${MINGW_PACKAGE_PREFIX}-python"
"${MINGW_PACKAGE_PREFIX}-meson"
"${MINGW_PACKAGE_PREFIX}-ninja"
"${MINGW_PACKAGE_PREFIX}-ragel")
depends=("${MINGW_PACKAGE_PREFIX}-cairo"
"${MINGW_PACKAGE_PREFIX}-freetype"
depends=("${MINGW_PACKAGE_PREFIX}-freetype"
"${MINGW_PACKAGE_PREFIX}-gcc-libs"
"${MINGW_PACKAGE_PREFIX}-glib2"
"${MINGW_PACKAGE_PREFIX}-graphite2")
@@ -28,10 +28,12 @@ checkdepends=("${MINGW_PACKAGE_PREFIX}-python-fonttools"
options=('strip' 'staticlibs')
optdepends=("${MINGW_PACKAGE_PREFIX}-icu: harfbuzz-icu support"
"${MINGW_PACKAGE_PREFIX}-cairo: hb-view program")
source=("https://github.com/harfbuzz/harfbuzz/releases/download/${pkgver}/${_realname}-${pkgver}.tar.xz")
sha256sums=('6648a571a27f186e47094121f0095e1b809e918b3037c630c7f38ffad86e3035')
source=("https://github.com/harfbuzz/harfbuzz/archive/${pkgver}.tar.gz")
sha256sums=('431c856ff18eeca89b2a36b58f2c2d56273cd522c34c0ffbc9dd6f7da4b9bd08')
noextract=("${pkgver}.tar.gz")
prepare() {
tar -xzf ${srcdir}/${pkgver}.tar.gz -C ${srcdir} || true
cd "${srcdir}/${_realname}-${pkgver}"
}

View File

@@ -1,9 +1,10 @@
# Maintainer: Øystein Krog <oystein.krog@gmail.com>
# Maintainer: Tom Schoonjans <Tom.Schoonjans@rfi.ac.uk>
_realname=hub
pkgbase=mingw-w64-${_realname}
pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}")
pkgver=2.2.1
pkgver=2.14.2
pkgrel=1
pkgdesc="hub introduces git to GitHub (mingw-w64)"
arch=('any')
@@ -15,22 +16,20 @@ options=('!strip')
depends=('git')
makedepends=("git" "${MINGW_PACKAGE_PREFIX}-go")
source=(${_realname}-${pkgver}.tar.gz::https://github.com/github/${_realname}/archive/v${pkgver}.tar.gz)
sha256sums=('9350aba6a8e3da9d26b7258a4020bf84491af69595f7484f922d75fc8b86dc10')
sha256sums=('e19e0fdfd1c69c401e1c24dd2d4ecf3fd9044aa4bd3f8d6fd942ed1b2b2ad21a')
build() {
cd "${srcdir}/${_realname}-${pkgver}"
GOROOT=${MINGW_PREFIX}/lib/go ./script/build
gzip --best -c man/${_realname}.1> ${_realname}.1.gz
export GOROOT=${MINGW_PREFIX}/lib/go
make
}
package() {
cd "${srcdir}/${_realname}-${pkgver}"
install -Dm755 "${_realname}" "${pkgdir}${MINGW_PREFIX}/bin/${_realname}"
make install prefix=${pkgdir}${MINGW_PREFIX}
install -Dm644 "LICENSE" "${pkgdir}${MINGW_PREFIX}/share/licenses/${_realname}/LICENSE"
install -Dm644 "man/${_realname}.1" "${pkgdir}${MINGWPREFIX}/share/man/man1/${_realname}.1"
install -Dm644 "etc/hub.bash_completion.sh" "${pkgdir}/usr/share/bash-completion/completions/hub"
install -Dm644 "etc/hub.zsh_completion" "${pkgdir}/usr/share/zsh/site-functions/_hub"
}

View File

@@ -20,6 +20,7 @@ sha256sums=('e77d68c0211515459b8812118d606812e300097cfac0b4e9fb3472664263bb8b'
'63c66b49831a90c5191cd3295d17a4e1888d8fa2a0b02589448de3b78d4e0293'
'624ae1c52b01e52dfd4417bb160ef606342f25548fbd90c58ef4962367179750'
'd0ecfbc7cbf694b4222545bbd19d1b81f320ee9f5a2d5bfc86f27fe365f63145')
validpgpkeys=('782130B4C9944247977B82FD6EA4D2311A2D268D')
prepare() {
cd "${srcdir}"/${_realname}-${pkgver}

View File

@@ -1,9 +0,0 @@
diff --git a/src/util/windows.cpp b/src/util/windows.cpp
index 9a978d7..1bebe9c 100644
--- a/src/util/windows.cpp
+++ b/src/util/windows.cpp
@@ -523,3 +523,3 @@ int main() {
// Tell boost::filesystem to interpret our path strings as UTF-8
- boost::filesystem::path::imbue(std::locale(std::locale(), &util::codecvt));
+ boost::filesystem::path::imbue(std::locale(std::locale(), new std::codecvt_utf8_utf16<wchar_t>()));

View File

@@ -3,8 +3,8 @@
_realname=innoextract
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=1.8
pkgrel=2
pkgver=1.9
pkgrel=1
pkgdesc="A tool to extract installers created by Inno Setup (mingw-w64)"
arch=('any')
url="https://constexpr.org/innoextract/"
@@ -19,16 +19,10 @@ depends=("${MINGW_PACKAGE_PREFIX}-gcc-libs"
"${MINGW_PACKAGE_PREFIX}-zlib")
options=('staticlibs' '!strip')
source=("https://constexpr.org/innoextract/files/${_realname}-${pkgver}.tar.gz"
0001-fix-segfault-windows.patch
)
sha256sums=('5e78f6295119eeda08a54dcac75306a1a4a40d0cb812ff3cd405e9862c285269'
'BFBDF47059B1EFDD74F7847679B0ED9B61E00E8A6236BA518C050B43C4D09D2A'
)
prepare() {
cd "${srcdir}/${_realname}-${pkgver}"
patch -p1 -l -i "${srcdir}"/0001-fix-segfault-windows.patch # see https://github.com/dscharrer/innoextract/pull/114 for details
}
sha256sums=('6344A69FC1ED847D4ED3E272E0DA5998948C6B828CB7AF39C6321ABA6CF88126'
)
build() {
[[ -d ${srcdir}/build-${MINGW_CHOST} ]] && rm -rf ${srcdir}/build-${MINGW_CHOST}

View File

@@ -4,7 +4,7 @@ _realname=itk
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=5.1.0
pkgrel=1
pkgrel=2
pkgdesc='An open-source C++ toolkit for medical image processing (mingw-w64)'
arch=('any')
url='https://www.itk.org/'

View File

@@ -4,13 +4,14 @@ _realname=jq
pkgbase=mingw-w64-${_realname}
pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}")
pkgver=1.6
pkgrel=2
pkgrel=3
pkgdesc="Command-line JSON processor (mingw-w64)"
arch=('any')
url='https://stedolan.github.io/jq/'
license=('MIT')
makedepends=("autoconf" "automake" "bison" "flex")
depends=("${MINGW_PACKAGE_PREFIX}-oniguruma")
depends=("${MINGW_PACKAGE_PREFIX}-oniguruma"
"${MINGW_PACKAGE_PREFIX}-libwinpthread")
source=("https://github.com/stedolan/${_realname}/releases/download/${_realname}-${pkgver}/${_realname}-${pkgver}.tar.gz"
no-undefined.patch)
sha256sums=('5de8c8e29aaa3fb9cc6b47bb27299f271354ebb72514e3accadc7d38b5bbaa72'

View File

@@ -1,20 +1,21 @@
--- json-c-json-c-0.14/CMakeLists.txt.orig 2020-04-27 16:22:14.788180700 +0300
+++ json-c-json-c-0.14/CMakeLists.txt 2020-04-27 16:25:33.974302700 +0300
@@ -380,10 +380,16 @@
--- a/CMakeLists.txt 2020-08-03 08:55:10.090125184 -0400
+++ b/CMakeLists.txt 2020-08-03 08:57:21.002463125 -0400
@@ -416,9 +416,17 @@
${JSON_C_SOURCES}
${JSON_C_HEADERS}
)
+
+set(JSON_C_SOVERSION 5)
set_target_properties(${PROJECT_NAME} PROPERTIES
VERSION 5.0.0
VERSION 5.1.0
- SOVERSION 5)
+ SOVERSION ${JSON_C_SOVERSION})
+
+set_target_properties(${PROJECT_NAME} PROPERTIES
+ OUTPUT_NAME ${PROJECT_NAME}
+ RUNTIME_OUTPUT_NAME ${PROJECT_NAME}-${JSON_C_SOVERSION}
+ ARCHIVE_OUTPUT_NAME ${PROJECT_NAME})
+
list(APPEND CMAKE_TARGETS ${PROJECT_NAME})
# If json-c is used as subroject it set to target correct interface -I flags and allow
# to build external target without extra include_directories(...)
target_include_directories(${PROJECT_NAME}

View File

@@ -4,7 +4,7 @@
_realname=json-c
pkgbase=mingw-w64-${_realname}
pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}")
pkgver=0.14
pkgver=0.15
pkgrel=1
arch=('any')
pkgdesc="A JSON implementation in C (mingw-w64)"
@@ -18,9 +18,9 @@ license=('MIT')
source=(https://github.com/json-c/json-c/archive/${_realname}-${pkgver//_/-}.tar.gz
001-install-private-header.patch
002-library-version.patch)
sha256sums=('7eccf1f949ce7ebc2187d316d73407baa991f1c7cc7a3eea14d92b2d98e987e5'
sha256sums=('74985882e39467b34722e584ab836ed2abd47061888f318125fd4b167002afd5'
'197e33a56fc3d655e058d6936e92698c8aa65b7297cb218345b8ad51350c4ecf'
'01070781c13c7c5732d5d6779443381079be22d7d5612d0be1936e9cb9c95b7e')
'2288c0ad1c0f98f2b43a8e4bdd09a6cf91710c7c8b1e7bf7a2b516ed21e81705')
noextract=(${_realname}-${pkgver//_/-}.tar.gz)
prepare() {

View File

@@ -25,6 +25,7 @@ optdepends=("${MINGW_PACKAGE_PREFIX}-breeze-icons-qt5${_namesuff}: application i
source=(https://download.kde.org/stable/release-service/${pkgver}/src/${_realname}-${pkgver}.tar.xz{,.sig})
sha256sums=('f60b52e5a6a78920ac703a458f1eaf0ced02ffcd8b5f2d49de9a48674eeb007c'
'SKIP')
validpgpkeys=('F23275E4BF10AFC1DF6914A6DBD2CE893E2D1C87')
prepare() {
mkdir -p build-${CARCH}${_variant}

View File

@@ -16,6 +16,7 @@ makedepends=("${MINGW_PACKAGE_PREFIX}-gcc")
source=(https://ftp.gnu.org/gnu/libcdio/${_realname}-${pkgver}.tar.bz2{,.sig})
sha256sums=('4565c18caf401083c53733e6d2847b6671ba824cff1c7792b9039693d34713c1'
'SKIP')
validpgpkeys=('DAA63BC2582034A02B923D521A8DE5008275EC21')
build() {
[[ -d "${srcdir}"/build-${CARCH} ]] && rm -rf "${srcdir}"/build-${CARCH}

View File

@@ -1,44 +0,0 @@
diff --git a/src/hdy-swipe-group.c b/src/hdy-swipe-group.c
index 18b167ab5a260093bc0e6cd8fc4deef86211cb0f..2779a312e066f698635f151a8df6c57b6ac8b125 100644
--- a/src/hdy-swipe-group.c
+++ b/src/hdy-swipe-group.c
@@ -104,7 +104,7 @@ hdy_swipe_group_new (void)
static void
child_switched_cb (HdySwipeGroup *self,
- uint index,
+ guint index,
gint64 duration,
HdySwipeable *swipeable)
{
diff --git a/tests/test-carousel.c b/tests/test-carousel.c
index 538ca6e1a8f9589ebf10d0099bfdb56349f0a357..25ccb3e68700612dc8ed5f0c3e4debb6e8cbdc8e 100644
--- a/tests/test-carousel.c
+++ b/tests/test-carousel.c
@@ -158,7 +158,7 @@ static void
test_hdy_carousel_indicator_spacing (void)
{
HdyCarousel *carousel = HDY_CAROUSEL (hdy_carousel_new ());
- uint spacing;
+ guint spacing;
notified = 0;
g_signal_connect (carousel, "notify::indicator-spacing", G_CALLBACK (notify_cb), NULL);
@@ -210,7 +210,7 @@ static void
test_hdy_carousel_spacing (void)
{
HdyCarousel *carousel = HDY_CAROUSEL (hdy_carousel_new ());
- uint spacing;
+ guint spacing;
notified = 0;
g_signal_connect (carousel, "notify::spacing", G_CALLBACK (notify_cb), NULL);
@@ -236,7 +236,7 @@ static void
test_hdy_carousel_animation_duration (void)
{
HdyCarousel *carousel = HDY_CAROUSEL (hdy_carousel_new ());
- uint duration;
+ guint duration;
notified = 0;
g_signal_connect (carousel, "notify::animation-duration", G_CALLBACK (notify_cb), NULL);

View File

@@ -3,7 +3,7 @@
_realname=libhandy
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=0.84.0
pkgver=0.90.0
pkgrel=1
pkgdesc="A library full of GTK+ widgets for mobile phones (mingw-w64)"
url="https://gitlab.gnome.org/GNOME/libhandy"
@@ -15,14 +15,11 @@ makedepends=("${MINGW_PACKAGE_PREFIX}-meson"
"${MINGW_PACKAGE_PREFIX}-vala"
"${MINGW_PACKAGE_PREFIX}-gobject-introspection")
options=('strip' 'staticlibs' '!debug')
source=("http://ftp.gnome.org/pub/GNOME/sources/libhandy/${pkgver:0:4}/libhandy-${pkgver}.tar.xz"
001-fix-types.patch)
sha256sums=('c05c539f96f91cdf29a07320576c74909fcf77d216d7328e602fe16599f561aa'
'0d7833c87deaf5b25f6e1205fe54c1814a1cf91ab19f89b3cef1b96bac401d27')
source=("https://download.gnome.org/sources/libhandy/${pkgver:0:4}/libhandy-${pkgver}.tar.xz")
sha256sums=('6ab0869a3aa483298ea20ec89d4c14c38ba4de416b33181d21e15a6039df5985')
prepare() {
cd libhandy-${pkgver}
patch -p1 -i ${srcdir}/001-fix-types.patch
}
build() {

View File

@@ -3,7 +3,7 @@
_realname=librsvg
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=2.48.7
pkgver=2.48.8
pkgrel=1
pkgdesc="SVG rendering library (mingw-w64)"
arch=('any')
@@ -23,7 +23,7 @@ optdepends=("${MINGW_PACKAGE_PREFIX}-gtk3: for rsvg-view-3")
options=('staticlibs' 'strip')
source=("https://download.gnome.org/sources/librsvg/${pkgver%.*}/${_realname}-${pkgver}.tar.xz"
"0005-hack-unixy-paths.patch")
sha256sums=('35de5d93e262fcd85fa4529cee147687d21c6e092f223c293921eaaf57e2fec0'
sha256sums=('f480a325bbdf26d1874eb6fb330ebc5920ba64e3e08de61931bb4506dfef2692'
'b23b094c0cb65fcbbbb952350448de6f3430b30f273e05acdbf7a56d634212dc')
prepare() {

View File

@@ -1,160 +0,0 @@
--- libsndfile-1.0.26/configure.ac.orig 2013-04-08 00:08:06 +0400
+++ libsndfile-1.0.6/configure.ac 2013-04-08 00:08:00 +0400
@@ -651,6 +651,7 @@
M4/Makefile doc/Makefile Win32/Makefile Octave/Makefile programs/Makefile \
Makefile \
src/version-metadata.rc tests/test_wrapper.sh tests/pedantic-header-test.sh \
+ tests/win32_ordinal_test.c \
doc/libsndfile.css Scripts/build-test-tarball.mk libsndfile.spec sndfile.pc \
src/sndfile.h \
echo-install-dirs
--- /dev/null 2013-04-08 00:11:18 +0400
+++ libsndfile-1.0.25/tests/win32_ordinal_test.c.in 2013-04-08 00:06:17 +0400
@@ -0,0 +1,147 @@
+/*
+** Copyright (C) 2006-2011 Erik de Castro Lopo <erikd@mega-nerd.com>
+**
+** This program is free software; you can redistribute it and/or modify
+** it under the terms of the GNU General Public License as published by
+** the Free Software Foundation; either version 2 of the License, or
+** (at your option) any later version.
+**
+** This program is distributed in the hope that it will be useful,
+** but WITHOUT ANY WARRANTY; without even the implied warranty of
+** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+** GNU General Public License for more details.
+**
+** You should have received a copy of the GNU General Public License
+** along with this program; if not, write to the Free Software
+** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+*/
+
+#include "sfconfig.h"
+#include "sndfile.h"
+
+#include <stdio.h>
+#include <stdlib.h>
+
+#if HAVE_UNISTD_H
+#include <unistd.h>
+#endif
+
+#if (HAVE_DECL_S_IRGRP == 0)
+#include <sf_unistd.h>
+#endif
+
+#include <string.h>
+#include <fcntl.h>
+#include <sys/types.h>
+
+#include "utils.h"
+
+#if (defined (WIN32) || defined (_WIN32) || defined (__CYGWIN__))
+#define TEST_WIN32 1
+#else
+#define TEST_WIN32 0
+#endif
+
+#if TEST_WIN32
+#include <windows.h>
+
+
+static const char * locations [] =
+{ ".", "../src/", "src/", "../src/.libs/", "src/.libs/",
+ "@top_srcdir@/src",
+ NULL
+} ; /* locations. */
+
+static int
+test_ordinal (HMODULE hmod, const char * func_name, int ordinal)
+{ char *lpmsg ;
+ void *name, *ord ;
+
+ print_test_name ("win32_ordinal_test", func_name) ;
+
+#if SIZEOF_VOIDP == 8
+#define LPCSTR_OF_ORDINAL(x) ((LPCSTR) ((int64_t) (x)))
+#else
+#define LPCSTR_OF_ORDINAL(x) ((LPCSTR) (x))
+#endif
+
+ ord = GetProcAddress (hmod, LPCSTR_OF_ORDINAL (ordinal)) ;
+ if ((name = GetProcAddress (hmod, func_name)) == NULL)
+ { FormatMessage (FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM, NULL, GetLastError (),
+ MAKELANGID (LANG_NEUTRAL, SUBLANG_DEFAULT), (LPTSTR) &lpmsg, 0, NULL) ;
+ /*-puts (lpmsg) ;-*/
+ } ;
+
+ if (name != NULL && ord != NULL && name == ord)
+ { puts ("ok") ;
+ return 0 ;
+ } ;
+
+ puts ("fail") ;
+ return 1 ;
+} /* test_ordinal */
+
+static void
+win32_ordinal_test (void)
+{ static char buffer [1024] ;
+ static char func_name [1024] ;
+ HMODULE hmod = NULL ;
+ FILE * file = NULL ;
+ int k, ordinal, errors = 0 ;
+
+ for (k = 0 ; locations [k] != NULL ; k++)
+ { snprintf (buffer, sizeof (buffer), "%s/libsndfile-1.def", locations [k]) ;
+ if ((file = fopen (buffer, "r")) != NULL)
+ break ;
+ } ;
+
+ if (file == NULL)
+ { puts ("\n\nError : cannot open DEF file.\n") ;
+ exit (1) ;
+ } ;
+
+ for (k = 0 ; locations [k] != NULL ; k++)
+ { snprintf (buffer, sizeof (buffer), "%s/libsndfile-1.dll", locations [k]) ;
+ if ((hmod = (HMODULE) LoadLibrary (buffer)) != NULL)
+ break ;
+ } ;
+
+ if (hmod == NULL)
+ { puts ("\n\nError : cannot load DLL.\n") ;
+ exit (1) ;
+ } ;
+
+ while (fgets (buffer, sizeof (buffer), file) != NULL)
+ { func_name [0] = 0 ;
+ ordinal = 0 ;
+
+ if (sscanf (buffer, "%s @%d", func_name, &ordinal) != 2)
+ continue ;
+
+ errors += test_ordinal (hmod, func_name, ordinal) ;
+ } ;
+
+ FreeLibrary (hmod) ;
+
+ fclose (file) ;
+
+ if (errors > 0)
+ { printf ("\n\nErrors : %d\n\n", errors) ;
+ exit (1) ;
+ } ;
+
+ return ;
+} /* win32_ordinal_test */
+
+#endif
+
+int
+main (void)
+{
+#if (TEST_WIN32 && WIN32_TARGET_DLL)
+ win32_ordinal_test () ;
+#endif
+
+ return 0 ;
+} /* main */
+

View File

@@ -3,27 +3,23 @@
_realname=libsndfile
pkgbase=mingw-w64-${_realname}
pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}")
pkgver=1.0.28
pkgver=1.0.29pre2
pkgrel=1
pkgdesc="A C library for reading and writing files containing sampled sound (mingw-w64)"
arch=('any')
url="http://www.mega-nerd.com/libsndfile"
license=('LGPL')
makedepends=("${MINGW_PACKAGE_PREFIX}-gcc")
depends=("${MINGW_PACKAGE_PREFIX}-flac" "${MINGW_PACKAGE_PREFIX}-libvorbis" "${MINGW_PACKAGE_PREFIX}-speex")
depends=("${MINGW_PACKAGE_PREFIX}-flac" "${MINGW_PACKAGE_PREFIX}-libogg" "${MINGW_PACKAGE_PREFIX}-libvorbis" "${MINGW_PACKAGE_PREFIX}-opus")
options=('staticlibs' 'strip')
source=(http://www.mega-nerd.com/libsndfile/files/${_realname}-${pkgver}.tar.gz
0003-fix-source-searches.mingw.patch)
sha256sums=('1ff33929f042fa333aed1e8923aa628c3ee9e1eb85512686c55092d1e5a9dfa9'
'35633bbc54583d3f0a5dff3c3adfe95107a444ce85fc2cfc907b4bc947268c89')
source=("http://www.mega-nerd.com/libsndfile/files/${pkgver}/${_realname}-${pkgver}.tar.bz2")
sha256sums=('ffe2d6bff622bc66e6f96059ada79cfcdc43b3e8bc9cc4f45dbc567dccbfae75')
validpgpkeys=('6A91A5CF22C24C99A35E013FCFDCF91FB242ACED') # Erik de Castro Lopo <erikd@mega-nerd.com>
prepare() {
cd ${srcdir}/${_realname}-${pkgver}
patch -p1 -i ${srcdir}/0003-fix-source-searches.mingw.patch
#sed -i 's|#!/usr/bin/python|#!/usr/bin/python2|' src/binheader_writef_check.py \
# src/create_symbols_file.py programs/test-sndfile-metadata-set.py
autoreconf -fi -I M4
autoreconf -vfi
}
build() {
@@ -37,7 +33,7 @@ build() {
--disable-sqlite \
--disable-test-coverage \
--enable-external-libs \
--enable-experimental \
--enable-stack-smash-protection \
--enable-shared \
--enable-static

View File

@@ -0,0 +1,22 @@
--- a/src/install.c
+++ b/src/install.c
@@ -35,7 +35,7 @@
#if defined(_WIN64)
#include <cfgmgr32.h>
#else
-#include <ddk/cfgmgr32.h>
+#include <cfgmgr32.h>
#endif
#else
#include <cfgmgr32.h>
--- a/src/registry.c
+++ b/src/registry.c
@@ -28,7 +28,7 @@
#if defined(_WIN64)
#include <cfgmgr32.h>
#else
-#include <ddk/cfgmgr32.h>
+#include <cfgmgr32.h>
#endif
#else
#include <cfgmgr32.h>

View File

@@ -0,0 +1,39 @@
# Maintainer: fauxpark <fauxpark@gmail.com>
_realname=libusb-win32
pkgbase=mingw-w64-${_realname}
pkgname=${MINGW_PACKAGE_PREFIX}-${_realname}
pkgver=1.2.6.0
pkgrel=1
pkgdesc='Port of libusb-0.1 under Windows (mingw-w64)'
arch=('any')
license=('GPL3')
url='https://sourceforge.net/projects/libusb-win32/'
source=(
"https://downloads.sourceforge.net/project/libusb-win32/libusb-win32-releases/${pkgver}/libusb-win32-src-${pkgver}.zip"
01-mingw32-ddk-headers.patch
)
sha256sums=(
'f3faf094c9b3415ede42eeb5032feda2e71945f13f0ca3da58ca10dcb439bfee'
'71c3f422719cf229e7aaf9e06369ef5a0065b799f2184a4bbd8826bc5fad1687'
)
prepare() {
cd ${srcdir}/${_realname}-src-${pkgver}
patch -p1 -i ../01-mingw32-ddk-headers.patch
}
build() {
cd ${srcdir}/${_realname}-src-${pkgver}
make dll
}
package() {
cd ${srcdir}/${_realname}-src-${pkgver}
install -Dm755 libusb0.dll "${pkgdir}${MINGW_PREFIX}/bin/libusb0.dll"
install -Dm644 libusb.a "${pkgdir}${MINGW_PREFIX}/lib/libusb0.dll.a"
install -Dm644 src/lusb0_usb.h "${pkgdir}${MINGW_PREFIX}/include/lusb0_usb.h"
}

View File

@@ -3,7 +3,7 @@
_realname=mesa
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=20.1.4
pkgver=20.1.5
pkgrel=1
pkgdesc="Open-source implementation of the OpenGL specification (mingw-w64)"
arch=('any')
@@ -19,7 +19,7 @@ license=('MIT')
options=('staticlibs' 'strip')
source=(https://mesa.freedesktop.org/archive/${_realname}-${pkgver}.tar.xz{,.sig}
llvmwrapgen.sh)
sha256sums=('6800271c2be2a0447510eb4e9b67edd9521859a4d565310617c4b359eb6799fe'
sha256sums=('fac1861e6e0bf1aec893f8d86dbfb9d8a0f426ff06b05256df10e3ad7e02c69b'
'SKIP'
'3ad048a4c395adf6d24f2e9325d6a125822b323d494149e00d5cc435d16075e4')
validpgpkeys=('8703B6700E7EE06D7A39B8D6EDAE37B02CEB490D') # Emil Velikov <emil.l.velikov@gmail.com>

View File

@@ -3,7 +3,7 @@
_realname=meson
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=0.54.3
pkgver=0.55.1
pkgrel=1
pkgdesc="High-productivity build system (mingw-w64)"
arch=('any')
@@ -18,7 +18,7 @@ source=("https://github.com/mesonbuild/${_realname}/releases/download/${pkgver}/
'0002-Default-to-sys.prefix-as-the-default-prefix.patch'
'0003-Strip-the-prefix-from-all-paths-when-installing-with.patch'
'install-man.patch')
sha256sums=('f2bdf4cf0694e696b48261cdd14380fb1d0fe33d24744d8b2df0c12f33ebb662'
sha256sums=('3b5741f884e04928bdfa1947467ff06afa6c98e623c25cef75adf71ca39ce080'
'5805aed0a117536eb16dd8eef978c6be57c2471b655ede63e25517c28b4f4cf0'
'363182db7e7059526353278966aa4704e8a26cbaf7c3b7dc5d6e4f01692a40e6'
'2093c617cf3146a4cea601e7c73400d8ec5fd52ac5cf642c4f5af2d6493b1cb1'

View File

@@ -0,0 +1,24 @@
--- ./configure 2020-02-16 14:31:58.000000000 -0800
+++ ./configure.fix 2020-06-19 03:07:16.152206200 -0700
@@ -182,8 +182,8 @@
echo datadir=$datadir
echo mandir=$mandir
echo version=$version
- echo cflags=`grep ^framework packages.dat | cut -f 2`
- echo libs=`grep ^framework packages.dat | cut -f 3`
+ echo cflags=`grep ^framework packages.dat | cut -f 2 | sed "s#${prefix}/include#\\${includedir}#g"`
+ echo libs=`grep ^framework packages.dat | cut -f 3 | sed "s#${libdir}#\\${libdir}#g"`
echo moduledir=${moduledir}
echo mltdatadir=${mltdatadir}
echo meltbin=${prefix}/bin/${meltname}
@@ -198,8 +198,8 @@
echo datadir=$datadir
echo mandir=$mandir
echo version=$version
- echo cflags=`grep ^mlt++ packages.dat | cut -f 2`
- echo libs=`grep ^mlt++ packages.dat | cut -f 3`
+ echo cflags=`grep ^mlt++ packages.dat | cut -f 2 | sed "s#${prefix}/include#\\${includedir}#g"`
+ echo libs=`grep ^mlt++ packages.dat | cut -f 3 | sed "s#${libdir}#\\${libdir}#g"`
) >> mlt++.pc
cat mlt++.pc.in >>mlt++.pc
}

44
mingw-w64-mlt/PKGBUILD Normal file
View File

@@ -0,0 +1,44 @@
# Maintainer: Artem Konoplin <konoplin@gmail.com>
_realname=mlt
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=6.20.0
pkgrel=1
pkgdesc="An open source multimedia framework (mingw-w64)"
arch=('any')
url="https://www.mltframework.org"
license=('GPL')
makedepends=("${MINGW_PACKAGE_PREFIX}-dlfcn"
"${MINGW_PACKAGE_PREFIX}-SDL2"
"${MINGW_PACKAGE_PREFIX}-fftw"
"${MINGW_PACKAGE_PREFIX}-ffmpeg")
#options=('strip' 'staticlibs')
source=("https://github.com/mltframework/mlt/archive/v$pkgver.tar.gz"
"010-mlt-6.20.0-fix-configure-paths.patch")
sha256sums=('ab211e27c06c0688f9cbe2d74dc0623624ef75ea4f94eea915cdc313196be2dd'
'a039599ffbf976e9bb60da2be33876f7cac19a9540e7a0576aec75bc9831773e')
prepare() {
cd "${srcdir}/${_realname}-${pkgver}"
patch -p1 -i "${srcdir}/010-mlt-6.20.0-fix-configure-paths.patch"
}
build() {
cd mlt-$pkgver
./configure \
--avformat-swscale \
--enable-gpl \
--enable-gpl3 \
--enable-opencv \
--disable-gtk2 \
--prefix=${MINGW_PREFIX} \
--target-arch=${MSYSTEM_CARCH}
make -j$(nproc)
}
package() {
cd mlt-$pkgver
make DESTDIR="$pkgdir" install
}

View File

@@ -16,6 +16,7 @@ source=(#"http://www.multiprecision.org/mpc/download/${_realname}-${pkgver}.tar.
https://ftp.gnu.org/gnu/mpc/${_realname}-${pkgver}.tar.gz{,.sig})
sha256sums=('6985c538143c1208dcb1ac42cedad6ff52e267b47e5f970183a3e75125b43c2e'
'SKIP')
validpgpkeys=('AD17A21EF8AED8F1CC02DBD9F7D5C9BF765C61E3')
build() {
[[ -d ${srcdir}/build-${MINGW_CHOST} ]] && rm -rf ${srcdir}/build-${MINGW_CHOST}

View File

@@ -4,7 +4,7 @@
_realname=mpfr
pkgbase=mingw-w64-${_realname}
pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}")
_pkgver=4.0.2
_pkgver=4.1.0
_patchlevel=
pkgver=${_pkgver}
if [ -n "${_patchlevel}" ]; then
@@ -21,7 +21,7 @@ source=(https://ftp.gnu.org/gnu/mpfr/${_realname}-${_pkgver}.tar.xz{,.sig}
#https://www.mpfr.org/mpfr-current/${_realname}-${_pkgver}.tar.xz{,.asc}
#mpfr-${_pkgver}-${_patchlevel}.patch
)
sha256sums=('1d3be708604eae0e42d578ba93b390c2a145f17743a744d8f3f8c2ad5855a38a'
sha256sums=('0c98a3f1732ff6ca4ea690552079da9c597872d30e96ec28414ee23c95558a7f'
'SKIP')
validpgpkeys=('07F3DBBECC1A39605078094D980C197698C3739D')

View File

@@ -3,7 +3,7 @@
_realname=mpg123
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=1.26.1
pkgver=1.26.3
pkgrel=1
pkgdesc="A console based real time MPEG Audio Player for Layer 1, 2 and 3 (mingw-w64)"
arch=('any')
@@ -20,7 +20,7 @@ optdepends=("${MINGW_PACKAGE_PREFIX}-openal"
"${MINGW_PACKAGE_PREFIX}-SDL")
options=('strip' 'staticlibs' 'libtool')
source=("https://www.mpg123.com/download/mpg123-${pkgver}.tar.bz2"{,.sig})
sha256sums=('74d6629ab7f3dd9a588b0931528ba7ecfa989a2cad6bf53ffeef9de31b0fe032'
sha256sums=('30c998785a898f2846deefc4d17d6e4683a5a550b7eacf6ea506e30a7a736c6e'
'SKIP')
validpgpkeys=('D021FF8ECF4BE09719D61A27231C4CBC60D5CAFE')

View File

@@ -23,6 +23,7 @@ source=(https://marlam.de/msmtp/releases/${_realname}-${pkgver}.tar.xz{,.sig}
sha256sums=('f25f0fa177ce9e0ad65c127e790a37f35fb64fee9e33d90345844c5c86780e60'
'SKIP'
'3729fc8d9a11370324561a76cafe09035391e48c9a55876d1aaa5077944ebf8d')
validpgpkeys=('2F61B4828BBA779AECB3F32703A2A4AB1E32FD34')
prepare () {
cd ${srcdir}/${_realname}-${pkgver}

View File

@@ -3,7 +3,7 @@
_realname=nasm
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=2.14.02
pkgver=2.15.03
pkgrel=1
pkgdesc="An 80x86 assembler designed for portability and modularity (mingw-w64)"
arch=('any')
@@ -12,7 +12,7 @@ url="https://www.nasm.us"
options=('strip' '!libtool' 'staticlibs' '!makeflags')
makedepends=("${MINGW_PACKAGE_PREFIX}-gcc" "${MINGW_PACKAGE_PREFIX}-pkg-config")
source=(https://www.nasm.us/pub/nasm/releasebuilds/${pkgver}/${_realname}-${pkgver}.tar.xz)
sha256sums=('e24ade3e928f7253aa8c14aa44726d1edf3f98643f87c9d72ec1df44b26be8f5')
sha256sums=('c0c39a305f08ccf0c5c6edba4294dd2851b3925b6d9642dd1efd62f72829822f')
build() {
[[ -d ${srcdir}/build-${MINGW_CHOST} ]] && rm -rf ${srcdir}/build-${MINGW_CHOST}

View File

@@ -21,6 +21,7 @@ source=(#"${_realname}-${pkgver}.tar.gz"::"https://invisible-mirror.net/archives
sha256sums=('30306e0c76e0f9f1f0de987cf1c82a5c21e1ce6568b9227f7da5b71cbea86c9d'
'SKIP'
'd8fb37262372f3e5c9a553bdeff07c8b874bac6f3c416e2a372877cef0af1925')
validpgpkeys=('C52048C0C0748FEE227D47A2702353E0F7E48EDB')
prepare() {
cd ${_realname}-${pkgver}

View File

@@ -3,7 +3,7 @@
_realname=ngraph-gtk
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=6.08.05
pkgver=6.08.06
pkgrel=1
arch=('any')
pkgdesc="create scientific 2-dimensional graphs (mingw-w64)"
@@ -22,7 +22,7 @@ options=('strip' 'staticlibs')
license=("GPL")
url="https://htrb.github.io/ngraph-gtk/"
source=("https://github.com/htrb/ngraph-gtk/releases/download/v${pkgver}/ngraph-gtk-${pkgver}.tar.gz")
sha256sums=("f151f816b2d3382054408bac1bc378be9f5c7f60a6fdfe9b3f4fe840745c3f27")
sha256sums=("fa7d68774fc6d01421344211d456d75541f0a82e82768bfe073160cbcba44fbf")
prepare() {
cd "${srcdir}"/${_realname}-${pkgver}

View File

@@ -3,7 +3,7 @@
_realname=ninja
pkgbase=mingw-w64-${_realname}
pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}")
pkgver=1.10.0
pkgver=1.10.1
pkgrel=1
pkgdesc="Ninja is a small build system with a focus on speed (mingw-w64)"
arch=('any')
@@ -11,15 +11,9 @@ url="https://ninja-build.org"
license=('Apache')
depends=()
options=('strip' 'staticlibs')
makedepends=("re2c" "${MINGW_PACKAGE_PREFIX}-python3")
makedepends=("re2c" "${MINGW_PACKAGE_PREFIX}-python")
source=("${_realname}-${pkgver}.tar.gz"::"https://github.com/ninja-build/ninja/archive/v${pkgver}.tar.gz")
sha256sums=('3810318b08489435f8efc19c05525e80a993af5a55baa0dfeae0465a9d45f99f')
prepare () {
cd ${srcdir}/ninja-${pkgver}
#linking assumes windows cmd line but we are bash :)
sed -i 's|cmd /c $ar cqs $out.tmp $in && move /Y $out.tmp $out|$ar crs $out $in|g' ${srcdir}/ninja-${pkgver}/configure.py
}
sha256sums=('a6b6f7ac360d4aabd54e299cc1d8fa7b234cd81b9401693da21221c62569a23e')
build() {
mkdir -p "${pkgdir}${MINGW_PREFIX}"/bin

View File

@@ -4,7 +4,7 @@ _realname=json
_pkgname=nlohmann-json
pkgbase=mingw-w64-${_pkgname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_pkgname}"
pkgver=3.8.0
pkgver=3.9.1
pkgrel=1
pkgdesc="JSON for Modern C++ (mingw-w64)"
arch=('any')
@@ -17,7 +17,7 @@ provides=("${MINGW_PACKAGE_PREFIX}-nlohmann_json")
replaces=("${MINGW_PACKAGE_PREFIX}-nlohmann_json")
options=('staticlibs' '!strip' '!buildflags')
source=("${_realname}-${pkgver}.tar.gz"::"https://github.com/nlohmann/json/archive/v${pkgver}.tar.gz")
sha256sums=('7d0edf65f2ac7390af5e5a0b323b31202a6c11d744a74b588dc30f5a8c9865ba')
sha256sums=('4cf0df69731494668bdd6460ed8cb269b68de9c19ad8c27abc24cd72605b2d5b')
build() {
[[ -d "${srcdir}/build-${MINGW_CHOST}" ]] && rm -rf "${srcdir}/build-${MINGW_CHOST}"

View File

@@ -10,7 +10,7 @@ pkgdesc="NVIDIA Cg libraries (mingw-w64)"
arch=('any')
url="https://developer.nvidia.com/cg-toolkit"
license=("custom")
makedepends=("dos2unix" "${MINGW_PACKAGE_PREFIX}-tools" "${MINGW_PACKAGE_PREFIX}-binutils") #"${MINGW_PACKAGE_PREFIX}-innoextract"
makedepends=("dos2unix" "${MINGW_PACKAGE_PREFIX}-innoextract" "${MINGW_PACKAGE_PREFIX}-tools" "${MINGW_PACKAGE_PREFIX}-binutils")
depends=("${MINGW_PACKAGE_PREFIX}-crt")
options=('!strip' 'staticlibs')
source=("https://developer.download.nvidia.com/cg/Cg_3.1/Cg-3.1_April2012_Setup.exe")

View File

@@ -1,11 +0,0 @@
diff -Naur a/cmake/OpenCVFindOpenBLAS.cmake b/cmake/OpenCVFindOpenBLAS.cmake
--- a/cmake/OpenCVFindOpenBLAS.cmake 2017-03-08 20:21:41.669934400 -0500
+++ b/cmake/OpenCVFindOpenBLAS.cmake 2017-03-08 20:23:59.354590300 -0500
@@ -46,6 +46,7 @@
SET(Open_BLAS_INCLUDE_SEARCH_PATHS
$ENV{OpenBLAS_HOME}
$ENV{OpenBLAS_HOME}/include
+ $ENV{OpenBLAS_HOME}/include/OpenBLAS
/opt/OpenBLAS/include
/usr/local/include/openblas
/usr/include/openblas

View File

@@ -3,8 +3,8 @@
_realname=opencv
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=4.3.0
pkgrel=2
pkgver=4.4.0
pkgrel=1
pkgdesc="Open Source Computer Vision Library (mingw-w64)"
arch=('any')
url="https://opencv.org/"
@@ -59,7 +59,6 @@ source=("${_realname}-${pkgver}.tar.gz"::https://github.com/opencv/opencv/archiv
'0003-issue-4107.patch'
'0004-generate-proper-pkg-config-file.patch'
'0008-mingw-w64-cmake-lib-path.patch'
'0009-openblas-find.patch'
'0010-find-libpng-header.patch'
'0012-make-header-usable-with-C-compiler.patch'
'0014-python-install-path.patch'
@@ -68,14 +67,13 @@ source=("${_realname}-${pkgver}.tar.gz"::https://github.com/opencv/opencv/archiv
'0102-mingw-w64-have-sincos.patch'
'0103-sfm-module-linking.patch'
'0104-rgbd-module-missing-include.patch')
sha256sums=('68bc40cbf47fdb8ee73dfaf0d9c6494cd095cf6294d99de445ab64cf853d278a'
'acb8e89c9e7d1174e63e40532125b60d248b00e517255a98a419d415228c6a55'
sha256sums=('bb95acd849e458be7f7024d17968568d1ccd2f0681d47fd60d34ffb4b8c52563'
'a69772f553b32427e09ffbfd0c8d5e5e47f7dab8b3ffc02851ffd7f912b76840'
'496165d79ffdaee4626697c7f1c90891c1108854da2a266138c94dcb28e7a90f'
'fd4e095c3c879413184fc6b91a7b0a77dbb128612341a8be2c99d804a203e362'
'52ebc8875b9ef3ea70897f34509228daeff73d0cab0aa9eb8b931be6a7d32d7f'
'aaf2a1952b04c9be3a133b08b0a06f536b4e9ba5f312a03f41301dba61a3fc94'
'7398e66f80be37382bd427b5eb3a1201a23113c14e71435a44df8779ea1b8a34'
'e3e2cfc85a9588c545c08f12dcdf933b8b32df9b887944b84c01d520f563ac21'
'f4d9c95251d74165de89f9c4f17a9a265302aca10ac8723a866f413a2181a361'
'7350e41ac9dfd95213b880ff017edda155ad704e35e024cfd9f42d286178b1fb'
'e7ca030c5fc9d1292ff464afe5fd83ebe7d58df98321ed83dc55afba8a60ea3d'
@@ -112,7 +110,6 @@ prepare() {
0003-issue-4107.patch \
0004-generate-proper-pkg-config-file.patch \
0008-mingw-w64-cmake-lib-path.patch \
0009-openblas-find.patch \
0010-find-libpng-header.patch \
0012-make-header-usable-with-C-compiler.patch \
0014-python-install-path.patch \

View File

@@ -0,0 +1,19 @@
--- oiio-Release-2.1.18.1.orig/src/include/OpenImageIO/strutil.h
+++ oiio-Release-2.1.18.1/src/include/OpenImageIO/strutil.h
@@ -362,14 +362,14 @@
void OIIO_API to_upper (std::string &a);
/// Return an all-upper case version of `a` (locale-independent).
-inline std::string OIIO_API lower (string_view a) {
+inline std::string lower (string_view a) {
std::string result(a);
to_lower(result);
return result;
}
/// Return an all-upper case version of `a` (locale-independent).
-inline std::string OIIO_API upper (string_view a) {
+inline std::string upper (string_view a) {
std::string result(a);
to_upper(result);
return result;

View File

@@ -0,0 +1,15 @@
--- oiio-Release-2.1.18.1.orig/src/cmake/compiler.cmake
+++ oiio-Release-2.1.18.1/src/cmake/compiler.cmake
@@ -83,12 +83,6 @@
option (STOP_ON_WARNING "Stop building if there are any compiler warnings" OFF)
if (NOT MSVC)
add_compile_options ("-Wall")
- if (STOP_ON_WARNING OR DEFINED ENV{CI})
- add_compile_options ("-Werror")
- # N.B. Force CI builds (Travis defines $CI) to use -Werror, even if
- # STOP_ON_WARNING has been switched off by default, which we may do
- # in release branches.
- endif ()
endif ()

View File

@@ -3,8 +3,8 @@
_realname=openimageio
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=2.1.16.0
pkgrel=1
pkgver=2.1.18.1
pkgrel=2
pkgdesc="A library for reading and writing images, including classes, utilities, and applications (mingw-w64)"
arch=('any')
url="https://www.openimageio.org/"
@@ -12,6 +12,7 @@ license=("custom")
depends=("${MINGW_PACKAGE_PREFIX}-boost"
"${MINGW_PACKAGE_PREFIX}-field3d"
"${MINGW_PACKAGE_PREFIX}-freetype"
"${MINGW_PACKAGE_PREFIX}-fmt"
"${MINGW_PACKAGE_PREFIX}-jasper"
"${MINGW_PACKAGE_PREFIX}-giflib"
"${MINGW_PACKAGE_PREFIX}-glew"
@@ -52,8 +53,10 @@ source=(${_realname}-${pkgver}.tar.gz::https://github.com/OpenImageIO/oiio/archi
0012-maybe-uninitialized-errors.patch
0013-dont-export-enums.patch
0014-fix-ptex-string-format.patch
0015-python-module-ext.patch)
sha256sums=('f44e3b3cffe9a8f47395da1ae59e972ecb26adf65f17581e6a489fdcce0cb116'
0015-python-module-ext.patch
0016-strutil-dont-export-inline-functions.patch
0017-cmake-compiler-remove-Werror.patch)
sha256sums=('e2cf54f5b28e18fc88e76e1703f2e39bf144c88378334527e4a1246974659a85'
'SKIP'
'73c46166c1d19922b6b54f4e1e18128c33dadbc72a36b683049ec297ce1056b3'
'9e4e21333676268a91c0f4e7676aeab7658e5f748e7e5cfe43a92f0fd7931229'
@@ -64,7 +67,9 @@ sha256sums=('f44e3b3cffe9a8f47395da1ae59e972ecb26adf65f17581e6a489fdcce0cb116'
'bc37ea8326f7f5f26068051b537f2491e9554a380e6584bf55aaad111d33eb81'
'b3d1ce84de09b2de5047c79c7a9fbaff59d7cd45d0ce92ddd11fe40082a781b4'
'6845acb6229a40512407a983aa07470e9ff1832db7a1e01c408ee74898ddc504'
'7e9ab73459f1d4fe859d51682da75c2e0eaa42e3a14deb1b012db31867a45fa7')
'7e9ab73459f1d4fe859d51682da75c2e0eaa42e3a14deb1b012db31867a45fa7'
'8fc1c63974ca1a1aff3fadbdbb855f7e977680e510624815dabc35ec413e2a86'
'887dbdea1f74a5745ce0a1f3782174b4b5ce676d0c35124ec19e2dde6f841ff9')
prepare() {
cd ${srcdir}/oiio-Release-${pkgver}
@@ -78,6 +83,8 @@ prepare() {
patch -p1 -i ${srcdir}/0013-dont-export-enums.patch
patch -p1 -i ${srcdir}/0014-fix-ptex-string-format.patch
patch -p1 -i ${srcdir}/0015-python-module-ext.patch
patch -p1 -i ${srcdir}/0016-strutil-dont-export-inline-functions.patch
patch -p1 -i ${srcdir}/0017-cmake-compiler-remove-Werror.patch
}
build() {
@@ -103,10 +110,9 @@ build() {
-DUSE_OPENGL=ON \
-DUSE_QT=OFF \
-DUSE_FFMPEG=ON \
-DHIDE_SYMBOLS=ON \
-DPYTHON_VERSION=${_pyver} \
-DUSE_EXTERNAL_PUGIXML=ON \
-DOIIO_BUILD_TESTS=ON \
-DOIIO_BUILD_TESTS=OFF \
-DSTOP_ON_WARNING=OFF \
${extra_config} \
../oiio-Release-${pkgver}

View File

@@ -12,7 +12,7 @@ pkgdesc="The Open Source toolkit for Secure Sockets Layer and Transport Layer Se
depends=("${MINGW_PACKAGE_PREFIX}-ca-certificates" "${MINGW_PACKAGE_PREFIX}-gcc-libs" "${MINGW_PACKAGE_PREFIX}-zlib")
makedepends=("${MINGW_PACKAGE_PREFIX}-gcc")
options=('strip' '!buildflags' 'staticlibs')
license=('BSD')
license=('custom:BSD')
url="https://www.openssl.org"
noextract=(${_realname}-${_ver}.tar.gz)
source=(https://www.openssl.org/source/${_realname}-${_ver}.tar.gz{,.asc}

View File

@@ -0,0 +1,89 @@
# Maintainer: Konstantin Podsvirov <konstantin@podsvirov.pro>
_realname=pelican
pkgbase=mingw-w64-${_realname}
pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}")
pkgver=4.2.0
pkgrel=1
pkgdesc='A tool to generate a static blog, with restructured text (or markdown) input files (mingw-w64)'
arch=('any')
url='https://getpelican.com/'
license=('AGPL3')
depends=("${MINGW_PACKAGE_PREFIX}-python"
"${MINGW_PACKAGE_PREFIX}-python-jinja"
"${MINGW_PACKAGE_PREFIX}-python-pygments"
"${MINGW_PACKAGE_PREFIX}-python-feedgenerator"
"${MINGW_PACKAGE_PREFIX}-python-pytz"
"${MINGW_PACKAGE_PREFIX}-python-docutils"
"${MINGW_PACKAGE_PREFIX}-python-blinker"
"${MINGW_PACKAGE_PREFIX}-python-unidecode"
"${MINGW_PACKAGE_PREFIX}-python-six"
"${MINGW_PACKAGE_PREFIX}-python-dateutil")
makedepends=("${MINGW_PACKAGE_PREFIX}-python-setuptools"
"${MINGW_PACKAGE_PREFIX}-python-sphinx"
"${MINGW_PACKAGE_PREFIX}-python-sphinx_rtd_theme")
checkdepends=("${MINGW_PACKAGE_PREFIX}-python-nose")
optdepends=("${MINGW_PACKAGE_PREFIX}-python-markdown: Markdown support"
"${MINGW_PACKAGE_PREFIX}-asciidoc: AsciiDoc support"
"${MINGW_PACKAGE_PREFIX}-python-beautifulsoup4: importing from wordpress/dotclear/posterous"
#"${MINGW_PACKAGE_PREFIX}-python-feedparser: importing from feeds"
"${MINGW_PACKAGE_PREFIX}-python-rst2pdf: PDF generation"
"openssh: uploading through SSH"
"rsync: uploading through rsync+SSH"
"lftp: uploading through FTP"
#"s3cmd: uploading through S3"
#"${MINGW_PACKAGE_PREFIX}-python-ghp-import: uploading through gh-pages"
#"${MINGW_PACKAGE_PREFIX}-python-typogrify: typographical enhancements"
#"${MINGW_PACKAGE_PREFIX}-pandoc: for pelican-import auto convert"
#"${MINGW_PACKAGE_PREFIX}-python-mdx-video: easier embedding of youtube videos in markdown"
)
source=("pelican-${pkgver}.tar.gz"::"https://github.com/getpelican/pelican/archive/${pkgver}.tar.gz")
install=${_realname}-${CARCH}.install
sha256sums=('4b0d4c9439217b49ace89f4f8b52c90e13fa283a786d7b12e2020a11f32f9a33')
prepare() {
cd "${srcdir}"
rm -rf "python-build-${CARCH}" | true
cp -r "pelican-${pkgver}" "python-build-${CARCH}"
}
build() {
msg "Python build for ${CARCH}"
cd "${srcdir}/python-build-${CARCH}"
${MINGW_PREFIX}/bin/python setup.py build
msg "Building documentation"
cd "${srcdir}/python-build-${CARCH}/docs"
PYTHONPATH="${srcdir}/python-build-${CARCH}/build/lib" \
make man html
}
check() {
cd "${srcdir}/python-build-${CARCH}"
PYTHONPATH="${srcdir}/python-build-${CARCH}/build/lib" \
${MINGW_PREFIX}/bin/nosetests
}
package() {
cd "${srcdir}/python-build-${CARCH}"
MSYS2_ARG_CONV_EXCL="--prefix=;--install-scripts=;--install-platlib=" \
${MINGW_PREFIX}/bin/python setup.py install --prefix=${MINGW_PREFIX} --root="${pkgdir}" -O1 --skip-build
# fix python command in files
local PREFIX_WIN=$(cygpath -wm ${MINGW_PREFIX})
for _ff in "${pkgdir}${MINGW_PREFIX}/bin/*.py"; do
sed -e "s|${PREFIX_WIN}|${MINGW_PREFIX}|g" -i ${_ff}
done
# documentation
local _docdir="${srcdir}/python-build-${CARCH}/docs/_build"
mkdir -p "${pkgdir}${MINGW_PREFIX}/share/man/man1"
for _ff in "${_docdir}/man/*.1"
do
cp ${_ff} "${pkgdir}${MINGW_PREFIX}/share/man/man1/"
done
mkdir -p "${pkgdir}${MINGW_PREFIX}/share/doc"
cp -r "${_docdir}/html/" "${pkgdir}${MINGW_PREFIX}/share/doc/${_realname}"
# license
install -Dm644 LICENSE "${pkgdir}${MINGW_PREFIX}/share/licenses/${_realname}/LICENSE"
}
# vim: ts=2 sw=2 et:

View File

@@ -0,0 +1,14 @@
post_install() {
cd mingw32
local _prefix=$(pwd -W)
cd -
local _it
for _it in pelican pelican-import pelican-quickstart pelican-themes; do
sed -e "s|/mingw32|${_prefix}|g" \
-i ${_prefix}/bin/${_it}-script.py
done
}
post_upgrade() {
post_install
}

View File

@@ -0,0 +1,14 @@
post_install() {
cd mingw64
local _prefix=$(pwd -W)
cd -
local _it
for _it in pelican pelican-import pelican-quickstart pelican-themes; do
sed -e "s|/mingw64|${_prefix}|g" \
-i ${_prefix}/bin/${_it}-script.py
done
}
post_upgrade() {
post_install
}

View File

@@ -0,0 +1,43 @@
# Maintainer: Konstantin Podsvirov <konstantin@podsvirov.pro>
_realname=blinker
pkgbase=mingw-w64-python-${_realname}
pkgname=("${MINGW_PACKAGE_PREFIX}-python-${_realname}")
pkgver=1.4
pkgrel=1
pkgdesc='Fast, simple object-to-object and broadcast signaling (mingw-w64)'
arch=('any')
url='https://pythonhosted.org/blinker/'
license=('MIT')
depends=("${MINGW_PACKAGE_PREFIX}-python")
makedepends=("${MINGW_PACKAGE_PREFIX}-python-setuptools")
checkdepends=("${MINGW_PACKAGE_PREFIX}-python-nose")
source=("blinker-rel-${pkgver}.tar.gz"::"https://github.com/jek/blinker/archive/rel-${pkgver}.tar.gz")
sha256sums=('ee9d6d52cbb93a8f9fe40205f7e0bd33af90458e27214ffcd35415d1a940c36b')
prepare() {
cd "${srcdir}"
rm -rf "python-build-${CARCH}" | true
cp -r "blinker-rel-${pkgver}" "python-build-${CARCH}"
}
build() {
msg "Python build for ${CARCH}"
cd "${srcdir}/python-build-${CARCH}"
${MINGW_PREFIX}/bin/python setup.py build
}
check() {
cd "${srcdir}/python-build-${CARCH}"
PYTHONPATH="${srcdir}/python-build-${CARCH}/build/lib:${PYTHONPATH}" \
${MINGW_PREFIX}/bin/nosetests
}
package() {
cd "${srcdir}/python-build-${CARCH}"
MSYS2_ARG_CONV_EXCL="--prefix=;--install-scripts=;--install-platlib=" \
${MINGW_PREFIX}/bin/python setup.py install --prefix=${MINGW_PREFIX} --root="${pkgdir}" -O1 --skip-build
install -Dm644 LICENSE "${pkgdir}${MINGW_PREFIX}/share/licenses/python-${_realname}/LICENSE"
}
# vim: ts=2 sw=2 et:

View File

@@ -6,7 +6,7 @@ pkgname=("${MINGW_PACKAGE_PREFIX}-python-${_realname}")
provides=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}")
conflicts=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}")
replaces=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}")
pkgver=5.0.1
pkgver=5.2.1
pkgrel=1
pkgdesc="Code coverage measurement for Python (mingw-w64)"
arch=('any')
@@ -16,16 +16,16 @@ depends=("${MINGW_PACKAGE_PREFIX}-python")
makedepends=("${MINGW_PACKAGE_PREFIX}-python-setuptools")
install=${_realname}3-${CARCH}.install
source=("${_realname}-${pkgver}.tar.gz::https://github.com/nedbat/coveragepy/archive/coverage-${pkgver}.tar.gz")
sha256sums=('ea6d1b82bc758ca33483685c821ea8a75a0da63060d3a11ad12755f1965cf2dd')
sha256sums=('d4b1405f26b70021b28c50823e9345f203280ab104e65c01b52fe57b2dd96455')
prepare() {
prepare() {
cd "${srcdir}"
rm -rf python-build-${CARCH} | true
cp -r "coveragepy-${_realname}-${pkgver}" "python-build-${CARCH}"
}
build() {
msg "Python build for ${CARCH}"
msg "Python build for ${CARCH}"
cd "${srcdir}/python-build-${CARCH}"
${MINGW_PREFIX}/bin/python setup.py build
}

View File

@@ -6,7 +6,7 @@ pkgname=("${MINGW_PACKAGE_PREFIX}-python-${_realname}")
provides=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}")
conflicts=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}")
replaces=("${MINGW_PACKAGE_PREFIX}-python3-${_realname}")
pkgver=1.14.0
pkgver=1.15.0
pkgrel=1
pkgdesc="Python 2 and 3 compatibility utilities (mingw-w64)"
arch=('any')
@@ -14,7 +14,7 @@ url="https://pypi.python.org/pypi/six/"
license=('MIT')
depends=("${MINGW_PACKAGE_PREFIX}-python")
source=(https://pypi.io/packages/source/${_realname:0:1}/${_realname}/${_realname}-${pkgver}.tar.gz)
sha256sums=('236bdbdce46e6e6a3d61a337c0f8b763ca1e8717c03b369e87a7ec7ce1319c0a')
sha256sums=('30639c035cdb23534cd4aa2dd52c3bf48f06e5f4a941509c8bafd8ce11080259')
prepare() {
cd "${srcdir}"
@@ -39,4 +39,4 @@ package() {
--root "${pkgdir}" --optimize=1 --skip-build
install -Dm644 "${srcdir}/six-${pkgver}/LICENSE" "${pkgdir}${MINGW_PREFIX}/share/licenses/python-${_realname}/LICENSE"
}
}

View File

@@ -38,6 +38,7 @@ sha256sums=('1d68ef41a1b61dc9786beb923a68902a6276a77cced5e5ea7ff985ef113932d7'
'57602e5272a079ca1e8f4b4452030094010c7a6b33ed4606e1497cd0b4126717'
'037b615f8b6f609112383b69e6050e7c939b12b0c7c0fa210a58e075c0d1c589'
'b031ceac3ed4e1228349545cf536f75fd6e21a3cfb6a0412e5eb87c1f45b1bbc')
validpgpkeys=('CB9387521E1EE0127DA804843FDBB55084CC5D84')
prepare() {
cd "${srcdir}/${_realname}-${pkgver}"

View File

@@ -3,10 +3,10 @@
_realname=qemu
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
_base_ver=5.0.0
_base_ver=5.1.0
_rc=
pkgver=${_base_ver}${_rc//-/.}
pkgrel=2
pkgrel=1
pkgdesc="A generic and open source processor emulator (mingw-w64)"
arch=('any')
license=('GPL2' 'LGPL2')
@@ -36,7 +36,7 @@ depends=("${MINGW_PACKAGE_PREFIX}-capstone"
"${MINGW_PACKAGE_PREFIX}-usbredir"
"${MINGW_PACKAGE_PREFIX}-zstd")
source=(https://download.qemu.org/${_realname}-${pkgver}.tar.xz{,.sig})
sha256sums=('2f13a92a0fa5c8b69ff0796b59b86b080bbb92ebad5d301a7724dd06b5e78cb6'
sha256sums=('c9174eb5933d9eb5e61f541cd6d1184cd3118dfe4c5c4955bc1bdc4d390fa4e5'
'SKIP')
validpgpkeys=('CEACC9E15534EBABB82D3FA03353C9CEF108B584') # Michael Roth <flukshun@gmail.com>
noextract=(${_realname}-${pkgver}.tar.xz)
@@ -51,8 +51,15 @@ prepare() {
build() {
LDFLAGS+=" -fstack-protector"
cd "${srcdir}/${_realname}-${pkgver}"
./configure \
local -a _extra_config
if [[ "$CARCH" = 'x86_64' ]]; then
_extra_config+=("--enable-whpx")
fi
[[ -d "${srcdir}"/build-${CARCH} ]] && rm -rf "${srcdir}"/build-${CARCH}
mkdir -p "${srcdir}"/build-${CARCH} && cd "${srcdir}"/build-${CARCH}
../${_realname}-${pkgver}/configure \
--disable-werror \
--disable-kvm \
--disable-spice \
@@ -68,6 +75,7 @@ build() {
--enable-gtk \
--enable-sdl \
--enable-zstd \
"${_extra_config[@]}" \
--prefix=${MINGW_PREFIX} \
--bindir=${MINGW_PREFIX}/bin \
--datadir=${MINGW_PREFIX}/bin \
@@ -75,10 +83,11 @@ build() {
--python=${MINGW_PREFIX}/bin/python \
--mandir=${MINGW_PREFIX}/share/qemu \
--docdir=${MINGW_PREFIX}/share/qemu
make
}
package() {
cd "${srcdir}/${_realname}-${pkgver}"
cd "${srcdir}"/build-${CARCH}
make DESTDIR="${pkgdir}/" install
}

47
mingw-w64-scour/PKGBUILD Normal file
View File

@@ -0,0 +1,47 @@
# Maintainer: Biswapriyo Nath <nathbappai@gmail.com>
_realname=scour
pkgbase=mingw-w64-${_realname}
pkgname="${MINGW_PACKAGE_PREFIX}-${_realname}"
pkgver=0.38
pkgrel=1
pkgdesc="An SVG scrubber (mingw-w64)"
arch=('any')
url="https://github.com/scour-project/scour"
license=('Apache')
depends=("${MINGW_PACKAGE_PREFIX}-python"
"${MINGW_PACKAGE_PREFIX}-python-setuptools"
"${MINGW_PACKAGE_PREFIX}-python-six")
source=("${_realname}-${pkgver}.tar.gz"::"https://github.com/scour-project/scour/archive/v${pkgver}.tar.gz")
sha256sums=('565d52331b40793f038a2725fcc3ee53539d9ef287d582b7c305789cb1d503eb')
prepare() {
cd "${srcdir}"
cp -r ${_realname}-${pkgver} python-build-${CARCH}
}
build() {
cd "${srcdir}/python-build-${CARCH}"
${MINGW_PREFIX}/bin/python setup.py build
}
check() {
cd "${srcdir}/python-build-${CARCH}"
${MINGW_PREFIX}/bin/python setup.py check
}
package() {
cd "${srcdir}/python-build-${CARCH}"
MSYS2_ARG_CONV_EXCL="--prefix=;--install-scripts=;--install-platlib=" \
${MINGW_PREFIX}/bin/python setup.py install --prefix=${MINGW_PREFIX} \
--root "${pkgdir}" --optimize=1 --skip-build
install -Dm644 "${srcdir}/${_realname}-${pkgver}/LICENSE" "${pkgdir}${MINGW_PREFIX}/share/licenses/python-${_realname}/LICENSE"
local PREFIX_WIN=$(cygpath -wm ${MINGW_PREFIX})
# fix python command in files
for _f in "${pkgdir}${MINGW_PREFIX}"/bin/*.py; do
sed -e "s|/usr/bin/env |${MINGW_PREFIX}|g" \
-e "s|${PREFIX_WIN}|${MINGW_PREFIX}|g" -i ${_f}
done
}

Some files were not shown because too many files have changed in this diff Show More