summaryrefslogtreecommitdiffstats
path: root/debian/_buildscripts/local/hook_examples
diff options
context:
space:
mode:
authorMichele Calgaro <michele.calgaro@yahoo.it>2018-07-11 23:38:32 +0900
committerMichele Calgaro <michele.calgaro@yahoo.it>2018-07-11 23:38:32 +0900
commiteeaccbeddbaa2974406eb20cbb7beca3fb4a59f0 (patch)
tree510e0eea682ebf69263b187287873956394b5e7b /debian/_buildscripts/local/hook_examples
parent02dbbffa606c3c52833bbaf3dc5c5a050f295dbf (diff)
downloadtde-packaging-eeaccbeddbaa2974406eb20cbb7beca3fb4a59f0.tar.gz
tde-packaging-eeaccbeddbaa2974406eb20cbb7beca3fb4a59f0.zip
DEB build scripts: several enhancements as follow:
- major rework of update_repositories.sh script, which now supports multiple branches and provide better feedback to user. - added support for pre-built extra dependency packages. A user can now use Slavek Banko's binary packages instead of building the extra dependency locally. This removes a quite tedious process during the setup of the building environment. - bug fixes and more user friendly folder names. - improved README to cover the complete process until TDE installation. Special thanks to Gregory Guy <zadig83@laposte.net> for testing and feedback done so far. Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
Diffstat (limited to 'debian/_buildscripts/local/hook_examples')
-rw-r--r--debian/_buildscripts/local/hook_examples/applications/kaffeine/kaffeine-wizard.diff65
-rwxr-xr-xdebian/_buildscripts/local/hook_examples/applications/kaffeine/pre_build.sh13
-rw-r--r--debian/_buildscripts/local/hook_examples/tdebase/018_kate_save_all.diff37
-rwxr-xr-xdebian/_buildscripts/local/hook_examples/tdebase/pre_build.sh16
-rw-r--r--debian/_buildscripts/local/hook_examples/tdebase/tdebase-usesak.diff15
-rw-r--r--debian/_buildscripts/local/hook_examples/tdelibs/038_placeholder.diff64
-rwxr-xr-xdebian/_buildscripts/local/hook_examples/tdelibs/pre_build.sh13
7 files changed, 223 insertions, 0 deletions
diff --git a/debian/_buildscripts/local/hook_examples/applications/kaffeine/kaffeine-wizard.diff b/debian/_buildscripts/local/hook_examples/applications/kaffeine/kaffeine-wizard.diff
new file mode 100644
index 000000000..c35ba6516
--- /dev/null
+++ b/debian/_buildscripts/local/hook_examples/applications/kaffeine/kaffeine-wizard.diff
@@ -0,0 +1,65 @@
+diff -urN kaffeine/kaffeine/src/kaffeine.cpp kaffeine.new/kaffeine/src/kaffeine.cpp
+--- kaffeine/kaffeine/src/kaffeine.cpp 2013-03-02 15:47:14.000000000 -0600
++++ kaffeine.new/kaffeine/src/kaffeine.cpp 2013-11-24 11:39:09.809430631 -0600
+@@ -683,7 +683,9 @@
+ m_autoResizeTriple = new TDEToggleAction(i18n("Triple Size"), 0, ALT|Key_3, TQT_TQOBJECT(this), TQT_SLOT(slotAutoresizeTriple()), actionCollection(), "view_auto_resize_triple");
+
+ m_playersMenu = new TDEActionMenu(i18n("&Player Engine"), actionCollection(), "options_player");
+- KStdAction::keyBindings(TQT_TQOBJECT(this), TQT_SLOT(optionsConfigureKeys()), actionCollection());
++ m_instWizard = new TDEAction(i18n("Installation &Wizard"), 0, 0, TQT_TQOBJECT(this), TQT_SLOT(slotInstWizard()), actionCollection(), "inst_wizard");
++
++ KStdAction::keyBindings(TQT_TQOBJECT(this), TQT_SLOT(optionsConfigureKeys()), actionCollection());
+ KStdAction::configureToolbars(TQT_TQOBJECT(this), TQT_SLOT(optionsConfigureToolbars()), actionCollection());
+ KStdAction::preferences(TQT_TQOBJECT(this), TQT_SLOT(slotPreferences()), actionCollection(), "options_preferences");
+
+@@ -1619,6 +1621,18 @@
+ mute();
+ }
+
++void Kaffeine::slotInstWizard()
++{
++ TQString stamp = locateLocal("appdata", "wizard_stamp_v0.7.1");
++ InstWizard::showWizard();
++
++ TDEProcess process;
++ process << "touch" << stamp;
++ process.start(TDEProcess::Block, TDEProcess::Stderr);
++ process.clearArguments();
++}
++
++
+ /********* DCOP INTERFACE *********/
+
+ void Kaffeine::openURL(TQString url)
+diff -urN kaffeine/kaffeine/src/kaffeine.h kaffeine.new/kaffeine/src/kaffeine.h
+--- kaffeine/kaffeine/src/kaffeine.h 2013-03-02 15:47:14.000000000 -0600
++++ kaffeine.new/kaffeine/src/kaffeine.h 2013-11-24 11:09:17.455756279 -0600
+@@ -193,6 +193,7 @@
+ void slotDvbClient(bool,const TQString&,int,int,const TQString&);
+ void slotNumKeyInput( int );
+ void slotDVBNextBack( int );
++ void slotInstWizard();
+
+ private:
+ void autoresize();
+@@ -258,7 +259,8 @@
+ TDEToggleAction* m_autoResizeTriple;
+ TDEToggleAction* m_originalAspect;
+ TDEToggleAction* m_toggleLayout;
+- TDEActionMenu* m_playersMenu;
++ TDEActionMenu* m_playersMenu;
++ TDEAction* m_instWizard;
+ TDEToggleAction* m_sleepAfterPlay;
+ TDEToggleAction* m_quitAfterPlay;
+ TDEToggleAction* m_quitAfterPlaylist;
+diff -urN kaffeine/kaffeine/src/kaffeineui.rc kaffeine.new/kaffeine/src/kaffeineui.rc
+--- kaffeine/kaffeine/src/kaffeineui.rc 2012-09-14 17:39:52.000000000 -0500
++++ kaffeine.new/kaffeine/src/kaffeineui.rc 2013-11-24 11:10:15.335565312 -0600
+@@ -34,6 +34,7 @@
+ <Merge/>
+ <Menu noMerge="1" name="settings"><text>&amp;Settings</text>
+ <Action name="options_player"/>
++ <Action name="inst_wizard"/>
+ <Separator/>
+ <Merge name="StandardToolBarMenuHandler"/>
+ <Action name="options_show_statusbar"/>
diff --git a/debian/_buildscripts/local/hook_examples/applications/kaffeine/pre_build.sh b/debian/_buildscripts/local/hook_examples/applications/kaffeine/pre_build.sh
new file mode 100755
index 000000000..96400d6e9
--- /dev/null
+++ b/debian/_buildscripts/local/hook_examples/applications/kaffeine/pre_build.sh
@@ -0,0 +1,13 @@
+#!/bin/bash
+
+CURR_DIR=$PWD
+cd "$PKG_BUILD_PATH"
+
+# Apply patches
+if [ "$bool_COPY_PKG_SRC" = "y" ]; then
+ echo -e "${CLightPurple}Applying Kaffeine wizard patch${CNone}"
+ patch -p2 < "$HOOK_DIR/$PKG_NAME/kaffeine-wizard.diff"
+fi
+
+cd "$CURR_DIR"
+return 0
diff --git a/debian/_buildscripts/local/hook_examples/tdebase/018_kate_save_all.diff b/debian/_buildscripts/local/hook_examples/tdebase/018_kate_save_all.diff
new file mode 100644
index 000000000..16ac7c7dc
--- /dev/null
+++ b/debian/_buildscripts/local/hook_examples/tdebase/018_kate_save_all.diff
@@ -0,0 +1,37 @@
+diff -Nur ori/tdebase/kate/app/katedocmanager.cpp new/tdebase/kate/app/katedocmanager.cpp
+--- ori/tdebase/kate/app/katedocmanager.cpp 2013-07-27 02:36:57.000000000 +0900
++++ new/tdebase/kate/app/katedocmanager.cpp 2013-12-05 15:56:20.311928016 +0900
+@@ -381,7 +381,6 @@
+ return modified;
+ }
+
+-
+ bool KateDocManager::queryCloseDocuments(KateMainWindow *w)
+ {
+ uint docCount = m_docList.count();
+@@ -436,12 +435,22 @@
+ return true;
+ }
+
+-
+ void KateDocManager::saveAll()
+ {
+ for (TQPtrListIterator<Kate::Document> it(m_docList); it.current(); ++it)
+- if ( it.current()->isModified() && it.current()->views().count() )
+- ((Kate::View*)it.current()->views().first())->save();
++ {
++ if (it.current()->views().count())
++ {
++ if (it.current()->url().isEmpty())
++ {
++ ((Kate::View*)it.current()->views().first())->saveAs();
++ }
++ else if (it.current()->isModified())
++ {
++ ((Kate::View*)it.current()->views().first())->save();
++ }
++ }
++ }
+ }
+
+ void KateDocManager::saveDocumentList (TDEConfig* config)
diff --git a/debian/_buildscripts/local/hook_examples/tdebase/pre_build.sh b/debian/_buildscripts/local/hook_examples/tdebase/pre_build.sh
new file mode 100755
index 000000000..e764c29ad
--- /dev/null
+++ b/debian/_buildscripts/local/hook_examples/tdebase/pre_build.sh
@@ -0,0 +1,16 @@
+#!/bin/bash
+
+CURR_DIR=$PWD
+cd "$PKG_BUILD_PATH"
+
+# Apply patches
+if [ "$bool_COPY_PKG_SRC" = "y" ]; then
+ echo -e "${CLightPurple}Applying Kate save all patch${CNone}"
+ patch -p2 < "$HOOK_DIR/$PKG_NAME/018_kate_save_all.diff"
+
+ echo -e "${CLightPurple}Applying SAK patch${CNone}"
+ patch -p1 < "$HOOK_DIR/$PKG_NAME/tdebase-usesak.diff"
+fi
+
+cd "$CURR_DIR"
+return 0
diff --git a/debian/_buildscripts/local/hook_examples/tdebase/tdebase-usesak.diff b/debian/_buildscripts/local/hook_examples/tdebase/tdebase-usesak.diff
new file mode 100644
index 000000000..e85ca1047
--- /dev/null
+++ b/debian/_buildscripts/local/hook_examples/tdebase/tdebase-usesak.diff
@@ -0,0 +1,15 @@
+diff -urNa tdebase/tdm/config.def tdebase.new/tdm/config.def
+--- tdebase/tdm/config.def 2013-09-12 11:51:29.000000000 -0500
++++ tdebase.new/tdm/config.def 2014-02-10 06:29:38.537806886 -0600
+@@ -2010,9 +2010,9 @@
+
+ Key: UseSAK
+ Type: bool
+-Default: true
++Default: false
+ User: greeter
+-Instance: #*/!
++Instance: #:*/false
+ Comment:
+ SAK
+ Description:
diff --git a/debian/_buildscripts/local/hook_examples/tdelibs/038_placeholder.diff b/debian/_buildscripts/local/hook_examples/tdelibs/038_placeholder.diff
new file mode 100644
index 000000000..65d64cc72
--- /dev/null
+++ b/debian/_buildscripts/local/hook_examples/tdelibs/038_placeholder.diff
@@ -0,0 +1,64 @@
+diff -Nur ori/tdelibs/tdeutils/kfinddialog.cpp new/tdelibs/tdeutils/kfinddialog.cpp
+--- ori/tdelibs/tdeutils/kfinddialog.cpp 2014-02-05 16:54:13.852605699 +0900
++++ new/tdelibs/tdeutils/kfinddialog.cpp 2014-02-11 18:16:55.292214876 +0900
+@@ -149,8 +149,9 @@
+ m_replace->setMaxCount(10);
+ m_replace->setDuplicatesEnabled(false);
+ m_backRef = new TQCheckBox(i18n("Use p&laceholders"), m_replaceGrp);
++ m_backRef->setEnabled(m_regExp->isChecked());
+ m_backRefItem = new TQPushButton(i18n("Insert Place&holder"), m_replaceGrp);
+- m_backRefItem->setEnabled(false);
++ m_backRefItem->setEnabled(m_regExp->isChecked() && m_backRef->isChecked());
+
+ m_replaceLayout->addWidget(m_replaceLabel, 0, 0);
+ m_replaceLayout->addMultiCellWidget(m_replace, 1, 1, 0, 1);
+@@ -193,8 +194,8 @@
+
+ // signals and slots connections
+ connect(m_selectedText, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(slotSelectedTextToggled(bool)));
+- connect(m_regExp, TQT_SIGNAL(toggled(bool)), m_regExpItem, TQT_SLOT(setEnabled(bool)));
+- connect(m_backRef, TQT_SIGNAL(toggled(bool)), m_backRefItem, TQT_SLOT(setEnabled(bool)));
++ connect(m_regExp, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(slotRegexCheckBoxToggled(bool)));
++ connect(m_backRef, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(slotPlaceholdersCheckBoxToggled(bool)));
+ connect(m_regExpItem, TQT_SIGNAL(clicked()), this, TQT_SLOT(showPatterns()));
+ connect(m_backRefItem, TQT_SIGNAL(clicked()), this, TQT_SLOT(showPlaceholders()));
+
+@@ -276,11 +277,23 @@
+ "Ask before replacing each match found.") );
+ }
+
+-void KFindDialog::textSearchChanged( const TQString & text)
++void KFindDialog::textSearchChanged(const TQString & text)
+ {
+ enableButtonOK( !text.isEmpty() );
+ }
+
++void KFindDialog::slotRegexCheckBoxToggled(bool checked)
++{
++ m_regExpItem->setEnabled(checked);
++ m_backRef->setEnabled(checked);
++ m_backRefItem->setEnabled(checked && m_backRef->isChecked());
++}
++
++void KFindDialog::slotPlaceholdersCheckBoxToggled(bool checked)
++{
++ m_backRefItem->setEnabled(checked && m_regExp->isChecked());
++}
++
+ void KFindDialog::showEvent( TQShowEvent *e )
+ {
+ if ( !d->m_initialShowDone )
+diff -Nur ori/tdelibs/tdeutils/kfinddialog.h new/tdelibs/tdeutils/kfinddialog.h
+--- ori/tdelibs/tdeutils/kfinddialog.h 2014-02-05 16:54:13.852605699 +0900
++++ new/tdelibs/tdeutils/kfinddialog.h 2014-02-11 18:16:57.876214916 +0900
+@@ -250,7 +250,9 @@
+ void slotSelectedTextToggled(bool);
+ void showPatterns();
+ void showPlaceholders();
+- void textSearchChanged( const TQString &);
++ void textSearchChanged(const TQString &);
++ void slotRegexCheckBoxToggled(bool checked);
++ void slotPlaceholdersCheckBoxToggled(bool checked);
+
+ protected:
+ virtual void showEvent ( TQShowEvent * );
diff --git a/debian/_buildscripts/local/hook_examples/tdelibs/pre_build.sh b/debian/_buildscripts/local/hook_examples/tdelibs/pre_build.sh
new file mode 100755
index 000000000..35bfc3c1b
--- /dev/null
+++ b/debian/_buildscripts/local/hook_examples/tdelibs/pre_build.sh
@@ -0,0 +1,13 @@
+#!/bin/bash
+
+CURR_DIR=$PWD
+cd "$PKG_BUILD_PATH"
+
+# Apply patches
+if [ "$bool_COPY_PKG_SRC" = "y" ]; then
+ echo -e "${CLightPurple}Applying kfinddialog placeholder patch${CNone}"
+ patch -p2 < "$HOOK_DIR/$PKG_NAME/038_placeholder.diff"
+fi
+
+cd "$CURR_DIR"
+return 0