uboot: (firmwareOdroidC2/C4) don't invoke patch tool, use patches = [] instead

https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/setup.sh#L948
this can do it nicely.

Signed-off-by: Anton Arapov <anton@deadbeef.mx>
This commit is contained in:
Anton Arapov 2021-04-03 12:58:10 +02:00 committed by Alan Daniels
commit 56de2bcd43
30691 changed files with 3076956 additions and 0 deletions

View file

@ -0,0 +1,122 @@
{ lib
, stdenv
, fetchFromGitHub
, fetchpatch
, makeWrapper
, which
, nodejs
, mkYarnPackage
, fetchYarnDeps
, python3
, nixosTests
, buildGoModule
}:
let
pinData = lib.importJSON ./pin.json;
# we need a different version than the one already available in nixpkgs
esbuild-hedgedoc = buildGoModule rec {
pname = "esbuild";
version = "0.12.27";
src = fetchFromGitHub {
owner = "evanw";
repo = "esbuild";
rev = "v${version}";
sha256 = "sha256-UclUTfm6fxoYEEdEEmO/j+WLZLe8SFzt7+Tej4bR0RU=";
};
vendorSha256 = "sha256-QPkBR+FscUc3jOvH7olcGUhM6OW4vxawmNJuRQxPuGs=";
};
in
mkYarnPackage rec {
pname = "hedgedoc";
inherit (pinData) version;
src = fetchFromGitHub {
owner = "hedgedoc";
repo = "hedgedoc";
rev = version;
sha256 = pinData.srcHash;
};
nativeBuildInputs = [ which makeWrapper ];
extraBuildInputs = [ python3 esbuild-hedgedoc ];
offlineCache = fetchYarnDeps {
inherit yarnLock;
sha256 = pinData.yarnHash;
};
# FIXME(@Ma27) on the bump to 1.9.0 I had to patch this file manually:
# I replaced `midi "https://github.com/paulrosen/MIDI.js.git#abcjs"` with
# `midi "git+https://github.com/paulrosen/MIDI.js.git#abcjs"` on all occurrences.
#
# Without this change `yarn` attempted to download the code directly from GitHub, with
# the `git+`-prefix it actually uses the `midi.js` version from the offline cache
# created by `yarn2nix`. On future bumps this may be necessary as well!
yarnLock = ./yarn.lock;
packageJSON = ./package.json;
postConfigure = ''
rm deps/HedgeDoc/node_modules
cp -R "$node_modules" deps/HedgeDoc
chmod -R u+w deps/HedgeDoc
'';
buildPhase = ''
runHook preBuild
cd deps/HedgeDoc
pushd node_modules/sqlite3
export CPPFLAGS="-I${nodejs}/include/node"
npm run install --build-from-source --nodedir=${nodejs}/include/node
popd
pushd node_modules/esbuild
rm bin/esbuild
ln -s ${lib.getBin esbuild-hedgedoc}/bin/esbuild bin/
popd
npm run build
patchShebangs bin/*
runHook postBuild
'';
dontInstall = true;
distPhase = ''
runHook preDist
mkdir -p $out
cp -R {app.js,bin,lib,locales,node_modules,package.json,public} $out
cat > $out/bin/hedgedoc <<EOF
#!${stdenv.shell}/bin/sh
${nodejs}/bin/node $out/app.js
EOF
chmod +x $out/bin/hedgedoc
wrapProgram $out/bin/hedgedoc \
--set NODE_PATH "$out/lib/node_modules"
runHook postDist
'';
passthru = {
updateScript = ./update.sh;
tests = { inherit (nixosTests) hedgedoc; };
};
meta = with lib; {
description = "Realtime collaborative markdown notes on all platforms";
license = licenses.agpl3;
homepage = "https://hedgedoc.org";
maintainers = with maintainers; [ willibutz ma27 globin ];
platforms = platforms.linux;
};
}

View file

@ -0,0 +1,215 @@
{
"name": "HedgeDoc",
"version": "1.9.0",
"description": "The best platform to write and share markdown.",
"main": "app.js",
"license": "AGPL-3.0",
"scripts": {
"test": "npm run-script eslint && npm run-script jsonlint && npm run-script mocha-suite",
"eslint": "node_modules/.bin/eslint --max-warnings 0 lib public test app.js",
"jsonlint": "find . -not -path './node_modules/*' -type f -name '*.json' -o -type f -name '*.json.example' | while read json; do echo $json ; jq . $json; done",
"markdownlint": "remark .",
"mocha-suite": "NODE_ENV=test CMD_DB_URL=\"sqlite::memory:\" mocha --exit",
"standard": "echo 'standard is no longer being used, use `npm run eslint` instead!' && exit 1",
"dev": "webpack --config webpack.dev.js --progress --watch",
"heroku-prebuild": "bin/heroku",
"build": "webpack --config webpack.prod.js --progress",
"start": "node app.js"
},
"dependencies": {
"@passport-next/passport-openid": "^1.0.0",
"Idle.Js": "git+https://github.com/shawnmclean/Idle.js",
"archiver": "^5.0.2",
"async": "^3.0.0",
"aws-sdk": "^2.987.0",
"azure-storage": "^2.7.0",
"base64url": "^3.0.0",
"body-parser": "^1.15.2",
"chance": "^1.0.4",
"cheerio": "^0.22.0",
"compression": "^1.6.2",
"connect-flash": "^0.1.1",
"connect-session-sequelize": "^7.1.2",
"cookie": "^0.4.0",
"cookie-parser": "^1.4.3",
"deep-freeze": "^0.0.1",
"diff-match-patch": "git+https://github.com/hackmdio/diff-match-patch.git",
"ejs": "^3.0.0",
"express": ">=4.14",
"express-session": "^1.14.2",
"file-type": "^16.1.0",
"formidable": "^1.0.17",
"graceful-fs": "^4.1.11",
"helmet": "^4.5.0",
"i18n": "^0.13.0",
"is-svg": "^4.3.1",
"jsdom-nogyp": "^0.8.3",
"lodash": "^4.17.20",
"lutim": "^1.0.2",
"lz-string": "git+https://github.com/hackmdio/lz-string.git",
"mariadb": "^2.1.2",
"markdown-it": "^12.0.0",
"markdown-it-abbr": "^1.0.4",
"markdown-it-container": "^3.0.0",
"markdown-it-deflist": "^2.0.1",
"markdown-it-emoji": "^2.0.0",
"markdown-it-footnote": "^3.0.1",
"markdown-it-imsize": "^2.0.1",
"markdown-it-ins": "^3.0.0",
"markdown-it-mark": "^3.0.0",
"markdown-it-mathjax": "^2.0.0",
"markdown-it-regexp": "^0.4.0",
"markdown-it-sub": "^1.0.0",
"markdown-it-sup": "^1.0.0",
"mattermost": "^3.4.0",
"meta-marked": "git+https://github.com/hedgedoc/meta-marked",
"method-override": "^3.0.0",
"minimist": "^1.2.0",
"minio": "^7.0.19",
"moment": "^2.17.1",
"morgan": "^1.7.0",
"mysql2": "^2.0.0",
"node-fetch": "^2.6.1",
"passport": "^0.4.0",
"passport-dropbox-oauth2": "^1.1.0",
"passport-facebook": "^3.0.0",
"passport-github": "^1.1.0",
"passport-gitlab2": "^5.0.0",
"passport-google-oauth20": "^2.0.0",
"passport-ldapauth": "^3.0.0",
"passport-local": "^1.0.0",
"passport-oauth2": "^1.4.0",
"passport-saml": "^3.1.2",
"passport-twitter": "^1.0.4",
"passport.socketio": "^3.7.0",
"pdfobject": "^2.0.201604172",
"pg": "^8.2.1",
"pg-hstore": "^2.3.3",
"prom-client": "^13.1.0",
"prometheus-api-metrics": "^3.2.0",
"randomcolor": "^0.6.0",
"readline-sync": "^1.4.7",
"rimraf": "^3.0.2",
"scrypt-kdf": "^2.0.1",
"sequelize": "^5.21.1",
"shortid": "2.2.16",
"socket.io": "^2.1.1",
"sqlite3": "^5.0.0",
"store": "^2.0.12",
"string": "^3.3.3",
"toobusy-js": "^0.5.1",
"umzug": "^2.3.0",
"uuid": "^8.0.0",
"validator": "^13.0.0",
"winston": "^3.1.0",
"xss": "^1.0.3"
},
"resolutions": {
"**/tough-cookie": "~2.5.0",
"**/minimatch": "^3.0.2",
"**/request": "^2.88.0"
},
"engines": {
"node": ">=12"
},
"bugs": "https://github.com/hedgedoc/hedgedoc/issues",
"keywords": [
"Collaborative",
"Markdown",
"Notes"
],
"homepage": "https://hedgedoc.org",
"maintainers": [
{
"name": "Claudius Coenen",
"url": "https://www.claudiuscoenen.de/"
},
{
"name": "Christoph (Sheogorath) Kern",
"email": "codimd@sheogorath.shivering-isles.com",
"url": "https://shivering-isles.com"
},
{
"name": "David Mehren",
"email": "hedgedoc@herrmehren.de"
}
],
"repository": {
"type": "git",
"url": "https://github.com/hedgedoc/hedgedoc.git"
},
"devDependencies": {
"abcjs": "5.12.0",
"babel-cli": "6.26.0",
"babel-core": "6.26.3",
"babel-loader": "7.1.5",
"babel-plugin-transform-runtime": "6.23.0",
"babel-polyfill": "6.26.0",
"babel-preset-env": "1.7.0",
"babel-runtime": "6.26.0",
"bootstrap": "3.4.1",
"bootstrap-validator": "0.11.9",
"codemirror": "git+https://github.com/hedgedoc/CodeMirror.git",
"copy-webpack-plugin": "6.4.1",
"css-loader": "5.2.7",
"emojify.js": "1.1.0",
"esbuild-loader": "2.15.1",
"escape-html": "1.0.3",
"eslint": "7.32.0",
"eslint-config-standard": "16.0.3",
"eslint-plugin-import": "2.24.2",
"eslint-plugin-node": "11.1.0",
"eslint-plugin-promise": "5.1.0",
"eslint-plugin-standard": "4.1.0",
"exports-loader": "1.1.1",
"expose-loader": "1.0.3",
"file-loader": "6.2.0",
"file-saver": "2.0.5",
"flowchart.js": "1.15.0",
"fork-awesome": "1.2.0",
"gist-embed": "2.6.0",
"highlight.js": "10.7.3",
"html-webpack-plugin": "4.5.2",
"imports-loader": "1.2.0",
"ionicons": "2.0.1",
"jquery": "3.6.0",
"jquery-mousewheel": "3.1.13",
"jquery-ui": "1.12.1",
"js-cookie": "3.0.1",
"js-sequence-diagrams": "git+https://github.com/hedgedoc/js-sequence-diagrams.git",
"js-yaml": "3.14.1",
"jsonlint": "1.6.3",
"keymaster": "1.6.2",
"less": "4.1.1",
"less-loader": "7.3.0",
"list.js": "2.3.1",
"mathjax": "2.7.9",
"mermaid": "8.12.1",
"mini-css-extract-plugin": "1.6.2",
"mocha": "9.1.1",
"mock-require": "3.0.3",
"optimize-css-assets-webpack-plugin": "6.0.1",
"prismjs": "1.24.1",
"raphael": "2.3.0",
"remark-cli": "10.0.0",
"remark-preset-lint-markdown-style-guide": "5.0.1",
"reveal.js": "3.9.2",
"select2": "3.5.2-browserify",
"socket.io-client": "2.4.0",
"spin.js": "4.1.1",
"string-loader": "0.0.1",
"turndown": "7.1.1",
"url-loader": "4.1.1",
"velocity-animate": "1.5.2",
"visibilityjs": "2.0.2",
"viz.js": "1.8.2",
"webpack": "4.46.0",
"webpack-cli": "4.8.0",
"webpack-merge": "5.8.0",
"wurl": "2.5.4"
},
"optionalDependencies": {
"bufferutil": "^4.0.0",
"utf-8-validate": "^5.0.1"
}
}

View file

@ -0,0 +1,5 @@
{
"version": "1.9.0",
"srcHash": "hSKQGkI1+68Zf05RhgRKZo47buyobzjhURSZ30/h0PA=",
"yarnHash": "0v51jmmbg8fx66ay2glby0gxw07in95igz325p42g5hjd5kankf6"
}

View file

@ -0,0 +1,32 @@
#!/usr/bin/env nix-shell
#!nix-shell -I nixpkgs=../../../../ -i bash -p nix wget prefetch-yarn-deps nix-prefetch-github
if [ "$#" -gt 1 ] || [[ "$1" == -* ]]; then
echo "Regenerates packaging data for the element packages."
echo "Usage: $0 [git release tag]"
exit 1
fi
version="$1"
set -euo pipefail
if [ -z "$version" ]; then
version="$(wget -O- "https://api.github.com/repos/hedgedoc/hedgedoc/releases?per_page=1" | jq -r '.[0].tag_name')"
fi
src="https://raw.githubusercontent.com/hedgedoc/hedgedoc/$version"
wget "$src/package.json" -O package.json
wget "$src/yarn.lock" -O yarn.lock
sed 's;midi "https://github\.com/paulrosen/MIDI\.js\.git;midi "git+https://github.com/paulrosen/MIDI.js.git;g' -i yarn.lock
src_hash=$(nix-prefetch-github hedgedoc hedgedoc --rev ${version} | jq -r .sha256)
yarn_hash=$(prefetch-yarn-deps yarn.lock)
cat > pin.json << EOF
{
"version": "$version",
"srcHash": "$src_hash",
"yarnHash": "$yarn_hash"
}
EOF

File diff suppressed because it is too large Load diff