Skip to content

Commit

Permalink
Merge pull request #585 from mariux64/convert-python3-to-package
Browse files Browse the repository at this point in the history
Convert python3 to package
  • Loading branch information
donald authored Jan 27, 2018
2 parents 4341665 + fd6245b commit 5a39507
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 161 deletions.
74 changes: 0 additions & 74 deletions Python3-3.3.0-0.bee

This file was deleted.

76 changes: 0 additions & 76 deletions matplotlib_python3.3-1.2.0-0.bee

This file was deleted.

51 changes: 40 additions & 11 deletions numpy_python3.3-1.7.0b2-0.bee → python3-wrapper.be0
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
#!/usr/bin/env beesh

# BEE_VERSION python3-wrapper-1.0-0

## this file was created by bee init and should be executed to build a
## bee-package. (Additional hints are located at the end of this file.)

###############################################################################
## The source URL(s) define the location of the sources that will be
## downloaded. Version variables may be used to simplify reuse of this bee-file.

SRCURL[0]="http://downloads.sourceforge.net/project/numpy/NumPy/${PKGVERSION}/numpy-${PKGVERSION}.tar.gz"
SRCURL[0]=""

###############################################################################
## Add URLs/pathes to patch files to the PATCHURL array.
Expand All @@ -22,14 +24,20 @@ SRCURL[0]="http://downloads.sourceforge.net/project/numpy/NumPy/${PKGVERSION}/nu
# EXCLUDE+=()

###############################################################################
## Uncomment the next statement, if the software may not be able to be build
## outside the source directory and need to be build inside the source
## Uncomment the next statement, if the software may not be able to be built
## outside the source directory and needs to be built inside the source
## directory.

# build_in_sourcedir

# which python to use to build this module is encoded in PKGEXTRANAME
export PYTHON=${PKGEXTRANAME}
###############################################################################
## bee cannot detect buildtypes specified in subdirectories.
## Sometimes packages "hide" the real sources in a subdirectory named
## 'src' or 'cmake' or ..
## use 'sourcesubdir_append' to specify this directory if known.

# sourcesubdir_append src


###############################################################################
## Change the default (auto-detected) steps to
Expand All @@ -46,16 +54,37 @@ export PYTHON=${PKGEXTRANAME}
#}

#mee_configure() {
# bee_configure
# bee_configure
#}

mee_build() {
bee_build --fcompiler=gnu95
echo -e '#! /bin/bash\nprun python3 "$(basename "$0")" "$@"' >wrapper
chmod +x wrapper
}

#mee_install() {
# bee_install
#}
create_bin_wrapper() {
cmd="$1"
target="$2"
if [ -z "$target" ]; then
ln "$B/wrapper" "$D$BINDIR/$cmd"
else
echo -e '#! /bin/bash\nprun python3 "$target" "$@"' > "$D$BINDIR/$cmd"
chmod +x "$D$BINDIR/$cmd"
fi
}

mee_install() {
mkdir -p "$D$BINDIR"
create_bin_wrapper 2to3
create_bin_wrapper idle3
create_bin_wrapper pydoc3
create_bin_wrapper python3-config
create_bin_wrapper python3
create_bin_wrapper pyenv3 pyenv-3.3

create_bin_wrapper ipython3
create_bin_wrapper meson
}
## by default this may be 'make install DESTDIR="${D}"'

###############################################################################
Expand All @@ -65,7 +94,7 @@ mee_build() {
## The name of this bee-file should follow the following naming convention:
## pkgname-pkgversion-pkgrevision.bee
##
## You may remove all comments as long as SRCURL[0]="" is set.
## You may remove all comments as long as SRCURL[0] is set.
##
## Everything in this file will be executed in a bash environment.
##
Expand Down

0 comments on commit 5a39507

Please sign in to comment.