Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Try to fix build with current build system #1

Merged
merged 17 commits into from
Jan 8, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
52 changes: 2 additions & 50 deletions HACKING
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ as well, so it's recommended you give it a read.

Building your plugin
--------------------
You should first read either `README` or `README.waf` depending on whether
you want to use Autotools or Waf to build the plugins.
You should first read `README` to understand how to build the plugins in
general.


Autotools Build System
Expand Down Expand Up @@ -284,54 +284,6 @@ Makefile.am to references them::
yourfancypluginname_la_LIBADD = $(COMMONLIBS) $(FOO_LIBS)


Adding a new plugin to Waf build system
---------------------------------------

Configuration checks
^^^^^^^^^^^^^^^^^^^^

Add a ``wscript_configure`` file in your plugin's root folder.
This file contains checks for dependencies, like libraries your plugin
requires. If your plugin does not have any additional dependencies
besides Geany, GLib and GTK, you can leave this file empty (but you need
to create it nonetheless).

Generally checks are performed with ``check_cfg_cached``. An example
to check for library ``foo`` at version 2.0 or newer might look like
this::

from build.wafutils import check_cfg_cached

check_cfg_cached(conf,
package='foo',
atleast_version='2.0',
uselib_store='FOO',
mandatory=True,
args='--cflags --libs')


Build rules
^^^^^^^^^^^

Add a ``wscript_build`` file inside your plugin's root folder.
This files defines how the plugin is built, and has to at least call
``build_plugin()``. An example could look like this::

from build.wafutils import build_plugin

name = 'YourFancyPluginName'
sources = ['src/yourfancypluginname.c']

build_plugin(bld, name, sources=sources)

If you checked for additional dependencies in ``wscript_configure``
in addition to the standard Geany, GLib or GTK, you might need to make
use of some results of these checks. Given the configuration example
above, you would need to add the ``libraries=['FOO']`` argument to
the ``build_plugin()`` call::

build_plugin(bld, name, sources=sources, libraries=['FOO'])


Additional things to do for a new plugin
----------------------------------------
Expand Down
7 changes: 6 additions & 1 deletion MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@ M: Colomban Wendling <ban@herbesfolles.org>
W:
S: Maintained


debugger
P: Alexander Petukhov <devel@apetukhov.ru>
M: Alexander Petukhov <devel@apetukhov.ru>
Expand Down Expand Up @@ -168,6 +167,12 @@ M: Colomban Wendling <ban@herbesfolles.org>
W: http://plugins.geany.org/git-changebar.html
S: Maintained

lineoperations
P: Sylvan Mostert <smostert.dev@gmail.com>
M: Sylvan Mostert <smostert.dev@gmail.com>
W:
S: Maintained

markdown
P: Matthew Brush <matt@geany.org>
M: Matthew Brush <matt@geany.org>
Expand Down
9 changes: 3 additions & 6 deletions Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,9 @@ if ENABLE_GITCHANGEBAR
SUBDIRS += git-changebar
endif

if ENABLE_LINEOPERATIONS
SUBDIRS += lineoperations
endif
if ENABLE_MARKDOWN
SUBDIRS += markdown
endif
Expand Down Expand Up @@ -169,10 +172,4 @@ endif


EXTRA_DIST = \
build/__init__.py \
build/wafcache.py \
build/wafutils.py \
waf \
wscript \
README.waf \
README.windows
11 changes: 1 addition & 10 deletions README
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Geany-Plugins
Installation
------------

You can build the plugins using either Autotools or Waf.
You can build the plugins using Autotools.

Building with Autotools
^^^^^^^^^^^^^^^^^^^^^^^
Expand Down Expand Up @@ -122,12 +122,3 @@ which means that after running ``./configure``, you may compile each
individual plugin by cd-ing into the respective plugin directory
and running make inside it.

Building with Waf
^^^^^^^^^^^^^^^^^

Geany-Plugins can also being build using Python based build system Waf.
For doing this you have similar to building with Autotools run three steps::

./waf configure [arguments]
./waf build
./waf install
36 changes: 0 additions & 36 deletions README.waf

This file was deleted.

29 changes: 0 additions & 29 deletions addons/wscript_build

This file was deleted.

28 changes: 0 additions & 28 deletions autoclose/wscript_build

This file was deleted.

22 changes: 0 additions & 22 deletions autoclose/wscript_configure

This file was deleted.

28 changes: 0 additions & 28 deletions automark/wscript_build

This file was deleted.

22 changes: 0 additions & 22 deletions automark/wscript_configure

This file was deleted.

5 changes: 0 additions & 5 deletions build/__init__.py

This file was deleted.

10 changes: 10 additions & 0 deletions build/lineoperations.m4
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
AC_DEFUN([GP_CHECK_LINEOPERATIONS],
[
GP_ARG_DISABLE([LineOperations], [auto])
GP_CHECK_PLUGIN_GTK2_ONLY([LineOperations])
GP_COMMIT_PLUGIN_STATUS([LineOperations])
AC_CONFIG_FILES([
lineoperations/Makefile
lineoperations/src/Makefile
])
])
4 changes: 1 addition & 3 deletions build/vars.auxfiles.mk
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,4 @@ dist_plugindoc_DATA = \
AUTHORS \
$(AUXFILES)

EXTRA_DIST = \
wscript_build \
wscript_configure
EXTRA_DIST =
41 changes: 0 additions & 41 deletions build/wafcache.py

This file was deleted.