40263 Commits

Author SHA1 Message Date
Ingo Weinhold
808a51161a Add a BStringList class 2011-07-17 16:55:20 +02:00
Ingo Weinhold
d0c417848b BString::Private class to access BString internals 2011-07-17 16:55:20 +02:00
Ingo Weinhold
10e1bc5267 BRepositoryCache: Add iteration, etc.
* Remove InitCheck() and the initializing constructor.
* Rename PackageCount() to CountPackages().
* Use BOpenHashTable instead of HashMap for the internal PackageMap.
* Allow multiple packages with the same name. Equally named packages are
  in a singly linked list after the first package with that name.
* Add an Iterator inner class and a GetIterator() method, so one can now
  iterate through the packages in the repository.
2011-07-17 16:55:20 +02:00
Ingo Weinhold
5a54e156e5 Add HashValue() methods to BString 2011-07-17 16:55:19 +02:00
Ingo Weinhold
abf1023d31 Handle the newer package attributes
This unbreaks reading repository cache files using the respective
attributes.
2011-07-17 16:55:19 +02:00
Ingo Weinhold
5bc6952049 Add error output in case of invalid compression ID 2011-07-17 16:55:19 +02:00
Ingo Weinhold
6c9fa46136 Fix handling of shine-through directories
* Add a new class ShineThroughDirectory for shine-through directories
  instead of using UnpackingDirectory.
* Split up setting up the shine-through directories in two steps. First
  the directories are only created. That happens before adding the
  initial package domains. After publishing the root node we bind the
  shine-through directories to the underlying directories.
* This makes adding a package directory with the same name as a
  shine-through directory fail in _AddPackageNode() as originally
  intended. Since we no longer want it to fail -- the package daemon
  will copy the files in the respective directories as part of the
  activation process -- we simply skip the directory now. Adjust
  _AddPackageNode() and _AddPackageContentRootNode() accordingly.
2011-07-17 16:55:19 +02:00
Ingo Weinhold
f361dbbe99 Fix notifications when adding package link dir
When adding a new package link directory, the volume would only be
notified about the addition of the directory itself, not of the addition
of its contents. Add a new PackageLinkDirectory::NotifyDirectoryAdded()
which does the whole job and use it in
PackageLinksDirectory::AddPackage().
2011-07-17 16:55:18 +02:00
Ingo Weinhold
3ac7efb860 Fix debug output 2011-07-17 16:55:18 +02:00
Ingo Weinhold
61b0ae0f39 Implement more virtuals in Node and Directory
* Node: Add default implementations for UserID(), GroupID(),
  OpenAttributeDirectory(), and OpenAttribute().
* Directory: Add default implementations for Mode() and FileSize().
* Remove the respective hook implementations in the PackageLink*
  classes.
2011-07-17 16:55:18 +02:00
Ingo Weinhold
f19b93ff21 Missing newline in error message 2011-07-17 16:55:18 +02:00
Ingo Weinhold
c71072069b GetRepositoryCache/Config(): return valid entry
Always create the common repository cache/config paths so the BEntry
that is returned is valid at least. Fixes BRefreshRepositoryRequest
failing when the common repository cache path didn't exist yet.
2011-07-17 16:55:17 +02:00
Ingo Weinhold
c3057c3f03 Initialize BRepositoryInfo::fInitStatus 2011-07-17 16:55:17 +02:00
Ingo Weinhold
30ab13397b Handle the newer package attributes 2011-07-17 16:55:17 +02:00
Ingo Weinhold
f642202ae8 Updated gcc 2.95.3 package
The /boot/common include paths are now built in.
2011-07-17 16:55:17 +02:00
Ingo Weinhold
0c7ef631d8 Notify earlier when removing a package node
Volume::_RemovePackageNode(): Notify listeners before removing the last
package node from the node, . This prevents the size/last modified
indices from not finding the node anymore, since the node would return
a default value instead of the value it was added to the index with.
2011-07-17 16:55:16 +02:00
Ingo Weinhold
15e694e535 Add UnpackingNode::IsOnlyPackageNode()
It returns whether the given package node is the only package node
attached to that node.
2011-07-17 16:55:15 +02:00
Ingo Weinhold
437651ffcc Force package names and versions to lower case 2011-07-17 16:55:15 +02:00
Ingo Weinhold
48a8980c43 Add install path support to packagefs 2011-07-17 16:55:15 +02:00
Ingo Weinhold
6f0f81ef9b Add options -b and -I to package command
* With -b building a build package can be requested. It will be empty
  save for the .PackageInfo. No license check is performed.
* -I allows to specify an install path.
2011-07-17 16:55:15 +02:00
Ingo Weinhold
f19957b8e5 Add a package info "install-path" attribute
The attribute is intended for simplifying package building. The
package's install path will be used for the package's .self package
symlink, allowing installation to a temporary directory when building
the package.
2011-07-17 16:55:14 +02:00
Ingo Weinhold
d7227dfa9e BPackageWriter: Add SetCheckLicenses()
The default is still "true", but now it is possible to disable the
license check.
2011-07-17 16:55:14 +02:00
Ingo Weinhold
e6067d0cf4 Change Haiku package name to lower case 2011-07-17 16:55:14 +02:00
Ingo Weinhold
a0f6347784 Fix location of the Deskbar menu symlinks 2011-07-17 16:55:14 +02:00
Ingo Weinhold
407c09e2d9 Create /packages symlink on boot
Rename the package links directory from /package-links to just /packages
and create it when booting.
2011-07-17 16:55:13 +02:00
Ingo Weinhold
3773b47514 Tracker: Sort volumes like folders
Volumes no longer have a higher sorting priority than folders when "sort
folders first" is enabled.
2011-07-17 16:55:13 +02:00
Ingo Weinhold
e96cbb12b4 Update cmake package, create doxygen package 2011-07-17 16:55:13 +02:00
Ingo Weinhold
70de928ed8 Move <directories.h> to headers/private/system 2011-07-17 16:55:13 +02:00
Ingo Weinhold
e94674ce75 cmake 2.8.5 optional package repackaged as hpkg 2011-07-17 16:55:13 +02:00
Ingo Weinhold
c98a59c653 Don't show packagefs on desktop or in disks window
More generally: Any volume that is mounted at a directory of a
persistent volume is not shown on the desktop or the disks window any
longer.
2011-07-17 16:55:12 +02:00
Ingo Weinhold
207a28efee Declare packagefs persistent
Besides that it is kind of correct, it also makes tracker queries work
correctly.
2011-07-17 16:55:12 +02:00
Ingo Weinhold
139bd32c02 Implement packagefs index (dir) hooks 2011-07-17 16:55:12 +02:00
Ingo Weinhold
bf20808710 Add set_dirent_name() without name length parameter 2011-07-17 16:55:12 +02:00
Ingo Weinhold
7915349914 Remove unused IndexIterator constructor 2011-07-17 16:55:11 +02:00
Ingo Weinhold
29ee895757 Remove references in index iterator interface
This avoids checks.
2011-07-17 16:55:11 +02:00
Ingo Weinhold
ac6706807e Remove superfluous checks 2011-07-17 16:55:11 +02:00
Ingo Weinhold
4006e48369 Check key length, if index keys are fixed length 2011-07-17 16:55:11 +02:00
Ingo Weinhold
061337ba5f Create a "BEOS:APP_SIG" index by default 2011-07-17 16:55:10 +02:00
Ingo Weinhold
55b969b13b Attribute index support for non-special attributes
* Add AttributeIndex class.
* Each attribute does now have an attribute index cookie. The new
  attribute index service methods Node::IndexAttribute() and
  IndexCookieForAttribute() create+set/retrieve the cookie. The cookie
  is actually the attribute index's tree node.
* Add OldNodeAttribute::IndexCookieForAttribute() so the cookie is
  available when the node changes.
2011-07-17 16:55:10 +02:00
Ingo Weinhold
4d67e7847b More abstraction in GenericIndexIterator
* Move tree node operations to a subpolicy TreePolicy.
* Add a GenericIndexIteratorTreePolicy templatized over the policy,
  implementing the tree policy for the standard indices.
2011-07-17 16:55:10 +02:00
Ingo Weinhold
51ee03bead QueryPolicy::NodeGetAttribute(): Get the type too 2011-07-17 16:55:10 +02:00
Ingo Weinhold
278925246f Remove unused PackageNodeAttribute::fParent 2011-07-17 16:55:09 +02:00
Ingo Weinhold
a52387c669 compareKeys(): Also handle B_MIME_STRING_TYPE 2011-07-17 16:55:09 +02:00
Ingo Weinhold
3e29244600 Move B_MIME_STRING_TYPE to <TypeConstants.h> 2011-07-17 16:55:09 +02:00
Ingo Weinhold
901749cff2 Remove TwoKeyAVLTree from kernel utils again
It's not ready for shared use yet.
2011-07-17 16:55:09 +02:00
Ingo Weinhold
01f7f92aef Move helper function out of QueryParser.h
They live in the new QueryParserUtils.{h,cpp} now.
2011-07-17 16:55:08 +02:00
Ingo Weinhold
3877a7f4a0 AVLTreeMap fixes
* AVLTreeMap::_GetKey(): Change return type from const Key& to Key, so
  the strategy can do that as well and doesn't have have a Key object in
  the node.
* Fix the Auto strategy: It was using the undefined _GetKey() instead
  of GetKey().
2011-07-17 16:55:08 +02:00
Ingo Weinhold
28559a4e24 Build fix 2011-07-17 16:55:08 +02:00
Ingo Weinhold
0c63c7738a Add last modified index support
* Add class LastModifiedIndex.
* Create and add an instance of it in Volume::Mount().
2011-07-17 16:55:08 +02:00
Ingo Weinhold
a5d15ca28b Removed left-over commented code 2011-07-17 16:55:08 +02:00